Merge branches 'acpi-blacklist' and 'acpi-video'

* acpi-blacklist:
ACPI / blacklist: Disable Vista compatibility for Sony VGN-SR19XN.

* acpi-video:
ACPI / video: Add force native backlight quirk for Lenovo Ideapad Z570
ACPI / video: Allow forcing native backlight on non win8 machines

+38 -14
+8
drivers/acpi/blacklist.c
··· 215 }, 216 { 217 .callback = dmi_disable_osi_vista, 218 .ident = "Toshiba Satellite L355", 219 .matches = { 220 DMI_MATCH(DMI_SYS_VENDOR, "TOSHIBA"),
··· 215 }, 216 { 217 .callback = dmi_disable_osi_vista, 218 + .ident = "VGN-SR19XN", 219 + .matches = { 220 + DMI_MATCH(DMI_SYS_VENDOR, "Sony Corporation"), 221 + DMI_MATCH(DMI_PRODUCT_NAME, "VGN-SR19XN"), 222 + }, 223 + }, 224 + { 225 + .callback = dmi_disable_osi_vista, 226 .ident = "Toshiba Satellite L355", 227 .matches = { 228 DMI_MATCH(DMI_SYS_VENDOR, "TOSHIBA"),
+30 -6
drivers/acpi/video.c
··· 82 * For Windows 8 systems: used to decide if video module 83 * should skip registering backlight interface of its own. 84 */ 85 - static int use_native_backlight_param = -1; 86 module_param_named(use_native_backlight, use_native_backlight_param, int, 0444); 87 - static bool use_native_backlight_dmi = true; 88 89 static int register_count; 90 static struct mutex video_list_lock; ··· 243 244 static bool acpi_video_use_native_backlight(void) 245 { 246 - if (use_native_backlight_param != -1) 247 return use_native_backlight_param; 248 - else 249 return use_native_backlight_dmi; 250 } 251 252 bool acpi_video_verify_backlight_support(void) 253 { 254 - if (acpi_osi_is_win8() && acpi_video_use_native_backlight() && 255 backlight_device_registered(BACKLIGHT_RAW)) 256 return false; 257 return acpi_video_backlight_support(); ··· 421 422 static int __init video_disable_native_backlight(const struct dmi_system_id *d) 423 { 424 - use_native_backlight_dmi = false; 425 return 0; 426 } 427 ··· 570 .matches = { 571 DMI_MATCH(DMI_SYS_VENDOR, "Dell Inc."), 572 DMI_MATCH(DMI_PRODUCT_NAME, "XPS L521X"), 573 }, 574 }, 575 {}
··· 82 * For Windows 8 systems: used to decide if video module 83 * should skip registering backlight interface of its own. 84 */ 85 + enum { 86 + NATIVE_BACKLIGHT_NOT_SET = -1, 87 + NATIVE_BACKLIGHT_OFF, 88 + NATIVE_BACKLIGHT_ON, 89 + }; 90 + 91 + static int use_native_backlight_param = NATIVE_BACKLIGHT_NOT_SET; 92 module_param_named(use_native_backlight, use_native_backlight_param, int, 0444); 93 + static int use_native_backlight_dmi = NATIVE_BACKLIGHT_NOT_SET; 94 95 static int register_count; 96 static struct mutex video_list_lock; ··· 237 238 static bool acpi_video_use_native_backlight(void) 239 { 240 + if (use_native_backlight_param != NATIVE_BACKLIGHT_NOT_SET) 241 return use_native_backlight_param; 242 + else if (use_native_backlight_dmi != NATIVE_BACKLIGHT_NOT_SET) 243 return use_native_backlight_dmi; 244 + return acpi_osi_is_win8(); 245 } 246 247 bool acpi_video_verify_backlight_support(void) 248 { 249 + if (acpi_video_use_native_backlight() && 250 backlight_device_registered(BACKLIGHT_RAW)) 251 return false; 252 return acpi_video_backlight_support(); ··· 414 415 static int __init video_disable_native_backlight(const struct dmi_system_id *d) 416 { 417 + use_native_backlight_dmi = NATIVE_BACKLIGHT_OFF; 418 + return 0; 419 + } 420 + 421 + static int __init video_enable_native_backlight(const struct dmi_system_id *d) 422 + { 423 + use_native_backlight_dmi = NATIVE_BACKLIGHT_ON; 424 return 0; 425 } 426 ··· 557 .matches = { 558 DMI_MATCH(DMI_SYS_VENDOR, "Dell Inc."), 559 DMI_MATCH(DMI_PRODUCT_NAME, "XPS L521X"), 560 + }, 561 + }, 562 + 563 + /* Non win8 machines which need native backlight nevertheless */ 564 + { 565 + /* https://bugzilla.redhat.com/show_bug.cgi?id=1187004 */ 566 + .callback = video_enable_native_backlight, 567 + .ident = "Lenovo Ideapad Z570", 568 + .matches = { 569 + DMI_MATCH(DMI_SYS_VENDOR, "LENOVO"), 570 + DMI_MATCH(DMI_PRODUCT_NAME, "102434U"), 571 }, 572 }, 573 {}
-8
drivers/acpi/video_detect.c
··· 174 DMI_MATCH(DMI_PRODUCT_NAME, "Inspiron 5737"), 175 }, 176 }, 177 - { 178 - .callback = video_detect_force_vendor, 179 - .ident = "Lenovo IdeaPad Z570", 180 - .matches = { 181 - DMI_MATCH(DMI_SYS_VENDOR, "LENOVO"), 182 - DMI_MATCH(DMI_PRODUCT_VERSION, "Ideapad Z570"), 183 - }, 184 - }, 185 { }, 186 }; 187
··· 174 DMI_MATCH(DMI_PRODUCT_NAME, "Inspiron 5737"), 175 }, 176 }, 177 { }, 178 }; 179