Skip to content

Commit

Permalink
compal: fingers off backlight if video.ko is serving this functionality
Browse files Browse the repository at this point in the history
Signed-off-by: Thomas Renninger <trenn@suse.de>
Acked-by: Zhang Rui <rui.zhang@intel.com>
Signed-off-by: Andi Kleen <ak@linux.intel.com>
Signed-off-by: Len Brown <len.brown@intel.com>
  • Loading branch information
Thomas Renninger authored and Len Brown committed Nov 8, 2008
1 parent 6766fec commit 29454f1
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions drivers/misc/compal-laptop.c
Original file line number Diff line number Diff line change
Expand Up @@ -326,12 +326,14 @@ static int __init compal_init(void)

/* Register backlight stuff */

compalbl_device = backlight_device_register("compal-laptop", NULL, NULL,
&compalbl_ops);
if (IS_ERR(compalbl_device))
return PTR_ERR(compalbl_device);
if (!acpi_video_backlight_support()) {
compalbl_device = backlight_device_register("compal-laptop", NULL, NULL,
&compalbl_ops);
if (IS_ERR(compalbl_device))
return PTR_ERR(compalbl_device);

compalbl_device->props.max_brightness = COMPAL_LCD_LEVEL_MAX-1;
compalbl_device->props.max_brightness = COMPAL_LCD_LEVEL_MAX-1;
}

ret = platform_driver_register(&compal_driver);
if (ret)
Expand Down

0 comments on commit 29454f1

Please sign in to comment.