mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH v4 0/1] drm/i915/display: Add quirk to force backlight type on some TUXEDO devices
@ 2026-08-07 20:04 Werner Sembach
  2026-08-07 20:04 ` [PATCH v4 1/1] " Werner Sembach
  0 siblings, 1 reply; 3+ messages in thread
From: Werner Sembach @ 2026-08-07 20:04 UTC (permalink / raw)
  To: jani.nikula, rodrigo.vivi, joonas.lahtinen, tursulin, airlied, simona
  Cc: wse, intel-gfx, intel-xe, dri-devel, linux-kernel

Since the proposed general fix, fixed the backlight on TUXEDO devices, but
broke it on other ones:
- https://gitlab.freedesktop.org/drm/i915/kernel/-/work_items/15679#note_3581777
- https://lore.kernel.org/all/20260515155340.1000997-1-suraj.kandpal@intel.com/
I'm back here again proposing the fix via a quirk.

I therefore rebased
https://lore.kernel.org/all/20260121223944.1104951-1-wse@tuxedocomputers.com/
to cleanly apply on current drm-tip.

V1->V2: Switch from dmis trings to PCI-IDs
V2->V3: Rebase onto current drm-tip
V3->V4: Better commit message and added comment in code

Werner Sembach (1):
  drm/i915/display: Add quirk to force backlight type on some TUXEDO
    devices

 .../drm/i915/display/intel_dp_aux_backlight.c | 22 ++++++++++++++++-
 drivers/gpu/drm/i915/display/intel_quirks.c   | 24 +++++++++++++++++++
 drivers/gpu/drm/i915/display/intel_quirks.h   |  1 +
 3 files changed, 46 insertions(+), 1 deletion(-)


base-commit: 665722ddd6884c57624bd82d7ab886cf11a7b6f8
-- 
2.43.0


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

* [PATCH v4 1/1] drm/i915/display: Add quirk to force backlight type on some TUXEDO devices
  2026-08-07 20:04 [PATCH v4 0/1] drm/i915/display: Add quirk to force backlight type on some TUXEDO devices Werner Sembach
@ 2026-08-07 20:04 ` Werner Sembach
  2026-08-10  5:15   ` Kandpal, Suraj
  0 siblings, 1 reply; 3+ messages in thread
From: Werner Sembach @ 2026-08-07 20:04 UTC (permalink / raw)
  To: jani.nikula, rodrigo.vivi, joonas.lahtinen, tursulin, airlied,
	simona, Suraj Kandpal, Ankit Nautiyal
  Cc: wse, intel-gfx, intel-xe, dri-devel, linux-kernel

The display backlight on TUXEDO DX1708 and InsanityBook 15 v1 have a broken
VBT in the AUO 12701 and AUO 12701 panels, but not others. They are
advertising INTEL_BACKLIGHT_DISPLAY_DDI, but are actually failing to use
the Intel interface. Adding a fallback to the VESA interface gives
these devices a working backlight for both the broken and non broken
panel VBTs.

Forcing the fallback can already be achieved via a module parameter,
but this patch adds a quirk to apply this by default on the mentioned
devices.

This patch does not actually test for the exact panels as the ID that is
used in the intel_dpcd_quirks list is sadly zeroed on the devices, but
afaik all these devices use try_intel_interface first anyway so all the
quirk does is to add the fallback to try_vesa_interface, so the behaviour
on the devices not needing the quirk and fallback should functionally stay
the same.

Fixes: f30fddb44023 ("Revert "drm/i915/backlight: Remove try_vesa_interface"")
Closes: https://gitlab.freedesktop.org/drm/i915/kernel/-/work_items/15679
Cc: stable@vger.kernel.org
Signed-off-by: Werner Sembach <wse@tuxedocomputers.com>
---
 .../drm/i915/display/intel_dp_aux_backlight.c | 22 ++++++++++++++++-
 drivers/gpu/drm/i915/display/intel_quirks.c   | 24 +++++++++++++++++++
 drivers/gpu/drm/i915/display/intel_quirks.h   |  1 +
 3 files changed, 46 insertions(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c b/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
index 266e042e00237..d84def79c4bfb 100644
--- a/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
+++ b/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
@@ -41,6 +41,7 @@
 #include "intel_display_types.h"
 #include "intel_dp.h"
 #include "intel_dp_aux_backlight.h"
+#include "intel_quirks.h"
 
 /*
  * DP AUX registers for Intel's proprietary HDR backlight interface. We define
@@ -687,11 +688,30 @@ int intel_dp_aux_init_backlight_funcs(struct intel_connector *connector)
 	struct drm_device *dev = connector->base.dev;
 	struct intel_panel *panel = &connector->panel;
 	bool try_intel_interface = false, try_vesa_interface = false;
+	int enable_dpcd_backlight;
+
+	/*
+	 * Some devices have a broken VBT in some Panels, but not others,
+	 * advertising INTEL_BACKLIGHT_DISPLAY_DDI, but actually failing to use
+	 * the Intel interface. Adding a fallback to the Vesa interface gives
+	 * these devices a working backlight for both the broken and non broken
+	 * panel VBTs.
+	 *
+	 * This fallback can not be made the general default as this has broken
+	 * other devices in the past whose VBT correctly reports
+	 * INTEL_BACKLIGHT_DISPLAY_DDI and whose PWM path is the actual
+	 * backlight control, but whose DPCD optimistically advertises
+	 * DP_EDP_BACKLIGHT_AUX_ENABLE_CAP / _BRIGHTNESS_AUX_SET_CAP.
+	 */
+	enable_dpcd_backlight = display->params.enable_dpcd_backlight;
+	if (enable_dpcd_backlight == INTEL_DP_AUX_BACKLIGHT_AUTO &&
+	    intel_has_dpcd_quirk(intel_dp, QUIRK_ENABLE_DPCD_BACKLIGHT))
+		enable_dpcd_backlight = INTEL_DP_AUX_BACKLIGHT_ON;
 
 	/* Check the VBT and user's module parameters to figure out which
 	 * interfaces to probe
 	 */
-	switch (display->params.enable_dpcd_backlight) {
+	switch (enable_dpcd_backlight) {
 	case INTEL_DP_AUX_BACKLIGHT_OFF:
 		return -ENODEV;
 	case INTEL_DP_AUX_BACKLIGHT_AUTO:
diff --git a/drivers/gpu/drm/i915/display/intel_quirks.c b/drivers/gpu/drm/i915/display/intel_quirks.c
index 33245f44c0d50..89d82364ae45d 100644
--- a/drivers/gpu/drm/i915/display/intel_quirks.c
+++ b/drivers/gpu/drm/i915/display/intel_quirks.c
@@ -100,6 +100,14 @@ static void quirk_disable_psr2(struct intel_display *display)
 	drm_info(display->drm, "PSR2 support not currently available for this setup, applying disable PSR2 quirk\n");
 }
 
+static void quirk_enable_dpcd_backlight(struct intel_dp *intel_dp)
+{
+	struct intel_display *display = to_intel_display(intel_dp);
+
+	intel_set_dpcd_quirk(intel_dp, QUIRK_ENABLE_DPCD_BACKLIGHT);
+	drm_info(display->drm, "Applying Enable DPCD Backlight quirk\n");
+}
+
 struct intel_quirk {
 	int device;
 	int subsystem_vendor;
@@ -286,6 +294,22 @@ static const struct intel_dpcd_quirk intel_dpcd_quirks[] = {
 		.sink_oui = SINK_OUI(0x00, 0x22, 0xb9),
 		.hook = quirk_disable_edp_panel_replay,
 	},
+	/* TUXEDO InsanityBook 15 v1 */
+	{
+		.device = 0x591b,
+		.subsystem_vendor = 0x1558,
+		.subsystem_device = 0x9501,
+		.sink_oui = SINK_OUI(0x38, 0xec, 0x11),
+		.hook = quirk_enable_dpcd_backlight,
+	},
+	/* TUXEDO DX1708 */
+	{
+		.device = 0x3e9b,
+		.subsystem_vendor = 0x1558,
+		.subsystem_device = 0x8500,
+		.sink_oui = SINK_OUI(0x38, 0xec, 0x11),
+		.hook = quirk_enable_dpcd_backlight,
+	},
 };
 
 void intel_init_quirks(struct intel_display *display)
diff --git a/drivers/gpu/drm/i915/display/intel_quirks.h b/drivers/gpu/drm/i915/display/intel_quirks.h
index 970a4fe52fafc..4996419ae76bd 100644
--- a/drivers/gpu/drm/i915/display/intel_quirks.h
+++ b/drivers/gpu/drm/i915/display/intel_quirks.h
@@ -23,6 +23,7 @@ enum intel_quirk_id {
 	QUIRK_EDP_LIMIT_RATE_HBR2,
 	QUIRK_DISABLE_EDP_PANEL_REPLAY,
 	QUIRK_DISABLE_PSR2,
+	QUIRK_ENABLE_DPCD_BACKLIGHT,
 };
 
 void intel_init_quirks(struct intel_display *display);
-- 
2.43.0


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

* RE: [PATCH v4 1/1] drm/i915/display: Add quirk to force backlight type on some TUXEDO devices
  2026-08-07 20:04 ` [PATCH v4 1/1] " Werner Sembach
