diff options
author | Timur Tabi <timur@freescale.com> | 2011-09-15 17:44:51 -0400 |
---|---|---|
committer | Florian Tobias Schandinat <FlorianSchandinat@gmx.de> | 2011-09-18 16:08:57 -0400 |
commit | 63cf8df44e522e2807ccbd0d55b851a89a311bc2 (patch) | |
tree | 2817c25fe736cefae069841256a3517d9c4cc2b1 /drivers/video/fsl-diu-fb.c | |
parent | 9e52ba612fa0d554c83c4bd988d60d4586347c17 (diff) |
drivers/video: fsl-diu-fb: remove redundant default video mode
The framebuffer layer already uses the first video mode defined in the
fb_videomode array as a default, so there's no need to duplicate the
first entry into a stand-alone structure.
Signed-off-by: Timur Tabi <timur@freescale.com>
Signed-off-by: Florian Tobias Schandinat <FlorianSchandinat@gmx.de>
Diffstat (limited to 'drivers/video/fsl-diu-fb.c')
-rw-r--r-- | drivers/video/fsl-diu-fb.c | 32 |
1 files changed, 7 insertions, 25 deletions
diff --git a/drivers/video/fsl-diu-fb.c b/drivers/video/fsl-diu-fb.c index 96417abb4bec..c89395450ee7 100644 --- a/drivers/video/fsl-diu-fb.c +++ b/drivers/video/fsl-diu-fb.c | |||
@@ -36,26 +36,10 @@ | |||
36 | #include "edid.h" | 36 | #include "edid.h" |
37 | 37 | ||
38 | /* | 38 | /* |
39 | * These parameters give default parameters | 39 | * List of supported video modes |
40 | * for video output 1024x768, | 40 | * |
41 | * FIXME - change timing to proper amounts | 41 | * The first entry is the default video mode |
42 | * hsync 31.5kHz, vsync 60Hz | ||
43 | */ | 42 | */ |
44 | static struct fb_videomode __devinitdata fsl_diu_default_mode = { | ||
45 | .refresh = 60, | ||
46 | .xres = 1024, | ||
47 | .yres = 768, | ||
48 | .pixclock = 15385, | ||
49 | .left_margin = 160, | ||
50 | .right_margin = 24, | ||
51 | .upper_margin = 29, | ||
52 | .lower_margin = 3, | ||
53 | .hsync_len = 136, | ||
54 | .vsync_len = 6, | ||
55 | .sync = FB_SYNC_COMP_HIGH_ACT | FB_SYNC_VERT_HIGH_ACT, | ||
56 | .vmode = FB_VMODE_NONINTERLACED | ||
57 | }; | ||
58 | |||
59 | static struct fb_videomode __devinitdata fsl_diu_mode_db[] = { | 43 | static struct fb_videomode __devinitdata fsl_diu_mode_db[] = { |
60 | { | 44 | { |
61 | .name = "1024x768-60", | 45 | .name = "1024x768-60", |
@@ -1165,8 +1149,8 @@ static int __devinit install_fb(struct fb_info *info) | |||
1165 | } else { | 1149 | } else { |
1166 | aoi_mode = init_aoi_mode; | 1150 | aoi_mode = init_aoi_mode; |
1167 | } | 1151 | } |
1168 | rc = fb_find_mode(&info->var, info, aoi_mode, db, dbsize, | 1152 | rc = fb_find_mode(&info->var, info, aoi_mode, db, dbsize, NULL, |
1169 | &fsl_diu_default_mode, default_bpp); | 1153 | default_bpp); |
1170 | if (!rc) { | 1154 | if (!rc) { |
1171 | /* | 1155 | /* |
1172 | * For plane 0 we continue and look into | 1156 | * For plane 0 we continue and look into |
@@ -1180,10 +1164,8 @@ static int __devinit install_fb(struct fb_info *info) | |||
1180 | 1164 | ||
1181 | if (!has_default_mode) { | 1165 | if (!has_default_mode) { |
1182 | rc = fb_find_mode(&info->var, info, aoi_mode, fsl_diu_mode_db, | 1166 | rc = fb_find_mode(&info->var, info, aoi_mode, fsl_diu_mode_db, |
1183 | ARRAY_SIZE(fsl_diu_mode_db), | 1167 | ARRAY_SIZE(fsl_diu_mode_db), NULL, default_bpp); |
1184 | &fsl_diu_default_mode, | 1168 | if (rc) |
1185 | default_bpp); | ||
1186 | if (rc > 0 && rc < 5) | ||
1187 | has_default_mode = 1; | 1169 | has_default_mode = 1; |
1188 | } | 1170 | } |
1189 | 1171 | ||