Commit a79530e4 authored by David Howells's avatar David Howells Committed by Linus Torvalds
Browse files

drivers/video/aty/aty128fb.c: fix a warning pertaining to the aty128fb backlight variable

Fix the following warning in the aty128fb driver:

	drivers/video/aty/aty128fb.c:363:12: warning: 'backlight' defined but not used [-Wunused-variable]
	 static int backlight = 0;

as the variable's value is only read if CONFIG_FB_ATY128_BACKLIGHT=y.  The
variable is also set if MODULE is unset[*].

[*] I wonder if the conditional wrapper around aty128fb_setup() should be
    using CONFIG_MODULE rather than MODULE.
Signed-off-by: default avatarDavid Howells <>
Cc: Paul Mackerras <>
Signed-off-by: default avatarAndrew Morton <>
Signed-off-by: default avatarLinus Torvalds <>
parent c6d5f989
......@@ -357,11 +357,13 @@ static int default_lcd_on = 1;
static bool mtrr = true;
static int backlight = 1;
static int backlight = 0;
/* PLL constants */
struct aty128_constants {
......@@ -1671,7 +1673,9 @@ static int aty128fb_setup(char *options)
default_crt_on = simple_strtoul(this_opt+4, NULL, 0);
} else if (!strncmp(this_opt, "backlight:", 10)) {
backlight = simple_strtoul(this_opt+10, NULL, 0);
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment