Commit c095da04 authored by Adam Jackson's avatar Adam Jackson 🎧
Browse files

Fix magic number in fbdevhw

The transformation between fbdev and xfree86 mode timings needs to be
invertible, otherwise Xen and other framebuffers that don't have real
pixel clocks won't initialize.
parent f4fe66f6
...@@ -258,7 +258,7 @@ fbdev_modes_equal(struct fb_var_screeninfo *set, struct fb_var_screeninfo *req) ...@@ -258,7 +258,7 @@ fbdev_modes_equal(struct fb_var_screeninfo *set, struct fb_var_screeninfo *req)
static void static void
fbdev2xfree_timing(struct fb_var_screeninfo *var, DisplayModePtr mode) fbdev2xfree_timing(struct fb_var_screeninfo *var, DisplayModePtr mode)
{ {
mode->Clock = var->pixclock ? 1000000000/var->pixclock : 28000000; mode->Clock = var->pixclock ? 1000000000/var->pixclock : 0;
mode->HDisplay = var->xres; mode->HDisplay = var->xres;
mode->HSyncStart = mode->HDisplay+var->right_margin; mode->HSyncStart = mode->HDisplay+var->right_margin;
mode->HSyncEnd = mode->HSyncStart+var->hsync_len; mode->HSyncEnd = mode->HSyncStart+var->hsync_len;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment