Bug 91791 - [SKL-U] System hang when a DP MST hub and a DP->VGA adapter/monitor are connected
Summary: [SKL-U] System hang when a DP MST hub and a DP->VGA adapter/monitor are conne...
Status: CLOSED FIXED
Alias: None
Product: DRI
Classification: Unclassified
Component: DRM/Intel (show other bugs)
Version: XOrg git
Hardware: Other All
: high critical
Assignee: cprigent
QA Contact: yann
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-08-28 08:53 UTC by Timo Aaltonen
Modified: 2016-08-23 12:12 UTC (History)
9 users (show)

See Also:
i915 platform: SKL
i915 features: display/DP MST


Attachments
kernel_log_for_VGA_monitor_(by_VGA_DP_converter) (321.24 KB, text/plain)
2015-10-19 11:00 UTC, Gary Wang
no flags Details
Error log when enabling VGA port (DP-to-VGA) in customer's device (35.20 KB, text/plain)
2015-10-22 13:34 UTC, Gary Wang
no flags Details
System hung when plug-in DP MST-enabled hub in Intel SKL-U CRB (211.57 KB, text/plain)
2015-10-23 07:03 UTC, Gary Wang
no flags Details
Picture: suffers issue when plug-in DP MST-enabled with modeset=1 (1.34 MB, text/plain)
2015-10-23 07:51 UTC, Gary Wang
no flags Details
Test purpose for disabling DP MST for DP HUB (1.37 KB, text/plain)
2015-10-23 08:56 UTC, Gary Wang
no flags Details
Test purpose for disabling DP MST for DP HUB in SKL platform (1.53 KB, text/plain)
2015-10-26 01:36 UTC, Gary Wang
no flags Details
[jpg] DP MST work well in Ubuntu with #13 patch (977.50 KB, image/jpeg)
2015-10-26 10:59 UTC, Gary Wang
no flags Details
Picture: suffers issue when plug-in DP MST-enabled with modeset=1 (1.34 MB, image/jpeg)
2015-11-02 04:28 UTC, Gary Wang
no flags Details
debug dmesg with Ville's patch (238.17 KB, text/plain)
2015-11-09 08:13 UTC, Timo Aaltonen
no flags Details
Patch for MST port clock setup on SKL (5.50 KB, patch)
2015-11-11 00:22 UTC, Jim Bride
no flags Details | Splinter Review
Dmesg log (248.95 KB, text/plain)
2016-05-30 18:59 UTC, Elio
no flags Details
Xrandr_output (1.64 KB, text/plain)
2016-05-30 18:59 UTC, Elio
no flags Details
Xorg log (22.39 KB, text/plain)
2016-05-30 19:01 UTC, Elio
no flags Details

Description Timo Aaltonen 2015-08-28 08:53:27 UTC
This one OEM system hangs immediately if a VGA monitor is plugged in. It also hangs if it's booted with the monitor already plugged in. Happens with current nightly as well.

I don't have any logs yet.
Comment 1 Gary Wang 2015-10-19 11:00:23 UTC
Created attachment 118977 [details]
kernel_log_for_VGA_monitor_(by_VGA_DP_converter)

Hi Timo,

According to corresponding issue #1482038 in launchpad, it seems to use DP-VGA converter for connecting to VGA monitor, right?

This issue cannot be reproduced with drm-intel-nightly-2015/10/19 + Ubuntu 15.04 in SKL-U Intel CRB platform. Both extended and mirror modes work well.
Comment 2 Gary Wang 2015-10-21 01:43:35 UTC
Hi Timo,
Could you please tell me that VGA port is enabled by DP_to_VGA_converter or native VGA interface? Thanks!
Comment 3 Timo Aaltonen 2015-10-21 04:11:01 UTC
Looks like you got that information already? I'm happy to keep this on LP for now until it's certain the driver is buggy and there are patches to try..
Comment 4 Gary Wang 2015-10-22 13:07:51 UTC
Hi Timo, 
I don't have miniDP 1.2 port in CRB for test this issue again (only have DP-to-VGA v1.2 converter). 

