Bug 86733 - [hsw DP] DP 1.1a hot plug monitor discovery takes way too long because piles of dp aux native defers
Summary: [hsw DP] DP 1.1a hot plug monitor discovery takes way too long because piles ...
Status: CLOSED FIXED
Alias: None
Product: DRI
Classification: Unclassified
Component: DRM/Intel (show other bugs)
Version: unspecified
Hardware: x86-64 (AMD64) Linux (All)
: medium normal
Assignee: Intel GFX Bugs mailing list
QA Contact: Intel GFX Bugs mailing list
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-11-26 09:54 UTC by xnox
Modified: 2017-07-24 22:50 UTC (History)
1 user (show)

See Also:
i915 platform: HSW
i915 features: display/DP


Attachments
dp-screen-finding-takes-too-long.txt (71.55 KB, text/plain)
2014-11-26 09:54 UTC, xnox
no flags Details

Description xnox 2014-11-26 09:54:04 UTC
Created attachment 110049 [details]
dp-screen-finding-takes-too-long.txt

I'm attaching a log booted without any screens attached, with drm.debug=7 set on the kernel command line, and later a screen attached.

[   10.814093] [drm:intel_hpd_irq_handler] hotplug event received, stat 0x00400000, dig 0x10101210
[   10.816202] [drm:drm_dp_i2c_do_msg] native defer
-- " --
[   11.142132] [drm:drm_detect_monitor_audio] Monitor has basic audio support
...
[   11.143836] [drm:drm_dp_i2c_do_msg] native defer
-- " --
[   11.466765] [drm:drm_detect_monitor_audio] Monitor has basic audio support
[   11.467203] [drm:drm_dp_i2c_do_msg] native defer
-- " --
[   11.791475] [drm:drm_dp_i2c_do_msg] native defer
[   11.792287] [drm:drm_add_display_info] DP-1: Assigning EDID-1.4 digital sink color depth as 8 bpc.

Imho the amount of "[drm:drm_dp_i2c_do_msg] native defer" calls is a lot and takes too much time.

For example, kernel initialisation takes 1.5s with screen attached (as reported by systemd-analyse), however it takes ~750ms less if no screen is attached and as per above the bulk of that time on screen hotplug is spent in talking over i2c. Also not sure why, but "Monitor has basic audio support" is detected twice...

This is an Intel NUC Haswell platform.
Comment 1 xnox 2014-11-26 10:21:42 UTC
I think it's important to point out that the monitor is Dell, connected from mini-DP to DP using a cable, with no dongles in between.

The monitor is operating with "DP MST/HBR2 disabled" in "DP1.1a" mode.

And I get the correct/native screen resolution on the terminal.

Enabling DisplayPort 1.2 - makes the screen detection much faster (in the range of additional 50-60ms above no screen connected from cold boot), however I do not get correct/native screen resolution.

I will file a separate bug report about DisplayPort 1.2.
Comment 2 Daniel Vetter 2014-11-26 14:57:25 UTC
Since your @intel.com: If this is product critical please escalate through normal means (pdt and all), bugzilla here is just best effort.
Comment 3 xnox 2014-11-26 15:04:23 UTC
(In reply to Daniel Vetter from comment #2)
> Since your @intel.com: If this is product critical please escalate through
> normal means (pdt and all), bugzilla here is just best effort.

@Daniel i'm new at intel, given the keywords above I can say this is not a "product critical" in any way. My team was concerned about boot speed and it's just one of the things we found. Now that we understand that it's pure upstream / monitor discovery taking too long in such a configuration, we are not concerned about experiencing this bug. Imho, it's a valid upstream bug and I hope this could be improved, eventually...
Comment 4 Jani Nikula 2014-11-27 13:47:18 UTC
Shot in the dark, please try this patch

diff --git a/drivers/gpu/drm/i915/intel_dp.c b/drivers/gpu/drm/i915/intel_dp.c
index 70bb8d0b9695..768b1bfaea78 100644
--- a/drivers/gpu/drm/i915/intel_dp.c
+++ b/drivers/gpu/drm/i915/intel_dp.c
@@ -1932,7 +1932,7 @@ void intel_dp_sink_dpms(struct intel_dp *intel_dp, int mode)
 
 	if (mode != DRM_MODE_DPMS_ON) {
 		ret = drm_dp_dpcd_writeb(&intel_dp->aux, DP_SET_POWER,
-					 DP_SET_POWER_D3);
+					 DP_SET_POWER_D0);
 	} else {
 		/*
 		 * When turning on, we need to retry for 1ms to give the sink
Comment 5 Jani Nikula 2015-01-29 15:14:50 UTC
Ping for the testing.
Comment 6 xnox 2015-02-02 09:14:08 UTC
(In reply to Jani Nikula from comment #5)
> Ping for the testing.

That patch from https://bugs.freedesktop.org/show_bug.cgi?id=86733#c4 did not improve boot time. I still see same/similar delay/boot timings.
Comment 8 Jani Nikula 2015-10-23 10:24:22 UTC
We've fixed tons of DP aux/i2c-over-aux issues lately. Presumed fixed upstream, closing. Please reopen if the problem persists with latest kernels.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.