aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/i915/intel_display.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/gpu/drm/i915/intel_display.c')
-rw-r--r--drivers/gpu/drm/i915/intel_display.c32
1 files changed, 32 insertions, 0 deletions
diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c
index 6d8a5edb1fa7..6301d0cb45ee 100644
--- a/drivers/gpu/drm/i915/intel_display.c
+++ b/drivers/gpu/drm/i915/intel_display.c
@@ -8644,6 +8644,34 @@ struct intel_quirk {
8644 void (*hook)(struct drm_device *dev); 8644 void (*hook)(struct drm_device *dev);
8645}; 8645};
8646 8646
8647/* For systems that don't have a meaningful PCI subdevice/subvendor ID */
8648struct intel_dmi_quirk {
8649 void (*hook)(struct drm_device *dev);
8650 const struct dmi_system_id (*dmi_id_list)[];
8651};
8652
8653static int intel_dmi_reverse_brightness(const struct dmi_system_id *id)
8654{
8655 DRM_INFO("Backlight polarity reversed on %s\n", id->ident);
8656 return 1;
8657}
8658
8659static const struct intel_dmi_quirk intel_dmi_quirks[] = {
8660 {
8661 .dmi_id_list = &(const struct dmi_system_id[]) {
8662 {
8663 .callback = intel_dmi_reverse_brightness,
8664 .ident = "NCR Corporation",
8665 .matches = {DMI_MATCH(DMI_SYS_VENDOR, "NCR Corporation"),
8666 DMI_MATCH(DMI_PRODUCT_NAME, ""),
8667 },
8668 },
8669 { } /* terminating entry */
8670 },
8671 .hook = quirk_invert_brightness,
8672 },
8673};
8674
8647static struct intel_quirk intel_quirks[] = { 8675static struct intel_quirk intel_quirks[] = {
8648 /* HP Mini needs pipe A force quirk (LP: #322104) */ 8676 /* HP Mini needs pipe A force quirk (LP: #322104) */
8649 { 0x27ae, 0x103c, 0x361a, quirk_pipea_force }, 8677 { 0x27ae, 0x103c, 0x361a, quirk_pipea_force },
@@ -8683,6 +8711,10 @@ static void intel_init_quirks(struct drm_device *dev)
8683 q->subsystem_device == PCI_ANY_ID)) 8711 q->subsystem_device == PCI_ANY_ID))
8684 q->hook(dev); 8712 q->hook(dev);
8685 } 8713 }
8714 for (i = 0; i < ARRAY_SIZE(intel_dmi_quirks); i++) {
8715 if (dmi_check_system(*intel_dmi_quirks[i].dmi_id_list) != 0)
8716 intel_dmi_quirks[i].hook(dev);
8717 }
8686} 8718}
8687 8719
8688/* Disable the VGA plane that we never use */ 8720/* Disable the VGA plane that we never use */