aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJordan Crouse <jordan.crouse@amd.com>2006-12-08 05:40:21 -0500
committerLinus Torvalds <torvalds@woody.osdl.org>2006-12-08 11:29:05 -0500
commitc25623f5540694ba70af272170d67f1411be97b1 (patch)
treef8c9e252093b860b198603d7737df4c698d25b24
parent572c04b24bd7b7e4b6a684416325cc3751fa8f45 (diff)
[PATCH] video: Get the default mode from the right database
If no default mode is specified, it should be grabbed from the supplied database, not the default one. [teanropo@jyu.fi: fix it] [akpm@osdl.org: simplify it] [akpm@osdl.org: remove pointless DEFAULT_MODEDB_INDEX] Signed-off-by: Jordan Crouse <jordan.crouse@amd.com> Cc: Geert Uytterhoeven <geert@linux-m68k.org> Cc: "Antonino A. Daplas" <adaplas@pol.net> Signed-off-by: Tero Roponen <teanropo@jyu.fi> Cc: James Simmons <jsimmons@infradead.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
-rw-r--r--drivers/video/modedb.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/video/modedb.c b/drivers/video/modedb.c
index d1267904c280..5df41f6f2b86 100644
--- a/drivers/video/modedb.c
+++ b/drivers/video/modedb.c
@@ -34,8 +34,6 @@ const char *global_mode_option;
34 * Standard video mode definitions (taken from XFree86) 34 * Standard video mode definitions (taken from XFree86)
35 */ 35 */
36 36
37#define DEFAULT_MODEDB_INDEX 0
38
39static const struct fb_videomode modedb[] = { 37static const struct fb_videomode modedb[] = {
40 { 38 {
41 /* 640x400 @ 70 Hz, 31.5 kHz hsync */ 39 /* 640x400 @ 70 Hz, 31.5 kHz hsync */
@@ -505,8 +503,10 @@ int fb_find_mode(struct fb_var_screeninfo *var,
505 db = modedb; 503 db = modedb;
506 dbsize = ARRAY_SIZE(modedb); 504 dbsize = ARRAY_SIZE(modedb);
507 } 505 }
506
508 if (!default_mode) 507 if (!default_mode)
509 default_mode = &modedb[DEFAULT_MODEDB_INDEX]; 508 default_mode = &db[0];
509
510 if (!default_bpp) 510 if (!default_bpp)
511 default_bpp = 8; 511 default_bpp = 8;
512 512