From cee9e8c5cb1554e9e85ad764d27b6c808555ed89 Mon Sep 17 00:00:00 2001 From: Guido Guenther Date: Fri, 23 Mar 2007 00:10:01 -0700 Subject: [PATCH] [PATCH] rivafb: fix initial brightness This is the rivafb equivalent of 238576e12fef1d52751c6e08db2d0bdb0e248caf. It fixes rivafb having a default backlight brightness of 0 (no picture at all) on a PBook 6,1. Signed-off-by: Guido Guenther Cc: "Antonino A. Daplas" Acked-by: Richard Purdie Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- drivers/video/riva/fbdev.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/video/riva/fbdev.c b/drivers/video/riva/fbdev.c index 1d1c7c624d7f..d7ece8d17a2c 100644 --- a/drivers/video/riva/fbdev.c +++ b/drivers/video/riva/fbdev.c @@ -285,8 +285,6 @@ static const struct riva_regs reg_template = { #define MAX_LEVEL 0x534 #define LEVEL_STEP ((MAX_LEVEL - MIN_LEVEL) / FB_BACKLIGHT_MAX) -static struct backlight_properties riva_bl_data; - static int riva_bl_get_level_brightness(struct riva_par *par, int level) { @@ -372,7 +370,7 @@ static void riva_bl_init(struct riva_par *par) FB_BACKLIGHT_MAX); bd->props.max_brightness = FB_BACKLIGHT_LEVELS - 1; - bd->props.brightness = riva_bl_data.max_brightness; + bd->props.brightness = bd->props.max_brightness; bd->props.power = FB_BLANK_UNBLANK; backlight_update_status(bd); -- 2.30.2