Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 222103
b: refs/heads/master
c: 5fd284e
h: refs/heads/master
i:
  222101: 3794b96
  222099: e654de2
  222095: d4cdd3c
v: v3
  • Loading branch information
Guennadi Liakhovetski authored and Paul Mundt committed Nov 10, 2010
1 parent f82b255 commit a62f67e
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 7 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 5ae0cf82df212253857326a6706018eccb658683
refs/heads/master: 5fd284e6cd39f731db86dfd2440553365d5fad4d
14 changes: 8 additions & 6 deletions trunk/drivers/video/sh_mobile_lcdcfb.c
Original file line number Diff line number Diff line change
Expand Up @@ -1198,6 +1198,7 @@ static int __devinit sh_mobile_lcdc_probe(struct platform_device *pdev)
const struct fb_videomode *mode = cfg->lcd_cfg;
unsigned long max_size = 0;
int k;
int num_cfg;

ch->info = framebuffer_alloc(0, &pdev->dev);
if (!ch->info) {
Expand Down Expand Up @@ -1233,8 +1234,14 @@ static int __devinit sh_mobile_lcdc_probe(struct platform_device *pdev)
info->fix = sh_mobile_lcdc_fix;
info->fix.smem_len = max_size * (cfg->bpp / 8) * 2;

if (!mode)
if (!mode) {
mode = &default_720p;
num_cfg = 1;
} else {
num_cfg = ch->cfg.num_cfg;
}

fb_videomode_to_modelist(mode, num_cfg, &info->modelist);

fb_videomode_to_var(var, mode);
/* Default Y virtual resolution is 2x panel size */
Expand Down Expand Up @@ -1282,10 +1289,6 @@ static int __devinit sh_mobile_lcdc_probe(struct platform_device *pdev)

for (i = 0; i < j; i++) {
struct sh_mobile_lcdc_chan *ch = priv->ch + i;
const struct fb_videomode *mode = ch->cfg.lcd_cfg;

if (!mode)
mode = &default_720p;

info = ch->info;

Expand All @@ -1298,7 +1301,6 @@ static int __devinit sh_mobile_lcdc_probe(struct platform_device *pdev)
}
}

fb_videomode_to_modelist(mode, ch->cfg.num_cfg, &info->modelist);
error = register_framebuffer(info);
if (error < 0)
goto err1;
Expand Down

0 comments on commit a62f67e

Please sign in to comment.