aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/video/udlfb.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2011-07-04 15:53:53 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2011-07-04 15:53:53 -0700
commitaababb9766f0e874da26a17acbbec867bf9501f0 (patch)
tree4dea1f04d8c6d66ce00bb0ab49b939c165c3f33b /drivers/video/udlfb.c
parentb2bc4782191cb574924a1d09f48083ea8b33a93b (diff)
parent3e86f1d8e397b1ef59a97910089e16a99e8f31f7 (diff)
Merge branch 'fbdev-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/lethal/fbdev-3.x
* 'fbdev-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/lethal/fbdev-3.x: vesafb: fix memory leak fbdev: amba: Link fb device to its parent fsl-diu-fb: remove check for pixel clock ranges udlfb: Correct sub-optimal resolution selection. hecubafb: add module_put on error path in hecubafb_probe() sm501fb: fix section mismatch warning gx1fb: Fix section mismatch warnings fbdev: sh_mobile_meram: Correct pointer check for YCbCr chroma plane
Diffstat (limited to 'drivers/video/udlfb.c')
-rw-r--r--drivers/video/udlfb.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/drivers/video/udlfb.c b/drivers/video/udlfb.c
index 52b0f3e8ccac..816a4fda04f5 100644
--- a/drivers/video/udlfb.c
+++ b/drivers/video/udlfb.c
@@ -1233,8 +1233,12 @@ static int dlfb_setup_modes(struct dlfb_data *dev,
if (dlfb_is_valid_mode(&info->monspecs.modedb[i], info))
fb_add_videomode(&info->monspecs.modedb[i],
&info->modelist);
- else /* if we've removed top/best mode */
- info->monspecs.misc &= ~FB_MISC_1ST_DETAIL;
+ else {
+ if (i == 0)
+ /* if we've removed top/best mode */
+ info->monspecs.misc
+ &= ~FB_MISC_1ST_DETAIL;
+ }
}
default_vmode = fb_find_best_display(&info->monspecs,

Privacy Policy