All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] drm/gma500: Add CedarView LVDS blacklist
@ 2019-04-09  6:51 Hans de Goede
  2019-04-09  9:47 ` Patrik Jakobsson
  0 siblings, 1 reply; 17+ messages in thread
From: Hans de Goede @ 2019-04-09  6:51 UTC (permalink / raw)
  To: Daniel Vetter, Patrik Jakobsson; +Cc: David Airlie, Hans de Goede, dri-devel

Some CedarView VBT-s claim that there is a LVDS panel, while there is none.
Specifically this happens on the Thecus N2800 / N5550 NAS models.

This commit adds a LVDS blacklist to deal with this and adds an entry for
the Thecus NAS-es.

BugLink: https://bugzilla.redhat.com/show_bug.cgi?id=1665766
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
---
 drivers/gpu/drm/gma500/cdv_intel_lvds.c | 23 +++++++++++++++++++++++
 1 file changed, 23 insertions(+)

diff --git a/drivers/gpu/drm/gma500/cdv_intel_lvds.c b/drivers/gpu/drm/gma500/cdv_intel_lvds.c
index de9531caaca0..268643af114c 100644
--- a/drivers/gpu/drm/gma500/cdv_intel_lvds.c
+++ b/drivers/gpu/drm/gma500/cdv_intel_lvds.c
@@ -572,6 +572,20 @@ static bool lvds_is_present_in_vbt(struct drm_device *dev,
 	return false;
 }
 
+static const struct dmi_system_id cdv_intel_lvds_blacklist[] = {
+	{
+		/* Thecus N2800 and N5550 family NAS-es */
+		.matches = {
+			DMI_EXACT_MATCH(DMI_SYS_VENDOR, "Intel Corporation"),
+			DMI_EXACT_MATCH(DMI_PRODUCT_NAME, "Milstead Platform"),
+			DMI_EXACT_MATCH(DMI_BOARD_NAME, "Granite Well"),
+			/* BIOS version is CDV_T<version> X64 */
+			DMI_MATCH(DMI_BIOS_VERSION, "CDV_T"),
+		},
+	},
+	{}
+};
+
 /**
  * cdv_intel_lvds_init - setup LVDS connectors on this device
  * @dev: drm device
@@ -594,6 +608,15 @@ void cdv_intel_lvds_init(struct drm_device *dev,
 	int pipe;
 	u8 pin;
 
+	/*
+	 * Check blacklist for machines with BIOSes that list an LVDS panel
+	 * without actually having one.
+	 */
+	if (dmi_check_system(cdv_intel_lvds_blacklist)) {
+		dev_info(&dev->pdev->dev, "System is on LVDS blacklist, skipping LVDS panel detection\n");
+		return;
+	}
+
 	pin = GMBUS_PORT_PANEL;
 	if (!lvds_is_present_in_vbt(dev, &pin)) {
 		DRM_DEBUG_KMS("LVDS is not present in VBT\n");
-- 
2.21.0

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply related	[flat|nested] 17+ messages in thread

end of thread, other threads:[~2019-04-16 15:36 UTC | newest]

Thread overview: 17+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-04-09  6:51 [PATCH] drm/gma500: Add CedarView LVDS blacklist Hans de Goede
2019-04-09  9:47 ` Patrik Jakobsson
2019-04-09 10:20   ` Hans de Goede
2019-04-09 12:05     ` Patrik Jakobsson
2019-04-09 14:44       ` Hans de Goede
2019-04-09 19:31         ` Dominik 'Rathann' Mierzejewski
2019-04-10  7:27           ` Hans de Goede
2019-04-10  9:00             ` Patrik Jakobsson
2019-04-10  9:08               ` Hans de Goede
2019-04-10 11:18                 ` Dominik 'Rathann' Mierzejewski
2019-04-10 11:33                   ` Patrik Jakobsson
2019-04-10 11:51                     ` Dominik 'Rathann' Mierzejewski
2019-04-16 14:32                       ` Patrik Jakobsson
2019-04-16 15:36                         ` Hans de Goede
2019-04-10 11:37                 ` Patrik Jakobsson
2019-04-10 10:43               ` Ville Syrjälä
2019-04-10 11:34                 ` Patrik Jakobsson

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.