diff options
author | Stefan Agner <stefan.agner@toradex.com> | 2016-01-25 15:44:32 -0800 |
---|---|---|
committer | Max Krummenacher <max.krummenacher@toradex.com> | 2016-06-24 14:46:17 +0200 |
commit | 3d4e2d3590739ee3a3e187b41c832190ff457830 (patch) | |
tree | 2997a70ba08b7fdc2bbe41b0eeed7faa2518dadd | |
parent | 938d98f83ab476a9578aee4dc7274e846146f08b (diff) |
video: fbdev: mxsfb: fix pixelclock polarity
The PIXDATA flags of the display_flags enum are controller centric,
e.g. NEGEDGE means the controller shall drive the data signals on
pixelclocks negative edge. However, the drivers flag is display
centric: Sample the data on negative (falling) edge.
Therefore, change the if statement to check for the POSEDGE flag
(which is typically not set):
Drive on positive edge => sample on negative edge
Signed-off-by: Stefan Agner <stefan.agner@toradex.com>
Acked-by: Max Krummenacher <max.krummenacher@toradex.com>
-rw-r--r-- | drivers/video/fbdev/mxsfb.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/drivers/video/fbdev/mxsfb.c b/drivers/video/fbdev/mxsfb.c index 8cbecbf31da8..a50c35b48951 100644 --- a/drivers/video/fbdev/mxsfb.c +++ b/drivers/video/fbdev/mxsfb.c @@ -1191,7 +1191,16 @@ static int mxsfb_init_fbinfo_dt(struct mxsfb_info *host) if (!(vm.flags & DISPLAY_FLAGS_DE_HIGH)) fb_vm.sync |= FB_SYNC_OE_LOW_ACT; - if (vm.flags & DISPLAY_FLAGS_PIXDATA_NEGEDGE) + + /* + * The PIXDATA flags of the display_flags enum are controller + * centric, e.g. NEGEDGE means drive data on negative edge. + * However, the drivers flag is display centric: Sample the + * data on negative (falling) edge. Therefore, check for the + * POSEDGE flag: + * drive on positive edge => sample on negative edge + */ + if (vm.flags & DISPLAY_FLAGS_PIXDATA_POSEDGE) fb_vm.sync |= FB_SYNC_CLK_LAT_FALL; fb_add_videomode(&fb_vm, &fb_info->modelist); } |