@ 2026-08-10  5:15   ` Kandpal, Suraj
  0 siblings, 0 replies; 3+ messages in thread
From: Kandpal, Suraj @ 2026-08-10  5:15 UTC (permalink / raw)
  To: Werner Sembach, jani.nikula, Vivi, Rodrigo, joonas.lahtinen,
	tursulin, airlied, simona, Nautiyal, Ankit K
  Cc: intel-gfx, intel-xe, dri-devel, linux-kernel

> Subject: [PATCH v4 1/1] drm/i915/display: Add quirk to force backlight type on
> some TUXEDO devices
> 
> The display backlight on TUXEDO DX1708 and InsanityBook 15 v1 have a broken
> VBT in the AUO 12701 and AUO 12701 panels, but not others. They are
> advertising INTEL_BACKLIGHT_DISPLAY_DDI, but are actually failing to use the
> Intel interface. Adding a fallback to the VESA interface gives these devices a
> working backlight for both the broken and non broken panel VBTs.
> 
> Forcing the fallback can already be achieved via a module parameter, but this
> patch adds a quirk to apply this by default on the mentioned devices.
> 
> This patch does not actually test for the exact panels as the ID that is used in

We don't refer to the current code as patch but as a commit because as soon as it gets merged
It's a commit. No need to send the patch again this can be fixed while merging.

Other than that
LGTM,
Reviewed-by: Suraj Kandpal <suraj.kandpal@intel.com>

> the intel_dpcd_quirks list is sadly zeroed on the devices, but afaik all these
> devices use try_intel_interface first anyway so all the quirk does is to add the
> fallback to try_vesa_interface, so the behaviour on the devices not needing the
> quirk and fallback should functionally stay the same.
> 
> Fixes: f30fddb44023 ("Revert "drm/i915/backlight: Remove
> try_vesa_interface"")
> Closes: https://gitlab.freedesktop.org/drm/i915/kernel/-/work_items/15679
> Cc: stable@vger.kernel.org
> Signed-off-by: Werner Sembach <wse@tuxedocomputers.com>
> ---
>  .../drm/i915/display/intel_dp_aux_backlight.c | 22 ++++++++++++++++-
>  drivers/gpu/drm/i915/display/intel_quirks.c   | 24 +++++++++++++++++++
>  drivers/gpu/drm/i915/display/intel_quirks.h   |  1 +
>  3 files changed, 46 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
> b/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
> index 266e042e00237..d84def79c4bfb 100644
> --- a/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
> +++ b/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
> @@ -41,6 +41,7 @@
>  #include "intel_display_types.h"
>  #include "intel_dp.h"
>  #include "intel_dp_aux_backlight.h"
> +#include "intel_quirks.h"
> 
>  /*
>   * DP AUX registers for Intel's proprietary HDR backlight interface. We define
> @@ -687,11 +688,30 @@ int intel_dp_aux_init_backlight_funcs(struct
> intel_connector *connector)
>  	struct drm_device *dev = connector->base.dev;
>  	struct intel_panel *panel = &connector->panel;
>  	bool try_intel_interface = false, try_vesa_interface = false;
> +	int enable_dpcd_backlight;
> +
> +	/*
> +	 * Some devices have a broken VBT in some Panels, but not others,
> +	 * advertising INTEL_BACKLIGHT_DISPLAY_DDI, but actually failing to
> use
> +	 * the Intel interface. Adding a fallback to the Vesa interface gives
> +	 * these devices a working backlight for both the broken and non
> broken
> +	 * panel VBTs.
> +	 *
> +	 * This fallback can not be made the general default as this has broken
> +	 * other devices in the past whose VBT correctly reports
> +	 * INTEL_BACKLIGHT_DISPLAY_DDI and whose PWM path is the actual
> +	 * backlight control, but whose DPCD optimistically advertises
> +	 * DP_EDP_BACKLIGHT_AUX_ENABLE_CAP /
> _BRIGHTNESS_AUX_SET_CAP.
> +	 */
> +	enable_dpcd_backlight = display->params.enable_dpcd_backlight;
> +	if (enable_dpcd_backlight == INTEL_DP_AUX_BACKLIGHT_AUTO &&
> +	    intel_has_dpcd_quirk(intel_dp, QUIRK_ENABLE_DPCD_BACKLIGHT))
> +		enable_dpcd_backlight = INTEL_DP_AUX_BACKLIGHT_ON;
> 
>  	/* Check the VBT and user's module parameters to figure out which
>  	 * interfaces to probe
>  	 */
> -	switch (display->params.enable_dpcd_backlight) {
> +	switch (enable_dpcd_backlight) {
>  	case INTEL_DP_AUX_BACKLIGHT_OFF:
>  		return -ENODEV;
>  	case INTEL_DP_AUX_BACKLIGHT_AUTO:
> diff --git a/drivers/gpu/drm/i915/display/intel_quirks.c
> b/drivers/gpu/drm/i915/display/intel_quirks.c
> index 33245f44c0d50..89d82364ae45d 100644
> --- a/drivers/gpu/drm/i915/display/intel_quirks.c
> +++ b/drivers/gpu/drm/i915/display/intel_quirks.c
> @@ -100,6 +100,14 @@ static void quirk_disable_psr2(struct intel_display
> *display)
>  	drm_info(display->drm, "PSR2 support not currently available for this
> setup, applying disable PSR2 quirk\n");  }
> 
> +static void quirk_enable_dpcd_backlight(struct intel_dp *intel_dp) {
> +	struct intel_display *display = to_intel_display(intel_dp);
> +
> +	intel_set_dpcd_quirk(intel_dp, QUIRK_ENABLE_DPCD_BACKLIGHT);
> +	drm_info(display->drm, "Applying Enable DPCD Backlight quirk\n"); }
> +
>  struct intel_quirk {
>  	int device;
>  	int subsystem_vendor;
> @@ -286,6 +294,22 @@ static const struct intel_dpcd_quirk
> intel_dpcd_quirks[] = {
>  		.sink_oui = SINK_OUI(0x00, 0x22, 0xb9),
>  		.hook = quirk_disable_edp_panel_replay,
>  	},
> +	/* TUXEDO InsanityBook 15 v1 */
> +	{
> +		.device = 0x591b,
> +		.subsystem_vendor = 0x1558,
> +		.subsystem_device = 0x9501,
> +		.sink_oui = SINK_OUI(0x38, 0xec, 0x11),
> +		.hook = quirk_enable_dpcd_backlight,
> +	},
> +	/* TUXEDO DX1708 */
> +	{
> +		.device = 0x3e9b,
> +		.subsystem_vendor = 0x1558,
> +		.subsystem_device = 0x8500,
> +		.sink_oui = SINK_OUI(0x38, 0xec, 0x11),
> +		.hook = quirk_enable_dpcd_backlight,
> +	},
>  };
> 
>  void intel_init_quirks(struct intel_display *display) diff --git
> a/drivers/gpu/drm/i915/display/intel_quirks.h
> b/drivers/gpu/drm/i915/display/intel_quirks.h
> index 970a4fe52fafc..4996419ae76bd 100644
> --- a/drivers/gpu/drm/i915/display/intel_quirks.h
> +++ b/drivers/gpu/drm/i915/display/intel_quirks.h
> @@ -23,6 +23,7 @@ enum intel_quirk_id {
>  	QUIRK_EDP_LIMIT_RATE_HBR2,
>  	QUIRK_DISABLE_EDP_PANEL_REPLAY,
>  	QUIRK_DISABLE_PSR2,
> +	QUIRK_ENABLE_DPCD_BACKLIGHT,
>  };
> 
>  void intel_init_quirks(struct intel_display *display);
> --
> 2.43.0


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

end of thread, other threads:[~2026-08-10  5:15 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-08-07 20:04 [PATCH v4 0/1] drm/i915/display: Add quirk to force backlight type on some TUXEDO devices Werner Sembach
2026-08-07 20:04 ` [PATCH v4 1/1] " Werner Sembach
2026-08-10  5:15   ` Kandpal, Suraj

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®