Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 188183
b: refs/heads/master
c: fa11de0
h: refs/heads/master
i:
  188181: 7754171
  188179: d01b25e
  188175: 1928c82
v: v3
  • Loading branch information
Bruno Prémont authored and Richard Purdie committed Mar 16, 2010
1 parent 3b3ec8a commit 76327bc
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 3 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: f0af78991363d704694a3618b638662c97d8a110
refs/heads/master: fa11de0a33e214a00e205494c27fb5a7bb71a5fa
10 changes: 9 additions & 1 deletion trunk/drivers/video/bf54x-lq043fb.c
Original file line number Diff line number Diff line change
Expand Up @@ -433,7 +433,7 @@ static int bl_get_brightness(struct backlight_device *bd)
return 0;
}

static struct backlight_ops bfin_lq043fb_bl_ops = {
static const struct backlight_ops bfin_lq043fb_bl_ops = {
.get_brightness = bl_get_brightness,
};

Expand Down Expand Up @@ -650,13 +650,21 @@ static int __devinit bfin_bf54x_probe(struct platform_device *pdev)
props.max_brightness = 255;
bl_dev = backlight_device_register("bf54x-bl", NULL, NULL,
&bfin_lq043fb_bl_ops, &props);
if (IS_ERR(bl_dev)) {
printk(KERN_ERR DRIVER_NAME
": unable to register backlight.\n");
ret = -EINVAL;
goto out9;
}

lcd_dev = lcd_device_register(DRIVER_NAME, &pdev->dev, NULL, &bfin_lcd_ops);
lcd_dev->props.max_contrast = 255, printk(KERN_INFO "Done.\n");
#endif

return 0;

out9:
unregister_framebuffer(fbinfo);
out8:
free_irq(info->irq, info);
out7:
Expand Down
10 changes: 9 additions & 1 deletion trunk/drivers/video/bfin-t350mcqb-fb.c
Original file line number Diff line number Diff line change
Expand Up @@ -352,7 +352,7 @@ static int bl_get_brightness(struct backlight_device *bd)
return 0;
}

static struct backlight_ops bfin_lq043fb_bl_ops = {
static const struct backlight_ops bfin_lq043fb_bl_ops = {
.get_brightness = bl_get_brightness,
};

Expand Down Expand Up @@ -545,13 +545,21 @@ static int __devinit bfin_t350mcqb_probe(struct platform_device *pdev)
props.max_brightness = 255;
bl_dev = backlight_device_register("bf52x-bl", NULL, NULL,
&bfin_lq043fb_bl_ops, &props);
if (IS_ERR(bl_dev)) {
printk(KERN_ERR DRIVER_NAME
": unable to register backlight.\n");
ret = -EINVAL;
goto out9;
}

lcd_dev = lcd_device_register(DRIVER_NAME, NULL, &bfin_lcd_ops);
lcd_dev->props.max_contrast = 255, printk(KERN_INFO "Done.\n");
#endif

return 0;

out9:
unregister_framebuffer(fbinfo);
out8:
free_irq(info->irq, info);
out7:
Expand Down

0 comments on commit 76327bc

Please sign in to comment.