thinkpad-acpi: fix issuing duplicated key events for brightness up/down
[pandora-kernel.git] / drivers / platform / x86 / thinkpad_acpi.c
index 7b82868..2a8d6aa 100644 (file)
@@ -3405,7 +3405,7 @@ static int __init hotkey_init(struct ibm_init_struct *iibm)
        /* Do not issue duplicate brightness change events to
         * userspace. tpacpi_detect_brightness_capabilities() must have
         * been called before this point  */
-       if (tp_features.bright_acpimode && acpi_video_backlight_support()) {
+       if (acpi_video_backlight_support()) {
                pr_info("This ThinkPad has standard ACPI backlight "
                        "brightness control, supported by the ACPI "
                        "video driver\n");
@@ -8665,6 +8665,13 @@ static int __must_check __init get_thinkpad_model_data(
                tp->model_str = kstrdup(s, GFP_KERNEL);
                if (!tp->model_str)
                        return -ENOMEM;
+       } else {
+               s = dmi_get_system_info(DMI_BIOS_VENDOR);
+               if (s && !(strnicmp(s, "Lenovo", 6))) {
+                       tp->model_str = kstrdup(s, GFP_KERNEL);
+                       if (!tp->model_str)
+                               return -ENOMEM;
+               }
        }
 
        s = dmi_get_system_info(DMI_PRODUCT_NAME);