aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/video/aty/atyfb_base.c
diff options
context:
space:
mode:
authorRichard Purdie <rpurdie@rpsys.net>2007-03-03 12:43:52 -0500
committerRichard Purdie <rpurdie@rpsys.net>2007-03-05 03:49:38 -0500
commit202d4e602555e68c2bc71775228876b0356785c8 (patch)
treee47c4013016e21a231b9d2873a2d75aa2750c5fe /drivers/video/aty/atyfb_base.c
parent238576e12fef1d52751c6e08db2d0bdb0e248caf (diff)
backlight: Allow enable/disable of fb backlights, fixing regressions
Enabling the backlight by default appears to cause problems for many users. This patch disables backlight controls unless explicitly enabled by users via a module parameter. Since PMAC users are known to work, default to enabled in that case. Signed-off-by: Richard Purdie <rpurdie@rpsys.net>
Diffstat (limited to 'drivers/video/aty/atyfb_base.c')
-rw-r--r--drivers/video/aty/atyfb_base.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/drivers/video/aty/atyfb_base.c b/drivers/video/aty/atyfb_base.c
index a7e0062233f2..00a51835fd82 100644
--- a/drivers/video/aty/atyfb_base.c
+++ b/drivers/video/aty/atyfb_base.c
@@ -308,6 +308,12 @@ static int xclk;
308static int comp_sync __devinitdata = -1; 308static int comp_sync __devinitdata = -1;
309static char *mode; 309static char *mode;
310 310
311#ifdef CONFIG_PMAC_BACKLIGHT
312static int backlight __devinitdata = 1;
313#else
314static int backlight __devinitdata = 0;
315#endif
316
311#ifdef CONFIG_PPC 317#ifdef CONFIG_PPC
312static int default_vmode __devinitdata = VMODE_CHOOSE; 318static int default_vmode __devinitdata = VMODE_CHOOSE;
313static int default_cmode __devinitdata = CMODE_CHOOSE; 319static int default_cmode __devinitdata = CMODE_CHOOSE;
@@ -2575,7 +2581,7 @@ static int __devinit aty_init(struct fb_info *info)
2575 | (USE_F32KHZ | TRISTATE_MEM_EN), par); 2581 | (USE_F32KHZ | TRISTATE_MEM_EN), par);
2576 } else 2582 } else
2577#endif 2583#endif
2578 if (M64_HAS(MOBIL_BUS)) { 2584 if (M64_HAS(MOBIL_BUS) && backlight) {
2579#ifdef CONFIG_FB_ATY_BACKLIGHT 2585#ifdef CONFIG_FB_ATY_BACKLIGHT
2580 aty_bl_init (par); 2586 aty_bl_init (par);
2581#endif 2587#endif
@@ -3757,6 +3763,8 @@ static int __init atyfb_setup(char *options)
3757 xclk = simple_strtoul(this_opt+5, NULL, 0); 3763 xclk = simple_strtoul(this_opt+5, NULL, 0);
3758 else if (!strncmp(this_opt, "comp_sync:", 10)) 3764 else if (!strncmp(this_opt, "comp_sync:", 10))
3759 comp_sync = simple_strtoul(this_opt+10, NULL, 0); 3765 comp_sync = simple_strtoul(this_opt+10, NULL, 0);
3766 else if (!strncmp(this_opt, "backlight:", 10))
3767 backlight = simple_strtoul(this_opt+10, NULL, 0);
3760#ifdef CONFIG_PPC 3768#ifdef CONFIG_PPC
3761 else if (!strncmp(this_opt, "vmode:", 6)) { 3769 else if (!strncmp(this_opt, "vmode:", 6)) {
3762 unsigned int vmode = 3770 unsigned int vmode =