drm/i915: Restrict usage of live status check
Subsystems (2)
PATCH v2 1/1 drm/i915: Restrict usage of live status check
This patch does the following:
- Restricts usage of live status check for HDMI detection. While testing certain (monitor + cable) combinations with various intel platforms, it seems that live status register doesn't work reliably on some older devices. So limit the live_status check for HDMI detection, only for platforms from gen7 onwards.
- Cleans up the retry logic.
There is an extra 'if (try)' check, which can be avoided by changing the logic slightly, keeping the delay as same(80ms)
V2: Ville: Skipped live_status check for IVB
--- drivers/gpu/drm/i915/intel_hdmi.c | 24 ++++++++++++++++-------- 1 file changed, 16 insertions(+), 8 deletions(-)
drivers/gpu/drm/i915/intel_hdmi.c +16 -8
@@ -1397,24 +1397,32 @@ intel_hdmi_detect(struct drm_connector *connector, bool force)enum drm_connector_status status;struct intel_hdmi *intel_hdmi =intel_attached_hdmi (connector);struct drm_i915_private *dev_priv =to_i915 (connector->dev); -bool live_status = false; -unsigned int try; +struct drm_device *dev = dev_priv->dev; +bool live_status = true; +unsigned int try =9 ;DRM_DEBUG_KMS ("[CONNECTOR:%d:%s]\n" , connector->base.id, connector->name);intel_display_power_get (dev_priv,POWER_DOMAIN_GMBUS ); -for (try =0 ; !live_status && try <9 ; try++) { -if (try) -msleep (10 ); +/* +* When tested with specific set of monitors + cables, +* live status behavior is not very consistent for older +* platforms. So add live status check from VLV +* onwards. +*/ +if (INTEL_INFO (dev)->gen >=7 && !IS_IVYBRIDGE (dev)) { +retry_ls: live_status =intel_digital_port_connected (dev_priv,hdmi_to_dig_port (intel_hdmi)); +if (!live_status && --try) { +msleep (10 ); + goto retry_ls; + } +DRM_DEBUG_KMS ("Live status %s!\n" , live_status ?"up" :"down" ); } -if (!live_status) -DRM_DEBUG_KMS ("Live status not up!" ); -intel_hdmi_unset_edid (connector);if (intel_hdmi_set_edid (connector, live_status)) {
Signature · 6 lines
1.9.1 _______________________________________________ Intel-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/intel-gfx
Patchwork
CI✗ Fi.CI.BAT: failure for drm/i915: Restrict usage of live status check (rev2)
== Series Details ==
== Series Details ==
Series: drm/i915: Restrict usage of live status check (rev2)
URL : https://patchwork.freedesktop.org/series/4297/
State : failure
== Summary ==
Series 4297v2 drm/i915: Restrict usage of live status check
http://patchwork.freedesktop.org/api/1.0/series/4297/revisions/2/mbox/
Test kms_flip:
Subgroup basic-flip-vs-modeset:
dmesg-warn -> PASS (bdw-ultra)
Test kms_pipe_crc_basic:
Subgroup suspend-read-crc-pipe-b:
incomplete -> PASS (hsw-gt2)
Subgroup suspend-read-crc-pipe-c:
pass -> DMESG-WARN (bsw-nuc-2)
Test pm_rpm:
Subgroup basic-pci-d3-state:
dmesg-warn -> PASS (hsw-brixbox)
Subgroup basic-rte:
dmesg-warn -> PASS (bsw-nuc-2)bdw-nuci7 total:193 pass:181 dwarn:0 dfail:0 fail:0 skip:12 bdw-ultra total:193 pass:172 dwarn:0 dfail:0 fail:0 skip:21 bsw-nuc-2 total:193 pass:155 dwarn:1 dfail:0 fail:0 skip:37 hsw-brixbox total:193 pass:171 dwarn:0 dfail:0 fail:0 skip:22 hsw-gt2 total:193 pass:175 dwarn:1 dfail:0 fail:0 skip:17 ivb-t430s total:193 pass:168 dwarn:0 dfail:0 fail:0 skip:25 skl-i5k-2 total:193 pass:170 dwarn:0 dfail:0 fail:0 skip:23 skl-i7k-2 total:193 pass:170 dwarn:0 dfail:0 fail:0 skip:23 skl-nuci5 total:161 pass:152 dwarn:0 dfail:0 fail:0 skip:9 snb-x220t total:193 pass:158 dwarn:1 dfail:0 fail:1 skip:33
Results at /archive/results/CI_IGT_test/Patchwork_1562/
63461ba49f1bc63fe9dcccdbbaa3a5049c57ae37 drm-intel-nightly: 2016y-03m-10d-13h-21m-51s UTC integration manifest 15df67ec813807692bf78e13462929f20ae491d0 drm/i915: Restrict usage of live status check
_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
Jani Nikula
maintainerQuoted 10 lines · Shashank Sharma
This patch does the following:
- Restricts usage of live status check for HDMI detection. While testing certain (monitor + cable) combinations with various intel platforms, it seems that live status register doesn't work reliably on some older devices. So limit thelive_statuscheck for HDMI detection, only for platforms from gen7 onwards.
- Cleans up the retry logic.
There is an extra 'if (try)' check, which can be avoided by changing the logic slightly, keeping the delay as same(80ms)
The commit message needs a reference to the commit that broke things.
BR,
Jani.
Quoted 53 lines
V2: Ville: Skipped
live_statuscheck for IVBSigned-off-by Shashank Sharma <[email protected]>--- drivers/gpu/drm/i915/intel_hdmi.c | 24 ++++++++++++++++-------- 1 file changed, 16 insertions(+), 8 deletions(-)drivers/gpu/drm/i915/intel_hdmi.c +16
-8@@ -1397,24 +1397,32 @@ intel_hdmi_detect(struct drm_connector *connector, bool force)enum drm_connector_status status;struct intel_hdmi *intel_hdmi =intel_attached_hdmi (connector);struct drm_i915_private *dev_priv =to_i915 (connector->dev); -bool live_status = false; -unsigned int try; +struct drm_device *dev = dev_priv->dev; +bool live_status = true; +unsigned int try =9 ;DRM_DEBUG_KMS ("[CONNECTOR:%d:%s]\n" , connector->base.id, connector->name);intel_display_power_get (dev_priv,POWER_DOMAIN_GMBUS ); -for (try =0 ; !live_status && try <9 ; try++) { -if (try) -msleep (10 ); +/* +* When tested with specific set of monitors + cables, +* live status behavior is not very consistent for older +* platforms. So add live status check from VLV +* onwards. +*/ +if (INTEL_INFO (dev)->gen >=7 && !IS_IVYBRIDGE (dev)) { +retry_ls: live_status =intel_digital_port_connected (dev_priv,hdmi_to_dig_port (intel_hdmi)); +if (!live_status && --try) { +msleep (10 ); + goto retry_ls; + } +DRM_DEBUG_KMS ("Live status %s!\n" , live_status ?"up" :"down" ); } -if (!live_status) -DRM_DEBUG_KMS ("Live status not up!" ); -intel_hdmi_unset_edid (connector);if (intel_hdmi_set_edid (connector, live_status)) {
Signature · 5 lines
Jani Nikula, Intel Open Source Technology Center _______________________________________________ Intel-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/intel-gfx