aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorMichal Januszewski <spock@gentoo.org>2005-11-07 04:00:47 -0500
committerLinus Torvalds <torvalds@g5.osdl.org>2005-11-07 10:53:52 -0500
commit8fb6567e347a04d44b57e2b223cc5845859dfc6a (patch)
treedb4037a6694d3ffb6871c073ecb009332ff783b5 /include
parent2fe0175491c4784d95f3237ebdc985da7b26a99d (diff)
[PATCH] fbdev: fix the fb_find_nearest_mode() function
Currently the fb_find_nearest_mode() function finds a mode with screen resolution closest to that described by the 'var' argument and with some arbitrary refresh rate (eg. in the following sequence of refresh rates: 70 60 53 85 75, 53 is selected). This patch fixes the function so that it looks for the closest mode as far as both resolution and refresh rate are concerned. The function's first argument is changed to fb_videomode so that the refresh rate can be specified by the caller, as fb_var_screeninfo doesn't have any fields that could directly hold this data. Signed-off-by: Michal Januszewski <spock@gentoo.org> Signed-off-by: Antonino Daplas <adaplas@pol.net> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'include')
-rw-r--r--include/linux/fb.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/linux/fb.h b/include/linux/fb.h
index 008ea71f4d7f..68a787914d85 100644
--- a/include/linux/fb.h
+++ b/include/linux/fb.h
@@ -897,7 +897,7 @@ extern struct fb_videomode *fb_match_mode(struct fb_var_screeninfo *var,
897 struct list_head *head); 897 struct list_head *head);
898extern struct fb_videomode *fb_find_best_mode(struct fb_var_screeninfo *var, 898extern struct fb_videomode *fb_find_best_mode(struct fb_var_screeninfo *var,
899 struct list_head *head); 899 struct list_head *head);
900extern struct fb_videomode *fb_find_nearest_mode(struct fb_var_screeninfo *var, 900extern struct fb_videomode *fb_find_nearest_mode(struct fb_videomode *mode,
901 struct list_head *head); 901 struct list_head *head);
902extern void fb_destroy_modelist(struct list_head *head); 902extern void fb_destroy_modelist(struct list_head *head);
903extern void fb_videomode_to_modelist(struct fb_videomode *modedb, int num, 903extern void fb_videomode_to_modelist(struct fb_videomode *modedb, int num,