Do you have any device embedded with DP 1.2 port to test DP-to-VGA v1.2 converter for VGA monitor? 

Thanks!

Gary
Comment 5 Timo Aaltonen 2015-10-22 13:23:45 UTC
No I don't, but when my SKL-H worked the VGA output on it worked fine (with the new patches from August).

SKL-Y DVP3 has a miniDP port, dunno if it's 1.2 but it only came with a DP/DVI/HDMI dongle.
Comment 6 Gary Wang 2015-10-22 13:34:59 UTC
Created attachment 119067 [details]
Error log when enabling VGA port (DP-to-VGA) in customer's device
Comment 7 Gary Wang 2015-10-23 07:03:36 UTC
Created attachment 119128 [details]
System hung when plug-in DP MST-enabled hub in Intel SKL-U CRB

I use DP 1.2 MST-supported HUB (Sunix IT DisplayPort to Dual Graphics Splitter) to test this issue in SKU-U Intel CRB, two DPs input, one miniDP output.

This DP MST hub works well in my win7 Lenovo X230NB via miniDP port. 

But it also suffer from system hung in Ubuntu 15.04 with drm-intel-nightly-2015/10/19 when plug-in DP MST Hub to CRB's miniDP port.
...
Feb 11 16:16:03 test kernel: [   96.395534] [drm:intel_dp_set_signal_levels] Using pre-emphasis level 0
Feb 11 16:16:03 test kernel: [   96.412066] [drm:intel_dp_set_signal_levels] Using signal levels 00000000
Feb 11 16:16:03 test kernel: [   96.412068] [drm:intel_dp_set_signal_levels] Using vswing level 0
Feb 11 16:16:03 test kernel: [   96.412069] [drm:intel_dp_set_signal_levels] Using pre-emphasis level 0
Feb 11 16:16:03 test kernel: [   96.428626] [drm:intel_dp_link_training_clock_recovery [i915]] *ERROR* too ma
Feb 11 16:16:03 test kernel: [   96.428847] [drm:intel_dp_link_training_channel_equalization [i915]] *ERROR*
....
Comment 8 Gary Wang 2015-10-23 07:25:42 UTC
The DP 1.2 MST Hub is Sunix IT DisplayPort to Dual Graphics Splitter, Black (DPD2001), please refer following link,
http://www.amazon.com/IT-DisplayPort-Graphics-Splitter-DPD2001/dp/B00JATFVXI
Comment 9 Gary Wang 2015-10-23 07:51:28 UTC
Created attachment 119131 [details]
Picture: suffers issue when plug-in DP MST-enabled with modeset=1

I verified this again with drm-intel-nightly 10/22 on Ubuntu 15.04. 

It also suffers from DP MST issue when plug-in DP MST-enabled in modeset=1 situation.
Comment 10 Gary Wang 2015-10-23 08:56:48 UTC
Created attachment 119133 [details]
Test purpose for disabling DP MST for DP HUB

Hi Timo,
Could help to give it a try and share the test result with us for reference? This is not final solution, and fix it further.
Comment 11 Gary Wang 2015-10-23 23:33:41 UTC
For provided patch, I forget to add checking code to let it be valid for SKY platform. sorry.
Comment 12 Gary Wang 2015-10-24 08:53:09 UTC
Correct description in #11.

For provided patch, I forgot to add checking code for SKY-U platform to let it be "only" disabled  DP MST in SKY-U, but still supports it in other platform like BDW/BSW...etc.
Comment 13 Gary Wang 2015-10-26 01:36:34 UTC
Created attachment 119190 [details]
Test purpose for disabling DP MST for DP HUB in SKL platform

Update patch.

Test purpose for disabling DP MST for DP 1.2 HUB in SKL platform. It only disable DP MST in SKY-U platform.
Comment 14 Gary Wang 2015-10-26 10:59:36 UTC
Created attachment 119197 [details]
[jpg] DP MST work well in Ubuntu with #13 patch

