* [PATCH 1/2] drm/i915/dpcd_bl: Skip testing control capability with force DPCD quirk
@ 2020-10-07 6:58 ` Kai-Heng Feng
0 siblings, 0 replies; 19+ messages in thread
From: Kai-Heng Feng @ 2020-10-07 6:58 UTC (permalink / raw)
To: Jani Nikula, Joonas Lahtinen, Rodrigo Vivi, David Airlie,
Daniel Vetter, Lyude Paul, Ville Syrjälä,
Juha-Pekka Heikkila, Kai-Heng Feng, intel-gfx,
open list:DRM DRIVERS, open list
Cc: open list:DRM DRIVERS, open list
HP DreamColor panel needs to be controlled via AUX interface. However,
it has both DP_EDP_BACKLIGHT_BRIGHTNESS_AUX_SET_CAP and
DP_EDP_BACKLIGHT_BRIGHTNESS_PWM_PIN_CAP set, so it fails to pass
intel_dp_aux_display_control_capable() test.
Skip the test if the panel has force DPCD quirk.
Signed-off-by: Kai-Heng Feng <kai.heng.feng@canonical.com>
---
drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c | 10 ++++++----
1 file changed, 6 insertions(+), 4 deletions(-)
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 acbd7eb66cbe..acf2e1c65290 100644
--- a/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
+++ b/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
@@ -347,9 +347,13 @@ int intel_dp_aux_init_backlight_funcs(struct intel_connector *intel_connector)
struct intel_panel *panel = &intel_connector->panel;
struct intel_dp *intel_dp = enc_to_intel_dp(intel_connector->encoder);
struct drm_i915_private *i915 = dp_to_i915(intel_dp);
+ bool force_dpcd;
+
+ force_dpcd = drm_dp_has_quirk(&intel_dp->desc, intel_dp->edid_quirks,
+ DP_QUIRK_FORCE_DPCD_BACKLIGHT);
if (i915->params.enable_dpcd_backlight == 0 ||
- !intel_dp_aux_display_control_capable(intel_connector))
+ (!force_dpcd && !intel_dp_aux_display_control_capable(intel_connector)))
return -ENODEV;
/*
@@ -358,9 +362,7 @@ int intel_dp_aux_init_backlight_funcs(struct intel_connector *intel_connector)
*/
if (i915->vbt.backlight.type !=
INTEL_BACKLIGHT_VESA_EDP_AUX_INTERFACE &&
- i915->params.enable_dpcd_backlight != 1 &&
- !drm_dp_has_quirk(&intel_dp->desc, intel_dp->edid_quirks,
- DP_QUIRK_FORCE_DPCD_BACKLIGHT)) {
+ i915->params.enable_dpcd_backlight != 1 && !force_dpcd) {
drm_info(&i915->drm,
"Panel advertises DPCD backlight support, but "
"VBT disagrees. If your backlight controls "
--
2.17.1
^ permalink raw reply related [flat|nested] 19+ messages in thread
* [PATCH 1/2] drm/i915/dpcd_bl: Skip testing control capability with force DPCD quirk
@ 2020-10-07 6:58 ` Kai-Heng Feng
0 siblings, 0 replies; 19+ messages in thread
From: Kai-Heng Feng @ 2020-10-07 6:58 UTC (permalink / raw)
To: Jani Nikula, Joonas Lahtinen, Rodrigo Vivi, David Airlie,
Daniel Vetter, Lyude Paul, Ville Syrjälä,
Juha-Pekka Heikkila, Kai-Heng Feng, intel-gfx,
open list:DRM DRIVERS, open list
Cc: open list, open list:DRM DRIVERS
HP DreamColor panel needs to be controlled via AUX interface. However,
it has both DP_EDP_BACKLIGHT_BRIGHTNESS_AUX_SET_CAP and
DP_EDP_BACKLIGHT_BRIGHTNESS_PWM_PIN_CAP set, so it fails to pass
intel_dp_aux_display_control_capable() test.
Skip the test if the panel has force DPCD quirk.
Signed-off-by: Kai-Heng Feng <kai.heng.feng@canonical.com>
---
drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c | 10 ++++++----
1 file changed, 6 insertions(+), 4 deletions(-)
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 acbd7eb66cbe..acf2e1c65290 100644
--- a/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
+++ b/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
@@ -347,9 +347,13 @@ int intel_dp_aux_init_backlight_funcs(struct intel_connector *intel_connector)
struct intel_panel *panel = &intel_connector->panel;
struct intel_dp *intel_dp = enc_to_intel_dp(intel_connector->encoder);
struct drm_i915_private *i915 = dp_to_i915(intel_dp);
+ bool force_dpcd;
+
+ force_dpcd = drm_dp_has_quirk(&intel_dp->desc, intel_dp->edid_quirks,
+ DP_QUIRK_FORCE_DPCD_BACKLIGHT);
if (i915->params.enable_dpcd_backlight == 0 ||
- !intel_dp_aux_display_control_capable(intel_connector))
+ (!force_dpcd && !intel_dp_aux_display_control_capable(intel_connector)))
return -ENODEV;
/*
@@ -358,9 +362,7 @@ int intel_dp_aux_init_backlight_funcs(struct intel_connector *intel_connector)
*/
if (i915->vbt.backlight.type !=
INTEL_BACKLIGHT_VESA_EDP_AUX_INTERFACE &&
- i915->params.enable_dpcd_backlight != 1 &&
- !drm_dp_has_quirk(&intel_dp->desc, intel_dp->edid_quirks,
- DP_QUIRK_FORCE_DPCD_BACKLIGHT)) {
+ i915->params.enable_dpcd_backlight != 1 && !force_dpcd) {
drm_info(&i915->drm,
"Panel advertises DPCD backlight support, but "
"VBT disagrees. If your backlight controls "
--
2.17.1
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel
^ permalink raw reply related [flat|nested] 19+ messages in thread
* [Intel-gfx] [PATCH 1/2] drm/i915/dpcd_bl: Skip testing control capability with force DPCD quirk
@ 2020-10-07 6:58 ` Kai-Heng Feng
0 siblings, 0 replies; 19+ messages in thread
From: Kai-Heng Feng @ 2020-10-07 6:58 UTC (permalink / raw)
To: Jani Nikula, Joonas Lahtinen, Rodrigo Vivi, David Airlie,
Daniel Vetter, Lyude Paul, Ville Syrjälä,
Juha-Pekka Heikkila, Kai-Heng Feng, intel-gfx,
open list:DRM DRIVERS, open list
Cc: open list, open list:DRM DRIVERS
HP DreamColor panel needs to be controlled via AUX interface. However,
it has both DP_EDP_BACKLIGHT_BRIGHTNESS_AUX_SET_CAP and
DP_EDP_BACKLIGHT_BRIGHTNESS_PWM_PIN_CAP set, so it fails to pass
intel_dp_aux_display_control_capable() test.
Skip the test if the panel has force DPCD quirk.
Signed-off-by: Kai-Heng Feng <kai.heng.feng@canonical.com>
---
drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c | 10 ++++++----
1 file changed, 6 insertions(+), 4 deletions(-)
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 acbd7eb66cbe..acf2e1c65290 100644
--- a/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
+++ b/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
@@ -347,9 +347,13 @@ int intel_dp_aux_init_backlight_funcs(struct intel_connector *intel_connector)
struct intel_panel *panel = &intel_connector->panel;
struct intel_dp *intel_dp = enc_to_intel_dp(intel_connector->encoder);
struct drm_i915_private *i915 = dp_to_i915(intel_dp);
+ bool force_dpcd;
+
+ force_dpcd = drm_dp_has_quirk(&intel_dp->desc, intel_dp->edid_quirks,
+ DP_QUIRK_FORCE_DPCD_BACKLIGHT);
if (i915->params.enable_dpcd_backlight == 0 ||
- !intel_dp_aux_display_control_capable(intel_connector))
+ (!force_dpcd && !intel_dp_aux_display_control_capable(intel_connector)))
return -ENODEV;
/*
@@ -358,9 +362,7 @@ int intel_dp_aux_init_backlight_funcs(struct intel_connector *intel_connector)
*/
if (i915->vbt.backlight.type !=
INTEL_BACKLIGHT_VESA_EDP_AUX_INTERFACE &&
- i915->params.enable_dpcd_backlight != 1 &&
- !drm_dp_has_quirk(&intel_dp->desc, intel_dp->edid_quirks,
- DP_QUIRK_FORCE_DPCD_BACKLIGHT)) {
+ i915->params.enable_dpcd_backlight != 1 && !force_dpcd) {
drm_info(&i915->drm,
"Panel advertises DPCD backlight support, but "
"VBT disagrees. If your backlight controls "
--
2.17.1
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply related [flat|nested] 19+ messages in thread
* [PATCH 2/2] drm/dp: HP DreamColor panel brigntness fix
2020-10-07 6:58 ` Kai-Heng Feng
@ 2020-10-07 6:58 ` Kai-Heng Feng
-1 siblings, 0 replies; 19+ messages in thread
From: Kai-Heng Feng @ 2020-10-07 6:58 UTC (permalink / raw)
To: Maarten Lankhorst, Maxime Ripard, Thomas Zimmermann,
David Airlie, Daniel Vetter, open list:DRM DRIVERS, open list
Cc: Kai-Heng Feng, open list:DRM DRIVERS, open list
HP DreamColor panel, which is used by new HP ZBook Studio, needs to use
DPCD to control brightness.
Signed-off-by: Kai-Heng Feng <kai.heng.feng@canonical.com>
---
drivers/gpu/drm/drm_dp_helper.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/gpu/drm/drm_dp_helper.c b/drivers/gpu/drm/drm_dp_helper.c
index 092c8c985911..b3d0ea1b082b 100644
--- a/drivers/gpu/drm/drm_dp_helper.c
+++ b/drivers/gpu/drm/drm_dp_helper.c
@@ -1321,6 +1321,7 @@ static const struct edid_quirk edid_quirk_list[] = {
*/
{ MFG(0x06, 0xaf), PROD_ID(0x9b, 0x32), BIT(DP_QUIRK_FORCE_DPCD_BACKLIGHT) },
{ MFG(0x06, 0xaf), PROD_ID(0xeb, 0x41), BIT(DP_QUIRK_FORCE_DPCD_BACKLIGHT) },
+ { MFG(0x30, 0xe4), PROD_ID(0x61, 0x06), BIT(DP_QUIRK_FORCE_DPCD_BACKLIGHT) },
{ MFG(0x4d, 0x10), PROD_ID(0xc7, 0x14), BIT(DP_QUIRK_FORCE_DPCD_BACKLIGHT) },
{ MFG(0x4d, 0x10), PROD_ID(0xe6, 0x14), BIT(DP_QUIRK_FORCE_DPCD_BACKLIGHT) },
{ MFG(0x4c, 0x83), PROD_ID(0x47, 0x41), BIT(DP_QUIRK_FORCE_DPCD_BACKLIGHT) },
--
2.17.1
^ permalink raw reply related [flat|nested] 19+ messages in thread
* [PATCH 2/2] drm/dp: HP DreamColor panel brigntness fix
@ 2020-10-07 6:58 ` Kai-Heng Feng
0 siblings, 0 replies; 19+ messages in thread
From: Kai-Heng Feng @ 2020-10-07 6:58 UTC (permalink / raw)
To: Maarten Lankhorst, Maxime Ripard, Thomas Zimmermann,
David Airlie, Daniel Vetter, open list:DRM DRIVERS, open list
Cc: Kai-Heng Feng, open list, open list:DRM DRIVERS
HP DreamColor panel, which is used by new HP ZBook Studio, needs to use
DPCD to control brightness.
Signed-off-by: Kai-Heng Feng <kai.heng.feng@canonical.com>
---
drivers/gpu/drm/drm_dp_helper.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/gpu/drm/drm_dp_helper.c b/drivers/gpu/drm/drm_dp_helper.c
index 092c8c985911..b3d0ea1b082b 100644
--- a/drivers/gpu/drm/drm_dp_helper.c
+++ b/drivers/gpu/drm/drm_dp_helper.c
@@ -1321,6 +1321,7 @@ static const struct edid_quirk edid_quirk_list[] = {
*/
{ MFG(0x06, 0xaf), PROD_ID(0x9b, 0x32), BIT(DP_QUIRK_FORCE_DPCD_BACKLIGHT) },
{ MFG(0x06, 0xaf), PROD_ID(0xeb, 0x41), BIT(DP_QUIRK_FORCE_DPCD_BACKLIGHT) },
+ { MFG(0x30, 0xe4), PROD_ID(0x61, 0x06), BIT(DP_QUIRK_FORCE_DPCD_BACKLIGHT) },
{ MFG(0x4d, 0x10), PROD_ID(0xc7, 0x14), BIT(DP_QUIRK_FORCE_DPCD_BACKLIGHT) },
{ MFG(0x4d, 0x10), PROD_ID(0xe6, 0x14), BIT(DP_QUIRK_FORCE_DPCD_BACKLIGHT) },
{ MFG(0x4c, 0x83), PROD_ID(0x47, 0x41), BIT(DP_QUIRK_FORCE_DPCD_BACKLIGHT) },
--
2.17.1
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel
^ permalink raw reply related [flat|nested] 19+ messages in thread
* Re: [PATCH 1/2] drm/i915/dpcd_bl: Skip testing control capability with force DPCD quirk
2020-10-07 6:58 ` Kai-Heng Feng
(?)
@ 2020-10-07 21:53 ` Lyude Paul
-1 siblings, 0 replies; 19+ messages in thread
From: Lyude Paul @ 2020-10-07 21:53 UTC (permalink / raw)
To: Satadru Pramanik, Kai-Heng Feng, Jani Nikula, Joonas Lahtinen,
Rodrigo Vivi, David Airlie, Daniel Vetter,
Ville Syrjälä,
Juha-Pekka Heikkila, intel-gfx, open list:DRM DRIVERS, open list
Hi! I thought this patch rang a bell, we actually already had some discussion
about this since there's a couple of other systems this was causing issues for.
Unfortunately it never seems like that patch got sent out. Satadru?
(if I don't hear back from them soon, I'll just send out a patch for this
myself)
JFYI - the proper fix here is to just drop the
DP_EDP_BACKLIGHT_BRIGHTNESS_PWM_PIN_CAP check from the code entirely. As long as
the backlight supports AUX_SET_CAP, that should be enough for us to control it.
On Wed, 2020-10-07 at 14:58 +0800, Kai-Heng Feng wrote:
> HP DreamColor panel needs to be controlled via AUX interface. However,
> it has both DP_EDP_BACKLIGHT_BRIGHTNESS_AUX_SET_CAP and
> DP_EDP_BACKLIGHT_BRIGHTNESS_PWM_PIN_CAP set, so it fails to pass
> intel_dp_aux_display_control_capable() test.
>
> Skip the test if the panel has force DPCD quirk.
>
> Signed-off-by: Kai-Heng Feng <kai.heng.feng@canonical.com>
> ---
> drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c | 10 ++++++----
> 1 file changed, 6 insertions(+), 4 deletions(-)
>
> 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 acbd7eb66cbe..acf2e1c65290 100644
> --- a/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
> +++ b/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
> @@ -347,9 +347,13 @@ int intel_dp_aux_init_backlight_funcs(struct
> intel_connector *intel_connector)
> struct intel_panel *panel = &intel_connector->panel;
> struct intel_dp *intel_dp = enc_to_intel_dp(intel_connector->encoder);
> struct drm_i915_private *i915 = dp_to_i915(intel_dp);
> + bool force_dpcd;
> +
> + force_dpcd = drm_dp_has_quirk(&intel_dp->desc, intel_dp->edid_quirks,
> + DP_QUIRK_FORCE_DPCD_BACKLIGHT);
>
> if (i915->params.enable_dpcd_backlight == 0 ||
> - !intel_dp_aux_display_control_capable(intel_connector))
> + (!force_dpcd &&
> !intel_dp_aux_display_control_capable(intel_connector)))
> return -ENODEV;
>
> /*
> @@ -358,9 +362,7 @@ int intel_dp_aux_init_backlight_funcs(struct
> intel_connector *intel_connector)
> */
> if (i915->vbt.backlight.type !=
> INTEL_BACKLIGHT_VESA_EDP_AUX_INTERFACE &&
> - i915->params.enable_dpcd_backlight != 1 &&
> - !drm_dp_has_quirk(&intel_dp->desc, intel_dp->edid_quirks,
> - DP_QUIRK_FORCE_DPCD_BACKLIGHT)) {
> + i915->params.enable_dpcd_backlight != 1 && !force_dpcd) {
> drm_info(&i915->drm,
> "Panel advertises DPCD backlight support, but "
> "VBT disagrees. If your backlight controls "
--
Sincerely,
Lyude Paul (she/her)
Software Engineer at Red Hat
^ permalink raw reply [flat|nested] 19+ messages in thread
* Re: [PATCH 1/2] drm/i915/dpcd_bl: Skip testing control capability with force DPCD quirk
@ 2020-10-07 21:53 ` Lyude Paul
0 siblings, 0 replies; 19+ messages in thread
From: Lyude Paul @ 2020-10-07 21:53 UTC (permalink / raw)
To: Satadru Pramanik, Kai-Heng Feng, Jani Nikula, Joonas Lahtinen,
Rodrigo Vivi, David Airlie, Daniel Vetter,
Ville Syrjälä,
Juha-Pekka Heikkila, intel-gfx, open list:DRM DRIVERS, open list
Hi! I thought this patch rang a bell, we actually already had some discussion
about this since there's a couple of other systems this was causing issues for.
Unfortunately it never seems like that patch got sent out. Satadru?
(if I don't hear back from them soon, I'll just send out a patch for this
myself)
JFYI - the proper fix here is to just drop the
DP_EDP_BACKLIGHT_BRIGHTNESS_PWM_PIN_CAP check from the code entirely. As long as
the backlight supports AUX_SET_CAP, that should be enough for us to control it.
On Wed, 2020-10-07 at 14:58 +0800, Kai-Heng Feng wrote:
> HP DreamColor panel needs to be controlled via AUX interface. However,
> it has both DP_EDP_BACKLIGHT_BRIGHTNESS_AUX_SET_CAP and
> DP_EDP_BACKLIGHT_BRIGHTNESS_PWM_PIN_CAP set, so it fails to pass
> intel_dp_aux_display_control_capable() test.
>
> Skip the test if the panel has force DPCD quirk.
>
> Signed-off-by: Kai-Heng Feng <kai.heng.feng@canonical.com>
> ---
> drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c | 10 ++++++----
> 1 file changed, 6 insertions(+), 4 deletions(-)
>
> 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 acbd7eb66cbe..acf2e1c65290 100644
> --- a/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
> +++ b/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
> @@ -347,9 +347,13 @@ int intel_dp_aux_init_backlight_funcs(struct
> intel_connector *intel_connector)
> struct intel_panel *panel = &intel_connector->panel;
> struct intel_dp *intel_dp = enc_to_intel_dp(intel_connector->encoder);
> struct drm_i915_private *i915 = dp_to_i915(intel_dp);
> + bool force_dpcd;
> +
> + force_dpcd = drm_dp_has_quirk(&intel_dp->desc, intel_dp->edid_quirks,
> + DP_QUIRK_FORCE_DPCD_BACKLIGHT);
>
> if (i915->params.enable_dpcd_backlight == 0 ||
> - !intel_dp_aux_display_control_capable(intel_connector))
> + (!force_dpcd &&
> !intel_dp_aux_display_control_capable(intel_connector)))
> return -ENODEV;
>
> /*
> @@ -358,9 +362,7 @@ int intel_dp_aux_init_backlight_funcs(struct
> intel_connector *intel_connector)
> */
> if (i915->vbt.backlight.type !=
> INTEL_BACKLIGHT_VESA_EDP_AUX_INTERFACE &&
> - i915->params.enable_dpcd_backlight != 1 &&
> - !drm_dp_has_quirk(&intel_dp->desc, intel_dp->edid_quirks,
> - DP_QUIRK_FORCE_DPCD_BACKLIGHT)) {
> + i915->params.enable_dpcd_backlight != 1 && !force_dpcd) {
> drm_info(&i915->drm,
> "Panel advertises DPCD backlight support, but "
> "VBT disagrees. If your backlight controls "
--
Sincerely,
Lyude Paul (she/her)
Software Engineer at Red Hat
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel
^ permalink raw reply [flat|nested] 19+ messages in thread
* Re: [Intel-gfx] [PATCH 1/2] drm/i915/dpcd_bl: Skip testing control capability with force DPCD quirk
@ 2020-10-07 21:53 ` Lyude Paul
0 siblings, 0 replies; 19+ messages in thread
From: Lyude Paul @ 2020-10-07 21:53 UTC (permalink / raw)
To: Satadru Pramanik, Kai-Heng Feng, Jani Nikula, Joonas Lahtinen,
Rodrigo Vivi, David Airlie, Daniel Vetter,
Ville Syrjälä,
Juha-Pekka Heikkila, intel-gfx, open list:DRM DRIVERS, open list
Hi! I thought this patch rang a bell, we actually already had some discussion
about this since there's a couple of other systems this was causing issues for.
Unfortunately it never seems like that patch got sent out. Satadru?
(if I don't hear back from them soon, I'll just send out a patch for this
myself)
JFYI - the proper fix here is to just drop the
DP_EDP_BACKLIGHT_BRIGHTNESS_PWM_PIN_CAP check from the code entirely. As long as
the backlight supports AUX_SET_CAP, that should be enough for us to control it.
On Wed, 2020-10-07 at 14:58 +0800, Kai-Heng Feng wrote:
> HP DreamColor panel needs to be controlled via AUX interface. However,
> it has both DP_EDP_BACKLIGHT_BRIGHTNESS_AUX_SET_CAP and
> DP_EDP_BACKLIGHT_BRIGHTNESS_PWM_PIN_CAP set, so it fails to pass
> intel_dp_aux_display_control_capable() test.
>
> Skip the test if the panel has force DPCD quirk.
>
> Signed-off-by: Kai-Heng Feng <kai.heng.feng@canonical.com>
> ---
> drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c | 10 ++++++----
> 1 file changed, 6 insertions(+), 4 deletions(-)
>
> 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 acbd7eb66cbe..acf2e1c65290 100644
> --- a/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
> +++ b/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
> @@ -347,9 +347,13 @@ int intel_dp_aux_init_backlight_funcs(struct
> intel_connector *intel_connector)
> struct intel_panel *panel = &intel_connector->panel;
> struct intel_dp *intel_dp = enc_to_intel_dp(intel_connector->encoder);
> struct drm_i915_private *i915 = dp_to_i915(intel_dp);
> + bool force_dpcd;
> +
> + force_dpcd = drm_dp_has_quirk(&intel_dp->desc, intel_dp->edid_quirks,
> + DP_QUIRK_FORCE_DPCD_BACKLIGHT);
>
> if (i915->params.enable_dpcd_backlight == 0 ||
> - !intel_dp_aux_display_control_capable(intel_connector))
> + (!force_dpcd &&
> !intel_dp_aux_display_control_capable(intel_connector)))
> return -ENODEV;
>
> /*
> @@ -358,9 +362,7 @@ int intel_dp_aux_init_backlight_funcs(struct
> intel_connector *intel_connector)
> */
> if (i915->vbt.backlight.type !=
> INTEL_BACKLIGHT_VESA_EDP_AUX_INTERFACE &&
> - i915->params.enable_dpcd_backlight != 1 &&
> - !drm_dp_has_quirk(&intel_dp->desc, intel_dp->edid_quirks,
> - DP_QUIRK_FORCE_DPCD_BACKLIGHT)) {
> + i915->params.enable_dpcd_backlight != 1 && !force_dpcd) {
> drm_info(&i915->drm,
> "Panel advertises DPCD backlight support, but "
> "VBT disagrees. If your backlight controls "
--
Sincerely,
Lyude Paul (she/her)
Software Engineer at Red Hat
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply [flat|nested] 19+ messages in thread
* Re: [PATCH 1/2] drm/i915/dpcd_bl: Skip testing control capability with force DPCD quirk
2020-10-07 21:53 ` Lyude Paul
(?)
@ 2020-10-08 2:32 ` Kai-Heng Feng
-1 siblings, 0 replies; 19+ messages in thread
From: Kai-Heng Feng @ 2020-10-08 2:32 UTC (permalink / raw)
To: lyude
Cc: Satadru Pramanik, Jani Nikula, Joonas Lahtinen, Rodrigo Vivi,
David Airlie, Daniel Vetter, Ville Syrjälä,
Juha-Pekka Heikkila, intel-gfx, open list:DRM DRIVERS, open list
Hi Lyude,
> On Oct 8, 2020, at 05:53, Lyude Paul <lyude@redhat.com> wrote:
>
> Hi! I thought this patch rang a bell, we actually already had some discussion
> about this since there's a couple of other systems this was causing issues for.
> Unfortunately it never seems like that patch got sent out. Satadru?
>
> (if I don't hear back from them soon, I'll just send out a patch for this
> myself)
>
> JFYI - the proper fix here is to just drop the
> DP_EDP_BACKLIGHT_BRIGHTNESS_PWM_PIN_CAP check from the code entirely. As long as
> the backlight supports AUX_SET_CAP, that should be enough for us to control it.
Does the proper fix include dropping DP_QUIRK_FORCE_DPCD_BACKLIGHT entirely?
Kai-Heng
>
>
> On Wed, 2020-10-07 at 14:58 +0800, Kai-Heng Feng wrote:
>> HP DreamColor panel needs to be controlled via AUX interface. However,
>> it has both DP_EDP_BACKLIGHT_BRIGHTNESS_AUX_SET_CAP and
>> DP_EDP_BACKLIGHT_BRIGHTNESS_PWM_PIN_CAP set, so it fails to pass
>> intel_dp_aux_display_control_capable() test.
>>
>> Skip the test if the panel has force DPCD quirk.
>>
>> Signed-off-by: Kai-Heng Feng <kai.heng.feng@canonical.com>
>> ---
>> drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c | 10 ++++++----
>> 1 file changed, 6 insertions(+), 4 deletions(-)
>>
>> 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 acbd7eb66cbe..acf2e1c65290 100644
>> --- a/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
>> +++ b/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
>> @@ -347,9 +347,13 @@ int intel_dp_aux_init_backlight_funcs(struct
>> intel_connector *intel_connector)
>> struct intel_panel *panel = &intel_connector->panel;
>> struct intel_dp *intel_dp = enc_to_intel_dp(intel_connector->encoder);
>> struct drm_i915_private *i915 = dp_to_i915(intel_dp);
>> + bool force_dpcd;
>> +
>> + force_dpcd = drm_dp_has_quirk(&intel_dp->desc, intel_dp->edid_quirks,
>> + DP_QUIRK_FORCE_DPCD_BACKLIGHT);
>>
>> if (i915->params.enable_dpcd_backlight == 0 ||
>> - !intel_dp_aux_display_control_capable(intel_connector))
>> + (!force_dpcd &&
>> !intel_dp_aux_display_control_capable(intel_connector)))
>> return -ENODEV;
>>
>> /*
>> @@ -358,9 +362,7 @@ int intel_dp_aux_init_backlight_funcs(struct
>> intel_connector *intel_connector)
>> */
>> if (i915->vbt.backlight.type !=
>> INTEL_BACKLIGHT_VESA_EDP_AUX_INTERFACE &&
>> - i915->params.enable_dpcd_backlight != 1 &&
>> - !drm_dp_has_quirk(&intel_dp->desc, intel_dp->edid_quirks,
>> - DP_QUIRK_FORCE_DPCD_BACKLIGHT)) {
>> + i915->params.enable_dpcd_backlight != 1 && !force_dpcd) {
>> drm_info(&i915->drm,
>> "Panel advertises DPCD backlight support, but "
>> "VBT disagrees. If your backlight controls "
> --
> Sincerely,
> Lyude Paul (she/her)
> Software Engineer at Red Hat
^ permalink raw reply [flat|nested] 19+ messages in thread
* Re: [PATCH 1/2] drm/i915/dpcd_bl: Skip testing control capability with force DPCD quirk
@ 2020-10-08 2:32 ` Kai-Heng Feng
0 siblings, 0 replies; 19+ messages in thread
From: Kai-Heng Feng @ 2020-10-08 2:32 UTC (permalink / raw)
To: lyude
Cc: Juha-Pekka Heikkila, David Airlie, intel-gfx, open list,
open list:DRM DRIVERS, Rodrigo Vivi, Satadru Pramanik
Hi Lyude,
> On Oct 8, 2020, at 05:53, Lyude Paul <lyude@redhat.com> wrote:
>
> Hi! I thought this patch rang a bell, we actually already had some discussion
> about this since there's a couple of other systems this was causing issues for.
> Unfortunately it never seems like that patch got sent out. Satadru?
>
> (if I don't hear back from them soon, I'll just send out a patch for this
> myself)
>
> JFYI - the proper fix here is to just drop the
> DP_EDP_BACKLIGHT_BRIGHTNESS_PWM_PIN_CAP check from the code entirely. As long as
> the backlight supports AUX_SET_CAP, that should be enough for us to control it.
Does the proper fix include dropping DP_QUIRK_FORCE_DPCD_BACKLIGHT entirely?
Kai-Heng
>
>
> On Wed, 2020-10-07 at 14:58 +0800, Kai-Heng Feng wrote:
>> HP DreamColor panel needs to be controlled via AUX interface. However,
>> it has both DP_EDP_BACKLIGHT_BRIGHTNESS_AUX_SET_CAP and
>> DP_EDP_BACKLIGHT_BRIGHTNESS_PWM_PIN_CAP set, so it fails to pass
>> intel_dp_aux_display_control_capable() test.
>>
>> Skip the test if the panel has force DPCD quirk.
>>
>> Signed-off-by: Kai-Heng Feng <kai.heng.feng@canonical.com>
>> ---
>> drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c | 10 ++++++----
>> 1 file changed, 6 insertions(+), 4 deletions(-)
>>
>> 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 acbd7eb66cbe..acf2e1c65290 100644
>> --- a/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
>> +++ b/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
>> @@ -347,9 +347,13 @@ int intel_dp_aux_init_backlight_funcs(struct
>> intel_connector *intel_connector)
>> struct intel_panel *panel = &intel_connector->panel;
>> struct intel_dp *intel_dp = enc_to_intel_dp(intel_connector->encoder);
>> struct drm_i915_private *i915 = dp_to_i915(intel_dp);
>> + bool force_dpcd;
>> +
>> + force_dpcd = drm_dp_has_quirk(&intel_dp->desc, intel_dp->edid_quirks,
>> + DP_QUIRK_FORCE_DPCD_BACKLIGHT);
>>
>> if (i915->params.enable_dpcd_backlight == 0 ||
>> - !intel_dp_aux_display_control_capable(intel_connector))
>> + (!force_dpcd &&
>> !intel_dp_aux_display_control_capable(intel_connector)))
>> return -ENODEV;
>>
>> /*
>> @@ -358,9 +362,7 @@ int intel_dp_aux_init_backlight_funcs(struct
>> intel_connector *intel_connector)
>> */
>> if (i915->vbt.backlight.type !=
>> INTEL_BACKLIGHT_VESA_EDP_AUX_INTERFACE &&
>> - i915->params.enable_dpcd_backlight != 1 &&
>> - !drm_dp_has_quirk(&intel_dp->desc, intel_dp->edid_quirks,
>> - DP_QUIRK_FORCE_DPCD_BACKLIGHT)) {
>> + i915->params.enable_dpcd_backlight != 1 && !force_dpcd) {
>> drm_info(&i915->drm,
>> "Panel advertises DPCD backlight support, but "
>> "VBT disagrees. If your backlight controls "
> --
> Sincerely,
> Lyude Paul (she/her)
> Software Engineer at Red Hat
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel
^ permalink raw reply [flat|nested] 19+ messages in thread
* Re: [Intel-gfx] [PATCH 1/2] drm/i915/dpcd_bl: Skip testing control capability with force DPCD quirk
@ 2020-10-08 2:32 ` Kai-Heng Feng
0 siblings, 0 replies; 19+ messages in thread
From: Kai-Heng Feng @ 2020-10-08 2:32 UTC (permalink / raw)
To: lyude; +Cc: David Airlie, intel-gfx, open list, open list:DRM DRIVERS
Hi Lyude,
> On Oct 8, 2020, at 05:53, Lyude Paul <lyude@redhat.com> wrote:
>
> Hi! I thought this patch rang a bell, we actually already had some discussion
> about this since there's a couple of other systems this was causing issues for.
> Unfortunately it never seems like that patch got sent out. Satadru?
>
> (if I don't hear back from them soon, I'll just send out a patch for this
> myself)
>
> JFYI - the proper fix here is to just drop the
> DP_EDP_BACKLIGHT_BRIGHTNESS_PWM_PIN_CAP check from the code entirely. As long as
> the backlight supports AUX_SET_CAP, that should be enough for us to control it.
Does the proper fix include dropping DP_QUIRK_FORCE_DPCD_BACKLIGHT entirely?
Kai-Heng
>
>
> On Wed, 2020-10-07 at 14:58 +0800, Kai-Heng Feng wrote:
>> HP DreamColor panel needs to be controlled via AUX interface. However,
>> it has both DP_EDP_BACKLIGHT_BRIGHTNESS_AUX_SET_CAP and
>> DP_EDP_BACKLIGHT_BRIGHTNESS_PWM_PIN_CAP set, so it fails to pass
>> intel_dp_aux_display_control_capable() test.
>>
>> Skip the test if the panel has force DPCD quirk.
>>
>> Signed-off-by: Kai-Heng Feng <kai.heng.feng@canonical.com>
>> ---
>> drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c | 10 ++++++----
>> 1 file changed, 6 insertions(+), 4 deletions(-)
>>
>> 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 acbd7eb66cbe..acf2e1c65290 100644
>> --- a/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
>> +++ b/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
>> @@ -347,9 +347,13 @@ int intel_dp_aux_init_backlight_funcs(struct
>> intel_connector *intel_connector)
>> struct intel_panel *panel = &intel_connector->panel;
>> struct intel_dp *intel_dp = enc_to_intel_dp(intel_connector->encoder);
>> struct drm_i915_private *i915 = dp_to_i915(intel_dp);
>> + bool force_dpcd;
>> +
>> + force_dpcd = drm_dp_has_quirk(&intel_dp->desc, intel_dp->edid_quirks,
>> + DP_QUIRK_FORCE_DPCD_BACKLIGHT);
>>
>> if (i915->params.enable_dpcd_backlight == 0 ||
>> - !intel_dp_aux_display_control_capable(intel_connector))
>> + (!force_dpcd &&
>> !intel_dp_aux_display_control_capable(intel_connector)))
>> return -ENODEV;
>>
>> /*
>> @@ -358,9 +362,7 @@ int intel_dp_aux_init_backlight_funcs(struct
>> intel_connector *intel_connector)
>> */
>> if (i915->vbt.backlight.type !=
>> INTEL_BACKLIGHT_VESA_EDP_AUX_INTERFACE &&
>> - i915->params.enable_dpcd_backlight != 1 &&
>> - !drm_dp_has_quirk(&intel_dp->desc, intel_dp->edid_quirks,
>> - DP_QUIRK_FORCE_DPCD_BACKLIGHT)) {
>> + i915->params.enable_dpcd_backlight != 1 && !force_dpcd) {
>> drm_info(&i915->drm,
>> "Panel advertises DPCD backlight support, but "
>> "VBT disagrees. If your backlight controls "
> --
> Sincerely,
> Lyude Paul (she/her)
> Software Engineer at Red Hat
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply [flat|nested] 19+ messages in thread
* Re: [PATCH 1/2] drm/i915/dpcd_bl: Skip testing control capability with force DPCD quirk
2020-10-08 2:32 ` Kai-Heng Feng
(?)
@ 2020-10-08 16:39 ` Lyude Paul
-1 siblings, 0 replies; 19+ messages in thread
From: Lyude Paul @ 2020-10-08 16:39 UTC (permalink / raw)
To: Kai-Heng Feng
Cc: Satadru Pramanik, Jani Nikula, Joonas Lahtinen, Rodrigo Vivi,
David Airlie, Daniel Vetter, Ville Syrjälä,
Juha-Pekka Heikkila, intel-gfx, open list:DRM DRIVERS, open list
On Thu, 2020-10-08 at 10:32 +0800, Kai-Heng Feng wrote:
> Hi Lyude,
>
> > On Oct 8, 2020, at 05:53, Lyude Paul <lyude@redhat.com> wrote:
> >
> > Hi! I thought this patch rang a bell, we actually already had some
> > discussion
> > about this since there's a couple of other systems this was causing issues
> > for.
> > Unfortunately it never seems like that patch got sent out. Satadru?
> >
> > (if I don't hear back from them soon, I'll just send out a patch for this
> > myself)
> >
> > JFYI - the proper fix here is to just drop the
> > DP_EDP_BACKLIGHT_BRIGHTNESS_PWM_PIN_CAP check from the code entirely. As
> > long as
> > the backlight supports AUX_SET_CAP, that should be enough for us to control
> > it.
>
> Does the proper fix include dropping DP_QUIRK_FORCE_DPCD_BACKLIGHT entirely?\
Not yet - we need someone to help with reviewing my Intel HDR backlight
interface patches before we can drop that. I was just talking about dropping the
check where we don't enable the DPCD backlight if it claims to support
DP_EDP_BACKLIGHT_BRIGHTNESS_PWM_PIN_CAP
>
> Kai-Heng
>
> >
> > On Wed, 2020-10-07 at 14:58 +0800, Kai-Heng Feng wrote:
> > > HP DreamColor panel needs to be controlled via AUX interface. However,
> > > it has both DP_EDP_BACKLIGHT_BRIGHTNESS_AUX_SET_CAP and
> > > DP_EDP_BACKLIGHT_BRIGHTNESS_PWM_PIN_CAP set, so it fails to pass
> > > intel_dp_aux_display_control_capable() test.
> > >
> > > Skip the test if the panel has force DPCD quirk.
> > >
> > > Signed-off-by: Kai-Heng Feng <kai.heng.feng@canonical.com>
> > > ---
> > > drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c | 10 ++++++----
> > > 1 file changed, 6 insertions(+), 4 deletions(-)
> > >
> > > 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 acbd7eb66cbe..acf2e1c65290 100644
> > > --- a/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
> > > +++ b/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
> > > @@ -347,9 +347,13 @@ int intel_dp_aux_init_backlight_funcs(struct
> > > intel_connector *intel_connector)
> > > struct intel_panel *panel = &intel_connector->panel;
> > > struct intel_dp *intel_dp = enc_to_intel_dp(intel_connector->encoder);
> > > struct drm_i915_private *i915 = dp_to_i915(intel_dp);
> > > + bool force_dpcd;
> > > +
> > > + force_dpcd = drm_dp_has_quirk(&intel_dp->desc, intel_dp->edid_quirks,
> > > + DP_QUIRK_FORCE_DPCD_BACKLIGHT);
> > >
> > > if (i915->params.enable_dpcd_backlight == 0 ||
> > > - !intel_dp_aux_display_control_capable(intel_connector))
> > > + (!force_dpcd &&
> > > !intel_dp_aux_display_control_capable(intel_connector)))
> > > return -ENODEV;
> > >
> > > /*
> > > @@ -358,9 +362,7 @@ int intel_dp_aux_init_backlight_funcs(struct
> > > intel_connector *intel_connector)
> > > */
> > > if (i915->vbt.backlight.type !=
> > > INTEL_BACKLIGHT_VESA_EDP_AUX_INTERFACE &&
> > > - i915->params.enable_dpcd_backlight != 1 &&
> > > - !drm_dp_has_quirk(&intel_dp->desc, intel_dp->edid_quirks,
> > > - DP_QUIRK_FORCE_DPCD_BACKLIGHT)) {
> > > + i915->params.enable_dpcd_backlight != 1 && !force_dpcd) {
> > > drm_info(&i915->drm,
> > > "Panel advertises DPCD backlight support, but "
> > > "VBT disagrees. If your backlight controls "
> > --
> > Sincerely,
> > Lyude Paul (she/her)
> > Software Engineer at Red Hat
--
Sincerely,
Lyude Paul (she/her)
Software Engineer at Red Hat
^ permalink raw reply [flat|nested] 19+ messages in thread
* Re: [PATCH 1/2] drm/i915/dpcd_bl: Skip testing control capability with force DPCD quirk
@ 2020-10-08 16:39 ` Lyude Paul
0 siblings, 0 replies; 19+ messages in thread
From: Lyude Paul @ 2020-10-08 16:39 UTC (permalink / raw)
To: Kai-Heng Feng
Cc: Juha-Pekka Heikkila, David Airlie, intel-gfx, open list,
open list:DRM DRIVERS, Rodrigo Vivi, Satadru Pramanik
On Thu, 2020-10-08 at 10:32 +0800, Kai-Heng Feng wrote:
> Hi Lyude,
>
> > On Oct 8, 2020, at 05:53, Lyude Paul <lyude@redhat.com> wrote:
> >
> > Hi! I thought this patch rang a bell, we actually already had some
> > discussion
> > about this since there's a couple of other systems this was causing issues
> > for.
> > Unfortunately it never seems like that patch got sent out. Satadru?
> >
> > (if I don't hear back from them soon, I'll just send out a patch for this
> > myself)
> >
> > JFYI - the proper fix here is to just drop the
> > DP_EDP_BACKLIGHT_BRIGHTNESS_PWM_PIN_CAP check from the code entirely. As
> > long as
> > the backlight supports AUX_SET_CAP, that should be enough for us to control
> > it.
>
> Does the proper fix include dropping DP_QUIRK_FORCE_DPCD_BACKLIGHT entirely?\
Not yet - we need someone to help with reviewing my Intel HDR backlight
interface patches before we can drop that. I was just talking about dropping the
check where we don't enable the DPCD backlight if it claims to support
DP_EDP_BACKLIGHT_BRIGHTNESS_PWM_PIN_CAP
>
> Kai-Heng
>
> >
> > On Wed, 2020-10-07 at 14:58 +0800, Kai-Heng Feng wrote:
> > > HP DreamColor panel needs to be controlled via AUX interface. However,
> > > it has both DP_EDP_BACKLIGHT_BRIGHTNESS_AUX_SET_CAP and
> > > DP_EDP_BACKLIGHT_BRIGHTNESS_PWM_PIN_CAP set, so it fails to pass
> > > intel_dp_aux_display_control_capable() test.
> > >
> > > Skip the test if the panel has force DPCD quirk.
> > >
> > > Signed-off-by: Kai-Heng Feng <kai.heng.feng@canonical.com>
> > > ---
> > > drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c | 10 ++++++----
> > > 1 file changed, 6 insertions(+), 4 deletions(-)
> > >
> > > 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 acbd7eb66cbe..acf2e1c65290 100644
> > > --- a/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
> > > +++ b/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
> > > @@ -347,9 +347,13 @@ int intel_dp_aux_init_backlight_funcs(struct
> > > intel_connector *intel_connector)
> > > struct intel_panel *panel = &intel_connector->panel;
> > > struct intel_dp *intel_dp = enc_to_intel_dp(intel_connector->encoder);
> > > struct drm_i915_private *i915 = dp_to_i915(intel_dp);
> > > + bool force_dpcd;
> > > +
> > > + force_dpcd = drm_dp_has_quirk(&intel_dp->desc, intel_dp->edid_quirks,
> > > + DP_QUIRK_FORCE_DPCD_BACKLIGHT);
> > >
> > > if (i915->params.enable_dpcd_backlight == 0 ||
> > > - !intel_dp_aux_display_control_capable(intel_connector))
> > > + (!force_dpcd &&
> > > !intel_dp_aux_display_control_capable(intel_connector)))
> > > return -ENODEV;
> > >
> > > /*
> > > @@ -358,9 +362,7 @@ int intel_dp_aux_init_backlight_funcs(struct
> > > intel_connector *intel_connector)
> > > */
> > > if (i915->vbt.backlight.type !=
> > > INTEL_BACKLIGHT_VESA_EDP_AUX_INTERFACE &&
> > > - i915->params.enable_dpcd_backlight != 1 &&
> > > - !drm_dp_has_quirk(&intel_dp->desc, intel_dp->edid_quirks,
> > > - DP_QUIRK_FORCE_DPCD_BACKLIGHT)) {
> > > + i915->params.enable_dpcd_backlight != 1 && !force_dpcd) {
> > > drm_info(&i915->drm,
> > > "Panel advertises DPCD backlight support, but "
> > > "VBT disagrees. If your backlight controls "
> > --
> > Sincerely,
> > Lyude Paul (she/her)
> > Software Engineer at Red Hat
--
Sincerely,
Lyude Paul (she/her)
Software Engineer at Red Hat
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel
^ permalink raw reply [flat|nested] 19+ messages in thread
* Re: [Intel-gfx] [PATCH 1/2] drm/i915/dpcd_bl: Skip testing control capability with force DPCD quirk
@ 2020-10-08 16:39 ` Lyude Paul
0 siblings, 0 replies; 19+ messages in thread
From: Lyude Paul @ 2020-10-08 16:39 UTC (permalink / raw)
To: Kai-Heng Feng; +Cc: David Airlie, intel-gfx, open list, open list:DRM DRIVERS
On Thu, 2020-10-08 at 10:32 +0800, Kai-Heng Feng wrote:
> Hi Lyude,
>
> > On Oct 8, 2020, at 05:53, Lyude Paul <lyude@redhat.com> wrote:
> >
> > Hi! I thought this patch rang a bell, we actually already had some
> > discussion
> > about this since there's a couple of other systems this was causing issues
> > for.
> > Unfortunately it never seems like that patch got sent out. Satadru?
> >
> > (if I don't hear back from them soon, I'll just send out a patch for this
> > myself)
> >
> > JFYI - the proper fix here is to just drop the
> > DP_EDP_BACKLIGHT_BRIGHTNESS_PWM_PIN_CAP check from the code entirely. As
> > long as
> > the backlight supports AUX_SET_CAP, that should be enough for us to control
> > it.
>
> Does the proper fix include dropping DP_QUIRK_FORCE_DPCD_BACKLIGHT entirely?\
Not yet - we need someone to help with reviewing my Intel HDR backlight
interface patches before we can drop that. I was just talking about dropping the
check where we don't enable the DPCD backlight if it claims to support
DP_EDP_BACKLIGHT_BRIGHTNESS_PWM_PIN_CAP
>
> Kai-Heng
>
> >
> > On Wed, 2020-10-07 at 14:58 +0800, Kai-Heng Feng wrote:
> > > HP DreamColor panel needs to be controlled via AUX interface. However,
> > > it has both DP_EDP_BACKLIGHT_BRIGHTNESS_AUX_SET_CAP and
> > > DP_EDP_BACKLIGHT_BRIGHTNESS_PWM_PIN_CAP set, so it fails to pass
> > > intel_dp_aux_display_control_capable() test.
> > >
> > > Skip the test if the panel has force DPCD quirk.
> > >
> > > Signed-off-by: Kai-Heng Feng <kai.heng.feng@canonical.com>
> > > ---
> > > drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c | 10 ++++++----
> > > 1 file changed, 6 insertions(+), 4 deletions(-)
> > >
> > > 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 acbd7eb66cbe..acf2e1c65290 100644
> > > --- a/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
> > > +++ b/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
> > > @@ -347,9 +347,13 @@ int intel_dp_aux_init_backlight_funcs(struct
> > > intel_connector *intel_connector)
> > > struct intel_panel *panel = &intel_connector->panel;
> > > struct intel_dp *intel_dp = enc_to_intel_dp(intel_connector->encoder);
> > > struct drm_i915_private *i915 = dp_to_i915(intel_dp);
> > > + bool force_dpcd;
> > > +
> > > + force_dpcd = drm_dp_has_quirk(&intel_dp->desc, intel_dp->edid_quirks,
> > > + DP_QUIRK_FORCE_DPCD_BACKLIGHT);
> > >
> > > if (i915->params.enable_dpcd_backlight == 0 ||
> > > - !intel_dp_aux_display_control_capable(intel_connector))
> > > + (!force_dpcd &&
> > > !intel_dp_aux_display_control_capable(intel_connector)))
> > > return -ENODEV;
> > >
> > > /*
> > > @@ -358,9 +362,7 @@ int intel_dp_aux_init_backlight_funcs(struct
> > > intel_connector *intel_connector)
> > > */
> > > if (i915->vbt.backlight.type !=
> > > INTEL_BACKLIGHT_VESA_EDP_AUX_INTERFACE &&
> > > - i915->params.enable_dpcd_backlight != 1 &&
> > > - !drm_dp_has_quirk(&intel_dp->desc, intel_dp->edid_quirks,
> > > - DP_QUIRK_FORCE_DPCD_BACKLIGHT)) {
> > > + i915->params.enable_dpcd_backlight != 1 && !force_dpcd) {
> > > drm_info(&i915->drm,
> > > "Panel advertises DPCD backlight support, but "
> > > "VBT disagrees. If your backlight controls "
> > --
> > Sincerely,
> > Lyude Paul (she/her)
> > Software Engineer at Red Hat
--
Sincerely,
Lyude Paul (she/her)
Software Engineer at Red Hat
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply [flat|nested] 19+ messages in thread
* Re: [PATCH 1/2] drm/i915/dpcd_bl: Skip testing control capability with force DPCD quirk
2020-10-08 2:32 ` Kai-Heng Feng
(?)
@ 2020-10-08 17:06 ` Lyude Paul
-1 siblings, 0 replies; 19+ messages in thread
From: Lyude Paul @ 2020-10-08 17:06 UTC (permalink / raw)
To: Kai-Heng Feng
Cc: Satadru Pramanik, Jani Nikula, Joonas Lahtinen, Rodrigo Vivi,
David Airlie, Daniel Vetter, Ville Syrjälä,
Juha-Pekka Heikkila, intel-gfx, open list:DRM DRIVERS, open list
oh hold on, I misspoke. Here's the patch I was thinking of:
https://patchwork.freedesktop.org/series/82041/
On Thu, 2020-10-08 at 10:32 +0800, Kai-Heng Feng wrote:
> Hi Lyude,
>
> > On Oct 8, 2020, at 05:53, Lyude Paul <lyude@redhat.com> wrote:
> >
> > Hi! I thought this patch rang a bell, we actually already had some
> > discussion
> > about this since there's a couple of other systems this was causing issues
> > for.
> > Unfortunately it never seems like that patch got sent out. Satadru?
> >
> > (if I don't hear back from them soon, I'll just send out a patch for this
> > myself)
> >
> > JFYI - the proper fix here is to just drop the
> > DP_EDP_BACKLIGHT_BRIGHTNESS_PWM_PIN_CAP check from the code entirely. As
> > long as
> > the backlight supports AUX_SET_CAP, that should be enough for us to control
> > it.
>
> Does the proper fix include dropping DP_QUIRK_FORCE_DPCD_BACKLIGHT entirely?
>
> Kai-Heng
>
> >
> > On Wed, 2020-10-07 at 14:58 +0800, Kai-Heng Feng wrote:
> > > HP DreamColor panel needs to be controlled via AUX interface. However,
> > > it has both DP_EDP_BACKLIGHT_BRIGHTNESS_AUX_SET_CAP and
> > > DP_EDP_BACKLIGHT_BRIGHTNESS_PWM_PIN_CAP set, so it fails to pass
> > > intel_dp_aux_display_control_capable() test.
> > >
> > > Skip the test if the panel has force DPCD quirk.
> > >
> > > Signed-off-by: Kai-Heng Feng <kai.heng.feng@canonical.com>
> > > ---
> > > drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c | 10 ++++++----
> > > 1 file changed, 6 insertions(+), 4 deletions(-)
> > >
> > > 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 acbd7eb66cbe..acf2e1c65290 100644
> > > --- a/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
> > > +++ b/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
> > > @@ -347,9 +347,13 @@ int intel_dp_aux_init_backlight_funcs(struct
> > > intel_connector *intel_connector)
> > > struct intel_panel *panel = &intel_connector->panel;
> > > struct intel_dp *intel_dp = enc_to_intel_dp(intel_connector->encoder);
> > > struct drm_i915_private *i915 = dp_to_i915(intel_dp);
> > > + bool force_dpcd;
> > > +
> > > + force_dpcd = drm_dp_has_quirk(&intel_dp->desc, intel_dp->edid_quirks,
> > > + DP_QUIRK_FORCE_DPCD_BACKLIGHT);
> > >
> > > if (i915->params.enable_dpcd_backlight == 0 ||
> > > - !intel_dp_aux_display_control_capable(intel_connector))
> > > + (!force_dpcd &&
> > > !intel_dp_aux_display_control_capable(intel_connector)))
> > > return -ENODEV;
> > >
> > > /*
> > > @@ -358,9 +362,7 @@ int intel_dp_aux_init_backlight_funcs(struct
> > > intel_connector *intel_connector)
> > > */
> > > if (i915->vbt.backlight.type !=
> > > INTEL_BACKLIGHT_VESA_EDP_AUX_INTERFACE &&
> > > - i915->params.enable_dpcd_backlight != 1 &&
> > > - !drm_dp_has_quirk(&intel_dp->desc, intel_dp->edid_quirks,
> > > - DP_QUIRK_FORCE_DPCD_BACKLIGHT)) {
> > > + i915->params.enable_dpcd_backlight != 1 && !force_dpcd) {
> > > drm_info(&i915->drm,
> > > "Panel advertises DPCD backlight support, but "
> > > "VBT disagrees. If your backlight controls "
> > --
> > Sincerely,
> > Lyude Paul (she/her)
> > Software Engineer at Red Hat
--
Sincerely,
Lyude Paul (she/her)
Software Engineer at Red Hat
^ permalink raw reply [flat|nested] 19+ messages in thread
* Re: [PATCH 1/2] drm/i915/dpcd_bl: Skip testing control capability with force DPCD quirk
@ 2020-10-08 17:06 ` Lyude Paul
0 siblings, 0 replies; 19+ messages in thread
From: Lyude Paul @ 2020-10-08 17:06 UTC (permalink / raw)
To: Kai-Heng Feng
Cc: Juha-Pekka Heikkila, David Airlie, intel-gfx, open list,
open list:DRM DRIVERS, Rodrigo Vivi, Satadru Pramanik
oh hold on, I misspoke. Here's the patch I was thinking of:
https://patchwork.freedesktop.org/series/82041/
On Thu, 2020-10-08 at 10:32 +0800, Kai-Heng Feng wrote:
> Hi Lyude,
>
> > On Oct 8, 2020, at 05:53, Lyude Paul <lyude@redhat.com> wrote:
> >
> > Hi! I thought this patch rang a bell, we actually already had some
> > discussion
> > about this since there's a couple of other systems this was causing issues
> > for.
> > Unfortunately it never seems like that patch got sent out. Satadru?
> >
> > (if I don't hear back from them soon, I'll just send out a patch for this
> > myself)
> >
> > JFYI - the proper fix here is to just drop the
> > DP_EDP_BACKLIGHT_BRIGHTNESS_PWM_PIN_CAP check from the code entirely. As
> > long as
> > the backlight supports AUX_SET_CAP, that should be enough for us to control
> > it.
>
> Does the proper fix include dropping DP_QUIRK_FORCE_DPCD_BACKLIGHT entirely?
>
> Kai-Heng
>
> >
> > On Wed, 2020-10-07 at 14:58 +0800, Kai-Heng Feng wrote:
> > > HP DreamColor panel needs to be controlled via AUX interface. However,
> > > it has both DP_EDP_BACKLIGHT_BRIGHTNESS_AUX_SET_CAP and
> > > DP_EDP_BACKLIGHT_BRIGHTNESS_PWM_PIN_CAP set, so it fails to pass
> > > intel_dp_aux_display_control_capable() test.
> > >
> > > Skip the test if the panel has force DPCD quirk.
> > >
> > > Signed-off-by: Kai-Heng Feng <kai.heng.feng@canonical.com>
> > > ---
> > > drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c | 10 ++++++----
> > > 1 file changed, 6 insertions(+), 4 deletions(-)
> > >
> > > 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 acbd7eb66cbe..acf2e1c65290 100644
> > > --- a/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
> > > +++ b/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
> > > @@ -347,9 +347,13 @@ int intel_dp_aux_init_backlight_funcs(struct
> > > intel_connector *intel_connector)
> > > struct intel_panel *panel = &intel_connector->panel;
> > > struct intel_dp *intel_dp = enc_to_intel_dp(intel_connector->encoder);
> > > struct drm_i915_private *i915 = dp_to_i915(intel_dp);
> > > + bool force_dpcd;
> > > +
> > > + force_dpcd = drm_dp_has_quirk(&intel_dp->desc, intel_dp->edid_quirks,
> > > + DP_QUIRK_FORCE_DPCD_BACKLIGHT);
> > >
> > > if (i915->params.enable_dpcd_backlight == 0 ||
> > > - !intel_dp_aux_display_control_capable(intel_connector))
> > > + (!force_dpcd &&
> > > !intel_dp_aux_display_control_capable(intel_connector)))
> > > return -ENODEV;
> > >
> > > /*
> > > @@ -358,9 +362,7 @@ int intel_dp_aux_init_backlight_funcs(struct
> > > intel_connector *intel_connector)
> > > */
> > > if (i915->vbt.backlight.type !=
> > > INTEL_BACKLIGHT_VESA_EDP_AUX_INTERFACE &&
> > > - i915->params.enable_dpcd_backlight != 1 &&
> > > - !drm_dp_has_quirk(&intel_dp->desc, intel_dp->edid_quirks,
> > > - DP_QUIRK_FORCE_DPCD_BACKLIGHT)) {
> > > + i915->params.enable_dpcd_backlight != 1 && !force_dpcd) {
> > > drm_info(&i915->drm,
> > > "Panel advertises DPCD backlight support, but "
> > > "VBT disagrees. If your backlight controls "
> > --
> > Sincerely,
> > Lyude Paul (she/her)
> > Software Engineer at Red Hat
--
Sincerely,
Lyude Paul (she/her)
Software Engineer at Red Hat
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel
^ permalink raw reply [flat|nested] 19+ messages in thread
* Re: [Intel-gfx] [PATCH 1/2] drm/i915/dpcd_bl: Skip testing control capability with force DPCD quirk
@ 2020-10-08 17:06 ` Lyude Paul
0 siblings, 0 replies; 19+ messages in thread
From: Lyude Paul @ 2020-10-08 17:06 UTC (permalink / raw)
To: Kai-Heng Feng; +Cc: David Airlie, intel-gfx, open list, open list:DRM DRIVERS
oh hold on, I misspoke. Here's the patch I was thinking of:
https://patchwork.freedesktop.org/series/82041/
On Thu, 2020-10-08 at 10:32 +0800, Kai-Heng Feng wrote:
> Hi Lyude,
>
> > On Oct 8, 2020, at 05:53, Lyude Paul <lyude@redhat.com> wrote:
> >
> > Hi! I thought this patch rang a bell, we actually already had some
> > discussion
> > about this since there's a couple of other systems this was causing issues
> > for.
> > Unfortunately it never seems like that patch got sent out. Satadru?
> >
> > (if I don't hear back from them soon, I'll just send out a patch for this
> > myself)
> >
> > JFYI - the proper fix here is to just drop the
> > DP_EDP_BACKLIGHT_BRIGHTNESS_PWM_PIN_CAP check from the code entirely. As
> > long as
> > the backlight supports AUX_SET_CAP, that should be enough for us to control
> > it.
>
> Does the proper fix include dropping DP_QUIRK_FORCE_DPCD_BACKLIGHT entirely?
>
> Kai-Heng
>
> >
> > On Wed, 2020-10-07 at 14:58 +0800, Kai-Heng Feng wrote:
> > > HP DreamColor panel needs to be controlled via AUX interface. However,
> > > it has both DP_EDP_BACKLIGHT_BRIGHTNESS_AUX_SET_CAP and
> > > DP_EDP_BACKLIGHT_BRIGHTNESS_PWM_PIN_CAP set, so it fails to pass
> > > intel_dp_aux_display_control_capable() test.
> > >
> > > Skip the test if the panel has force DPCD quirk.
> > >
> > > Signed-off-by: Kai-Heng Feng <kai.heng.feng@canonical.com>
> > > ---
> > > drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c | 10 ++++++----
> > > 1 file changed, 6 insertions(+), 4 deletions(-)
> > >
> > > 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 acbd7eb66cbe..acf2e1c65290 100644
> > > --- a/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
> > > +++ b/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
> > > @@ -347,9 +347,13 @@ int intel_dp_aux_init_backlight_funcs(struct
> > > intel_connector *intel_connector)
> > > struct intel_panel *panel = &intel_connector->panel;
> > > struct intel_dp *intel_dp = enc_to_intel_dp(intel_connector->encoder);
> > > struct drm_i915_private *i915 = dp_to_i915(intel_dp);
> > > + bool force_dpcd;
> > > +
> > > + force_dpcd = drm_dp_has_quirk(&intel_dp->desc, intel_dp->edid_quirks,
> > > + DP_QUIRK_FORCE_DPCD_BACKLIGHT);
> > >
> > > if (i915->params.enable_dpcd_backlight == 0 ||
> > > - !intel_dp_aux_display_control_capable(intel_connector))
> > > + (!force_dpcd &&
> > > !intel_dp_aux_display_control_capable(intel_connector)))
> > > return -ENODEV;
> > >
> > > /*
> > > @@ -358,9 +362,7 @@ int intel_dp_aux_init_backlight_funcs(struct
> > > intel_connector *intel_connector)
> > > */
> > > if (i915->vbt.backlight.type !=
> > > INTEL_BACKLIGHT_VESA_EDP_AUX_INTERFACE &&
> > > - i915->params.enable_dpcd_backlight != 1 &&
> > > - !drm_dp_has_quirk(&intel_dp->desc, intel_dp->edid_quirks,
> > > - DP_QUIRK_FORCE_DPCD_BACKLIGHT)) {
> > > + i915->params.enable_dpcd_backlight != 1 && !force_dpcd) {
> > > drm_info(&i915->drm,
> > > "Panel advertises DPCD backlight support, but "
> > > "VBT disagrees. If your backlight controls "
> > --
> > Sincerely,
> > Lyude Paul (she/her)
> > Software Engineer at Red Hat
--
Sincerely,
Lyude Paul (she/her)
Software Engineer at Red Hat
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply [flat|nested] 19+ messages in thread
* Re: [PATCH 1/2] drm/i915/dpcd_bl: Skip testing control capability with force DPCD quirk
2020-10-08 17:06 ` Lyude Paul
@ 2020-10-08 21:32 ` Satadru Pramanik
-1 siblings, 0 replies; 19+ messages in thread
From: Satadru Pramanik @ 2020-10-08 21:32 UTC (permalink / raw)
To: Lyude Paul, Kevin Chowski
Cc: Juha-Pekka Heikkila, David Airlie, intel-gfx, open list,
Kai-Heng Feng, open list:DRM DRIVERS, Rodrigo Vivi
[-- Attachment #1.1: Type: text/plain, Size: 3980 bytes --]
Kevin Chowski said he would be geting to working on upstreaming a version
of that which was in the ChromeOS tree here:
https://chromium-review.googlesource.com/c/chromiumos/third_party/kernel/+/2344844
when I last spoke to hi
(This was two weeks ago.)
Kevin - do you have any input on this?
Satadru
On Thu, Oct 8, 2020 at 1:07 PM Lyude Paul <lyude@redhat.com> wrote:
> oh hold on, I misspoke. Here's the patch I was thinking of:
>
> https://patchwork.freedesktop.org/series/82041/
>
> On Thu, 2020-10-08 at 10:32 +0800, Kai-Heng Feng wrote:
> > Hi Lyude,
> >
> > > On Oct 8, 2020, at 05:53, Lyude Paul <lyude@redhat.com> wrote:
> > >
> > > Hi! I thought this patch rang a bell, we actually already had some
> > > discussion
> > > about this since there's a couple of other systems this was causing
> issues
> > > for.
> > > Unfortunately it never seems like that patch got sent out. Satadru?
> > >
> > > (if I don't hear back from them soon, I'll just send out a patch for
> this
> > > myself)
> > >
> > > JFYI - the proper fix here is to just drop the
> > > DP_EDP_BACKLIGHT_BRIGHTNESS_PWM_PIN_CAP check from the code entirely.
> As
> > > long as
> > > the backlight supports AUX_SET_CAP, that should be enough for us to
> control
> > > it.
> >
> > Does the proper fix include dropping DP_QUIRK_FORCE_DPCD_BACKLIGHT
> entirely?
> >
> > Kai-Heng
> >
> > >
> > > On Wed, 2020-10-07 at 14:58 +0800, Kai-Heng Feng wrote:
> > > > HP DreamColor panel needs to be controlled via AUX interface.
> However,
> > > > it has both DP_EDP_BACKLIGHT_BRIGHTNESS_AUX_SET_CAP and
> > > > DP_EDP_BACKLIGHT_BRIGHTNESS_PWM_PIN_CAP set, so it fails to pass
> > > > intel_dp_aux_display_control_capable() test.
> > > >
> > > > Skip the test if the panel has force DPCD quirk.
> > > >
> > > > Signed-off-by: Kai-Heng Feng <kai.heng.feng@canonical.com>
> > > > ---
> > > > drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c | 10 ++++++----
> > > > 1 file changed, 6 insertions(+), 4 deletions(-)
> > > >
> > > > 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 acbd7eb66cbe..acf2e1c65290 100644
> > > > --- a/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
> > > > +++ b/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
> > > > @@ -347,9 +347,13 @@ int intel_dp_aux_init_backlight_funcs(struct
> > > > intel_connector *intel_connector)
> > > > struct intel_panel *panel = &intel_connector->panel;
> > > > struct intel_dp *intel_dp =
> enc_to_intel_dp(intel_connector->encoder);
> > > > struct drm_i915_private *i915 = dp_to_i915(intel_dp);
> > > > + bool force_dpcd;
> > > > +
> > > > + force_dpcd = drm_dp_has_quirk(&intel_dp->desc,
> intel_dp->edid_quirks,
> > > > + DP_QUIRK_FORCE_DPCD_BACKLIGHT);
> > > >
> > > > if (i915->params.enable_dpcd_backlight == 0 ||
> > > > - !intel_dp_aux_display_control_capable(intel_connector))
> > > > + (!force_dpcd &&
> > > > !intel_dp_aux_display_control_capable(intel_connector)))
> > > > return -ENODEV;
> > > >
> > > > /*
> > > > @@ -358,9 +362,7 @@ int intel_dp_aux_init_backlight_funcs(struct
> > > > intel_connector *intel_connector)
> > > > */
> > > > if (i915->vbt.backlight.type !=
> > > > INTEL_BACKLIGHT_VESA_EDP_AUX_INTERFACE &&
> > > > - i915->params.enable_dpcd_backlight != 1 &&
> > > > - !drm_dp_has_quirk(&intel_dp->desc, intel_dp->edid_quirks,
> > > > - DP_QUIRK_FORCE_DPCD_BACKLIGHT)) {
> > > > + i915->params.enable_dpcd_backlight != 1 && !force_dpcd) {
> > > > drm_info(&i915->drm,
> > > > "Panel advertises DPCD backlight support, but "
> > > > "VBT disagrees. If your backlight controls "
> > > --
> > > Sincerely,
> > > Lyude Paul (she/her)
> > > Software Engineer at Red Hat
> --
> Sincerely,
> Lyude Paul (she/her)
> Software Engineer at Red Hat
>
>
[-- Attachment #1.2: Type: text/html, Size: 5737 bytes --]
[-- Attachment #2: Type: text/plain, Size: 160 bytes --]
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel
^ permalink raw reply [flat|nested] 19+ messages in thread
* Re: [Intel-gfx] [PATCH 1/2] drm/i915/dpcd_bl: Skip testing control capability with force DPCD quirk
@ 2020-10-08 21:32 ` Satadru Pramanik
0 siblings, 0 replies; 19+ messages in thread
From: Satadru Pramanik @ 2020-10-08 21:32 UTC (permalink / raw)
To: Lyude Paul, Kevin Chowski
Cc: David Airlie, intel-gfx, open list, Kai-Heng Feng, open list:DRM DRIVERS
[-- Attachment #1.1: Type: text/plain, Size: 3980 bytes --]
Kevin Chowski said he would be geting to working on upstreaming a version
of that which was in the ChromeOS tree here:
https://chromium-review.googlesource.com/c/chromiumos/third_party/kernel/+/2344844
when I last spoke to hi
(This was two weeks ago.)
Kevin - do you have any input on this?
Satadru
On Thu, Oct 8, 2020 at 1:07 PM Lyude Paul <lyude@redhat.com> wrote:
> oh hold on, I misspoke. Here's the patch I was thinking of:
>
> https://patchwork.freedesktop.org/series/82041/
>
> On Thu, 2020-10-08 at 10:32 +0800, Kai-Heng Feng wrote:
> > Hi Lyude,
> >
> > > On Oct 8, 2020, at 05:53, Lyude Paul <lyude@redhat.com> wrote:
> > >
> > > Hi! I thought this patch rang a bell, we actually already had some
> > > discussion
> > > about this since there's a couple of other systems this was causing
> issues
> > > for.
> > > Unfortunately it never seems like that patch got sent out. Satadru?
> > >
> > > (if I don't hear back from them soon, I'll just send out a patch for
> this
> > > myself)
> > >
> > > JFYI - the proper fix here is to just drop the
> > > DP_EDP_BACKLIGHT_BRIGHTNESS_PWM_PIN_CAP check from the code entirely.
> As
> > > long as
> > > the backlight supports AUX_SET_CAP, that should be enough for us to
> control
> > > it.
> >
> > Does the proper fix include dropping DP_QUIRK_FORCE_DPCD_BACKLIGHT
> entirely?
> >
> > Kai-Heng
> >
> > >
> > > On Wed, 2020-10-07 at 14:58 +0800, Kai-Heng Feng wrote:
> > > > HP DreamColor panel needs to be controlled via AUX interface.
> However,
> > > > it has both DP_EDP_BACKLIGHT_BRIGHTNESS_AUX_SET_CAP and
> > > > DP_EDP_BACKLIGHT_BRIGHTNESS_PWM_PIN_CAP set, so it fails to pass
> > > > intel_dp_aux_display_control_capable() test.
> > > >
> > > > Skip the test if the panel has force DPCD quirk.
> > > >
> > > > Signed-off-by: Kai-Heng Feng <kai.heng.feng@canonical.com>
> > > > ---
> > > > drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c | 10 ++++++----
> > > > 1 file changed, 6 insertions(+), 4 deletions(-)
> > > >
> > > > 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 acbd7eb66cbe..acf2e1c65290 100644
> > > > --- a/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
> > > > +++ b/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
> > > > @@ -347,9 +347,13 @@ int intel_dp_aux_init_backlight_funcs(struct
> > > > intel_connector *intel_connector)
> > > > struct intel_panel *panel = &intel_connector->panel;
> > > > struct intel_dp *intel_dp =
> enc_to_intel_dp(intel_connector->encoder);
> > > > struct drm_i915_private *i915 = dp_to_i915(intel_dp);
> > > > + bool force_dpcd;
> > > > +
> > > > + force_dpcd = drm_dp_has_quirk(&intel_dp->desc,
> intel_dp->edid_quirks,
> > > > + DP_QUIRK_FORCE_DPCD_BACKLIGHT);
> > > >
> > > > if (i915->params.enable_dpcd_backlight == 0 ||
> > > > - !intel_dp_aux_display_control_capable(intel_connector))
> > > > + (!force_dpcd &&
> > > > !intel_dp_aux_display_control_capable(intel_connector)))
> > > > return -ENODEV;
> > > >
> > > > /*
> > > > @@ -358,9 +362,7 @@ int intel_dp_aux_init_backlight_funcs(struct
> > > > intel_connector *intel_connector)
> > > > */
> > > > if (i915->vbt.backlight.type !=
> > > > INTEL_BACKLIGHT_VESA_EDP_AUX_INTERFACE &&
> > > > - i915->params.enable_dpcd_backlight != 1 &&
> > > > - !drm_dp_has_quirk(&intel_dp->desc, intel_dp->edid_quirks,
> > > > - DP_QUIRK_FORCE_DPCD_BACKLIGHT)) {
> > > > + i915->params.enable_dpcd_backlight != 1 && !force_dpcd) {
> > > > drm_info(&i915->drm,
> > > > "Panel advertises DPCD backlight support, but "
> > > > "VBT disagrees. If your backlight controls "
> > > --
> > > Sincerely,
> > > Lyude Paul (she/her)
> > > Software Engineer at Red Hat
> --
> Sincerely,
> Lyude Paul (she/her)
> Software Engineer at Red Hat
>
>
[-- Attachment #1.2: Type: text/html, Size: 5737 bytes --]
[-- Attachment #2: Type: text/plain, Size: 160 bytes --]
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply [flat|nested] 19+ messages in thread
end of thread, other threads:[~2020-10-09 7:30 UTC | newest]
Thread overview: 19+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-10-07 6:58 [PATCH 1/2] drm/i915/dpcd_bl: Skip testing control capability with force DPCD quirk Kai-Heng Feng
2020-10-07 6:58 ` [Intel-gfx] " Kai-Heng Feng
2020-10-07 6:58 ` Kai-Heng Feng
2020-10-07 6:58 ` [PATCH 2/2] drm/dp: HP DreamColor panel brigntness fix Kai-Heng Feng
2020-10-07 6:58 ` Kai-Heng Feng
2020-10-07 21:53 ` [PATCH 1/2] drm/i915/dpcd_bl: Skip testing control capability with force DPCD quirk Lyude Paul
2020-10-07 21:53 ` [Intel-gfx] " Lyude Paul
2020-10-07 21:53 ` Lyude Paul
2020-10-08 2:32 ` Kai-Heng Feng
2020-10-08 2:32 ` [Intel-gfx] " Kai-Heng Feng
2020-10-08 2:32 ` Kai-Heng Feng
2020-10-08 16:39 ` Lyude Paul
2020-10-08 16:39 ` [Intel-gfx] " Lyude Paul
2020-10-08 16:39 ` Lyude Paul
2020-10-08 17:06 ` Lyude Paul
2020-10-08 17:06 ` [Intel-gfx] " Lyude Paul
2020-10-08 17:06 ` Lyude Paul
2020-10-08 21:32 ` Satadru Pramanik
2020-10-08 21:32 ` [Intel-gfx] " Satadru Pramanik
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.