diff options
author | Henrique de Moraes Holschuh <hmh@hmh.eng.br> | 2007-10-30 23:02:07 +0300 |
---|---|---|
committer | Len Brown <len.brown@intel.com> | 2007-11-05 21:07:11 +0300 |
commit | 87cc537a54fc017d998cf603f5fab9ca4a85d668 (patch) | |
tree | e69421b6f749853f2d9444c3f458b260eb503d4f /drivers/misc/thinkpad_acpi.c | |
parent | a3f104c02ab842574e699186cf953551aafe2ca9 (diff) | |
download | linux-87cc537a54fc017d998cf603f5fab9ca4a85d668.tar.xz |
ACPI: thinkpad-acpi: add brightness_force parameter
Add a "brightness_enable" module parameter that allows the local admin to
force the backlight support to not be enabled.
It can also be used to force the backlight support to be enabled, but that
is currently a no-op as the backlight support is enabled by default when
available. This will be changed by a different patch.
Signed-off-by: Henrique de Moraes Holschuh <hmh@hmh.eng.br>
Signed-off-by: Len Brown <len.brown@intel.com>
Diffstat (limited to 'drivers/misc/thinkpad_acpi.c')
-rw-r--r-- | drivers/misc/thinkpad_acpi.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/drivers/misc/thinkpad_acpi.c b/drivers/misc/thinkpad_acpi.c index 322ba25b4798..56a21e6b80a9 100644 --- a/drivers/misc/thinkpad_acpi.c +++ b/drivers/misc/thinkpad_acpi.c @@ -3182,6 +3182,12 @@ static int __init brightness_init(struct ibm_init_struct *iibm) mutex_init(&brightness_mutex); + if (!brightness_enable) { + dbg_printk(TPACPI_DBG_INIT, + "brightness support disabled by module parameter\n"); + return 1; + } + if (!brightness_mode) { if (thinkpad_id.vendor == PCI_VENDOR_ID_LENOVO) brightness_mode = 2; @@ -4803,6 +4809,9 @@ module_param_named(fan_control, fan_control_allowed, bool, 0); static int brightness_mode; module_param_named(brightness_mode, brightness_mode, int, 0); +static unsigned int brightness_enable = 2; /* 2 = auto, 0 = no, 1 = yes */ +module_param(brightness_enable, uint, 0); + static unsigned int hotkey_report_mode; module_param(hotkey_report_mode, uint, 0); |