I verified this issue again by patch from #13, DP MST seems to work well in Ubuntu 15.04 with drm-intel-nightly-10/23, and have no idea why.

Please refer this picture.
Comment 15 Gary Wang 2015-10-27 01:59:30 UTC
For an additional remark on #14,
Without applying patch from #13, it still failed the test in Ubuntu 15.04 with drm-intel-nightly-10/23.
Comment 16 Jim Bride 2015-10-27 23:28:44 UTC
Do we have the exact manufacturer and model number for the DP->VGA solution that the customer is using?  Are we sure it's a MST part?
Comment 17 Gary Wang 2015-10-28 01:11:17 UTC
Hi Jim,
They used Synaptics DP Hub VMM3320 as internal DP HUB to extend more VGA/DP ports
Comment 18 Jim Bride 2015-10-28 16:10:43 UTC
Gary,

Thanks for the quick response.  Can we verify that the customer is using the latest firmware available for the VMM3320?  The latest release that I've been able to find is v3.8.0, A02.

Thanks,

Jim
Comment 19 Gary Wang 2015-10-29 01:11:09 UTC
Customer used the latest firmware for Window platforms, and I will also check its ODM. 

It also happened this issue with Sunix IT DisplayPort to Dual Graphics Splitter, Black (DPD2001), please refer following link,
http://www.amazon.com/IT-DisplayPort-Graphics-Splitter-DPD2001/dp/B00JATFVXI

BTW, I don't have Dell DP MST monitor (only low-end AOC DP monitor). Do you have any Dell DP MST LCD for its reproduction? Thanks for your help!
Comment 20 Gary Wang 2015-10-29 03:29:20 UTC
it should be firmware v3.8 (refer following mst dump).
...
        mst: ffff8800894e3ae0, 0
        port: 3: ddps: 1 ldps: 1, ffff8800a3efe800, conn: ffff8800a3eff000
        port: 2: ddps: 0 ldps: 0, ffff8800a3efc000, conn: ffff8800a3efb800
        port: 1: ddps: 0 ldps: 0, ffff8800a3efd000, conn: ffff8800a3efc800
        port: 0: ddps: 1 ldps: 0, ffff8800a3efd800, conn:           (null)
vcpi: 3 1
vcpi 0: 3 1 14
vcpi 1:unsed
vcpi 2:unsed
payload 0: 2, 1, 14
payload 1: 0, 15, 0
payload 2: 0, 15, 0
dpcd: 12 14 c4 01 00 15 01 83 02 00 00 00 00 00 04
faux/mst: 00 01
mst ctrl: 07
branch oui: 90cc24 devid: SYNA3 revision: hw: 1.0 sw: 3.8
payload table: 03 01 01 01 01 01 01 01 01 01 01 01 01 01 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
...
Comment 21 dog 2015-10-29 23:39:44 UTC
This is a very confusing thread.  I'm trying to make sense of all the comments here.  The description says that one OEM system hands if a VGA monitor is plugged in.  Comment #1 says the issue can't be reproduced.  (Note that we've been encountering poor quality DP->VGA dongles quite a bit this year)

Please provide a summary of the simplest configuration that demonstrates the error today.  Can it be demonstrated with out the use of dongles or converter boxes?  Can you connect from a DP port to two monitors in series?  Does that work?

The status of DP MST and DP MST audio is being captured in the driver, but it is know that a number of Dave Airlie's patches are still in review.  So, DP MST functionality is not complete.
Comment 22 Gary Wang 2015-10-30 06:36:13 UTC
Hi Paul (reply to #21),
Totally agree on you. The title of this issue is really confusing.

Customer reported it suffered from system hung when plug-in into VGA port originally in SKL-U platform, and didn't say how design of display in DUT.

After checking its internal display design of DUT, it uses one DP MST-enabled Hub (Synaptics DP Hub VMM3320) and one DP-to-VGA converter to extend theirs display port for 2 DPs and 2 VGAs.

For comment #1, I used DP-to-VGA converters (DP 1.1a & DP 1.2) to check it, they works well in my Intel SKL-U CRB.

For comment #7, I used DP 1.2 MST-enabled HUB (Sunix IT DisplayPort to Dual Graphics Splitter 1-input DP and 2 output DPs) to test this issue in SKL-U Intel CRB, i.e. using CRB's miniDP port connecting to DP MST Hub for DP MST on two DP monitors via that DP MST Hub. It suffered from the same issue in my Intel SKL-U CRB (dp training error from intel_mst_pre_enable_dp()/intel_dp_mst_compute_config()).

For comment #13 and #14, it seems to cause trouble between source MST link computation among DP source/branch/sink when enabling MST display (but aux works well). Then disable MST for SST between source and sink makes test (from #7 with one DP 1.2 monitor & one DP 1.1a monitor) working well with functionality of DP MST in Ubuntu 15.04 (but still not try DP daisy chain and guess could be trouble due to lacking MST).

All of them were tested based on drm-intel-nightly-2015/10/19.

Thanks!

Gary
Comment 23 dog 2015-10-30 22:04:31 UTC
Thanks for the summary, Gary.  I have assigned an engineer to set up a system and reproduce the problem.  Which of the systems configurations listed in the previous comment do you want us to use for problem reproduction?  Also, can you write up the procedure for demonstrating the issue?
Comment 24 Gary Wang 2015-11-02 04:28:43 UTC
Created attachment 119332 [details]
Picture: suffers issue when plug-in DP MST-enabled with modeset=1

Hi Paul,

I used following information to this issue for QA's reference,

Intel CRB: Skylake Client platform/Skylake U DDR3L RVP7
CPU: i3-6100U CPU @ 2.30GHz (family: 0x6, model: 0x4e, stepping: 0x3)
BIOS version: BIOS SKLSE2R1.R00.X097.B02.1509020030 09/02/2015
Display: CRB's miniDP with DP MST-enabled Hub (Sunix IT DisplayPort, http://www.amazon.com/IT-DisplayPort-Graphics-Splitter-DPD2001/dp/B00JATFVXI)
Linux Gfx kernel Driver: drm-intel-nightly-2015/10/19

Reproduce steps:
1. Boot into Ubuntu 15.04 with kernel drm-intel-nightly-2015/10/19 successfully without plug-in mini-DP port
2. Prepare DP MST environment by miniDP cable-->DP MST-enabled HUB-->Connect to both/either DP 1.2 MST-supported monitor and/or DP 1.1a monitor
3. Plug-in miniDP cable into CRB's miniPort (it will encounter it immediately)

Warning: f booting with DP MST environment (i.e. step2/3), it suffered system hung immediately (please refer the picture).

BTW, from my analysis for booting by kernel drm-intel-nightly-2015/10/19 + x11 only, it seems to no problem on DP MST connecting (sometime MSTM_CTRL failed to write) but failed in its enabling.
...
Feb 17 22:22:38 test kernel: [  546.442146] [drm:intel_dp_check_mst_status] channel EQ not ok, retraining
Feb 17 22:22:38 test kernel: [  546.443339] [drm:intel_dp_set_signal_levels] Using signal levels 00000000
Feb 17 22:22:38 test kernel: [  546.443340] [drm:intel_dp_set_signal_levels] Using vswing level 0
Feb 17 22:22:38 test kernel: [  546.443341] [drm:intel_dp_set_signal_levels] Using pre-emphasis level 0
...
Feb 17 22:22:38 test kernel: [  547.039900] [drm:intel_dp_link_training_clock_recovery [i915]] *ERROR* too many voltage retries, give up
...

Thanks for your help!

Gary
Comment 25 Jim Bride 2015-11-04 23:03:42 UTC
Gary, Could you please get me the SHA for the first commit in the kernel source tree you are using?
Comment 26 Jim Bride 2015-11-05 15:28:54 UTC
It's also worth noting that this does seem to be SKL specific.  I was able to use the configuration that fails on SKL on my HSW dev system using the same kernel and it worked fine.
Comment 27 Gary Wang 2015-11-06 13:50:06 UTC
Hi Jim,

It seems to be necessary adding DDI PLL mapping in  intel_mst_pre_enable_dp method (please refer http://lxr.free-electrons.com/source/drivers/gpu/drm/i915/intel_dp_mst.c#L188). 
But it still got failed after I wrote DPLL_CTRL2 with corresponding port for it, and need to check it in related spec further, upset.
Comment 28 Ville Syrjala 2015-11-06 13:55:42 UTC
(In reply to Gary Wang from comment #27)
> Hi Jim,
> 
> It seems to be necessary adding DDI PLL mapping in  intel_mst_pre_enable_dp
> method (please refer
> http://lxr.free-electrons.com/source/drivers/gpu/drm/i915/intel_dp_mst.
> c#L188). 
> But it still got failed after I wrote DPLL_CTRL2 with corresponding port for
> it, and need to check it in related spec further, upset.

I tried to fix something along those lines for SKL:
http://lists.freedesktop.org/archives/intel-gfx/2015-August/073965.html
Comment 29 Timo Aaltonen 2015-11-09 08:13:44 UTC
Created attachment 119496 [details]
debug dmesg with Ville's patch

I built a kernel based on current drm-intel-next-fixes plus the one from Ville, but it still doesnt' work right, dmesg attached.
Comment 30 Timo Aaltonen 2015-11-09 08:23:25 UTC
Probably should've said what does happen; the monitor stays blank, system does not hang. And actually 4.3 was tested too, it didn't hang either.. dunno why not.
Comment 31 Jim Bride 2015-11-09 16:26:22 UTC
The system doesn't hang because the clock is being set right for the port being used for MST with the patch in place.  We still seem to have a problem with link training, which is why you are not seeing any monitor output.  I'm hoping to get together with one of my colleagues today and use a DP protocol analyzer to see if we can figure out what is going on.  There isn't a lot of visibility into the link training process from software, unfortunately.
Comment 32 Jesse Barnes 2015-11-10 17:15:01 UTC
I wonder if this is a dupe of 
https://bugs.launchpad.net/bugs/1482038

which is fixed now.
Comment 33 Jim Bride 2015-11-10 17:24:59 UTC
I get a 404 from the link above, but would love to have more info on this.
Comment 34 Timo Aaltonen 2015-11-10 19:40:55 UTC
Yes, it's the private bug that made me file this here, but the kernel that was last tested is what produced the dmesg from comment #29 here. So the hang is  fixed but monitor stays blank as mentioned.
Comment 35 Jim Bride 2015-11-11 00:22:24 UTC
Created attachment 119556 [details] [review]
Patch for MST port clock setup on SKL

Please see the attached bug.  It fixes clock setup for MST on SKL.
Comment 36 Jani Nikula 2015-11-11 12:53:27 UTC
(In reply to Jim Bride from comment #35)
> Created attachment 119556 [details] [review] [review]
> Patch for MST port clock setup on SKL
> 
> Please see the attached bug.  It fixes clock setup for MST on SKL.

That's now in drm-intel-nightly as

commit e404ba8d06ff2a1bdb916a9e5d2c09cacd7e5ca3
Author: Ville Syrjälä <ville.syrjala@linux.intel.com>
Date:   Mon Aug 17 18:46:20 2015 +0300

    drm/i915: Setup DDI clk for MST on SKL
Comment 37 Jim Bride 2015-11-18 18:21:03 UTC
Debug continues on this issue.  We are now wrestling with a failure while trying to do a mode set on the MST virtual channel associated with our monitor.  In the meantime, I would suggest pulling in the following two patches from drm-intel-nightly as a part of the solution to this issue.

commit d1c0a0019aed692020da523d5fa9f2ebb49a018a
Author: jim.bride@linux.intel.com <jim.bride@linux.intel.com>
Date:   Fri Nov 6 15:30:54 2015 -0800

    drm/i915/skl: Update DDI translation tables for SKL

commit e4d4c05bfb3a2dcba21422df160a67739dc80688
Author: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com>
Date:   Wed Nov 11 15:15:54 2015 +0200

    drm/i915: Fix SKL i_boost level
Comment 38 Gary Wang 2015-11-20 01:59:44 UTC
Hi Jim, 
I verified patches from #37 again (by drm-intel-nightly: 2015-11-18-19h-48m-48s). The DP port was in connected & enabled, but corresponding screen was still blank. Thanks!
Comment 39 webdevelopersdiary 2015-12-06 21:55:27 UTC
Hi Gary,

I was reading into Skylake support for MST and stumbled into this bug report. The issue you are describing with the blank screen is something I have heard before during my search, I posted all the info I could find here:

http://unix.stackexchange.com/questions/247722/intel-skylake-displayport-1-2-mst-daisy-chain-on-linux

It contains links to 2 different situations:
- one nvidia user reported that his second screen stayed blank (power saving mode). After his screen saver switched on and he used the computer *both* screens came on and the issue was gone until next reboot.
- an AMD Radeon user mentioned both his screens went into power saving mode *after* logging in, while these were working before the login.

And now I read about your screen also going in power saving mode, so I am just wondering if these situations all have something in common.

Perhaps you could try the work-around in this link to see if that solves the blank screen problem:

http://ubuntuforums.org/showthread.php?t=2301503

HTH
Comment 40 cprigent 2015-12-15 17:32:24 UTC
Bug scrub:
DP MST is not POR on SKL
Comment 41 Jani Nikula 2016-04-25 07:50:52 UTC
Please try current v4.6-rc kernels or, if that fails, drm-intel-nightly branch of http://cgit.freedesktop.org/drm-intel
Comment 42 Gary Wang 2016-04-26 06:09:06 UTC
Hi Timo, 
I verified this issue again by drm-intel-nightly 4/25, this issue went away. Switching display combination of internal/external/mirror/extended modes with DP-MST enabled HUB didn't get fail-rate. 

Could you help to verify it and share test result with us? Thanks!!!
Comment 43 yann 2016-04-26 08:19:02 UTC
QA, please re-test
Comment 44 Elio 2016-05-30 18:58:00 UTC
Using the following commit:
commit fb023a2062df06c9e097e1f8f2bcf252194b9413
Author: Daniel Vetter <daniel.vetter@ffwll.ch>
Date:   Mon May 30 10:46:14 2016 +0200

    drm-intel-nightly: 2016y-05m-30d-08h-45m-53s UTC integration manifest


Kernel version : 4.6.0
Architecture : source amd64 all

Observations:

Using same displays over DP hub 3-outputs, 1 through DP and 1 through DP-VGA dongle. 

Xrandr clonning instruction is working fine, no system hang, but this instruction is not working on Graphic interface (system settings-> display ->mirror displays), it is turning off the secondary display (VGA). 

Error:

"The selected configuration for display could not be applied"
 Could not set the configuration for CRTC 63

"Failed to apply configuration: %s"
Timeout was reached

Once that you try to set up the mirror displays , you need to re-activate on settings the display and change it to extended mode.


Platform:

SKL-H

OS: Ubuntu 16.04

Attaching Dmesg,Xorg and Kernel log
Comment 45 Elio 2016-05-30 18:59:09 UTC
Created attachment 124179 [details]
Dmesg log
Comment 46 Elio 2016-05-30 18:59:34 UTC
Created attachment 124180 [details]
Xrandr_output
Comment 47 Elio 2016-05-30 19:01:52 UTC
Created attachment 124181 [details]
Xorg log
Comment 48 Jani Nikula 2016-06-17 16:41:01 UTC
(In reply to Elio from comment #44)
> Xrandr clonning instruction is working fine, no system hang, but this
> instruction is not working on Graphic interface (system settings-> display
> ->mirror displays), it is turning off the secondary display (VGA). 

I take this as fixed, whatever the GUI does or fails to do is out of our hands.

Please reopen if the problem persists with nightly.
Comment 49 cprigent 2016-08-23 12:12:25 UTC
So closed.
Feel free to reopen if needed.


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.