Bug 48821

Summary: [ivb dp vga dongle] driver is stuck when dp dongle is plugged in
Product: Drivers Reporter: Ioannis Koutras (ioannis.koutras)
Component: Video(DRI - Intel)Assignee: intel-gfx-bugs (intel-gfx-bugs)
Status: RESOLVED INSUFFICIENT_DATA    
Severity: normal CC: daniel, intel-gfx-bugs
Priority: P1    
Hardware: All   
OS: Linux   
Kernel Version: 3.6.2 Subsystem:
Regression: No Bisected commit-id:
Attachments: dmesg output
dmesg output with CONFIG_PROVE_LOCKING enabled
Xorg.0.log (external monitor connected while X is running and disconnected after a while)

Description Ioannis Koutras 2012-10-15 10:42:36 UTC
Created attachment 83491 [details]
dmesg output

Dear all,

I use a Macbook Air 4,2 (Mid 2011), which has Intel HD 3000, and I cannot use currently an external monitor. My testing environment is Arch Linux with kernel version 3.6.2-1-ARCH.

Suppose that I connect the external monitor at the console login screen. The screen blanks for a second, then only the laptop panel turns on, but I cannot type anything (although text cursor blinks).

As soon as I disconnect the external monitor, whatever I have typed (i.e. my username) seems to being typed and system turns back to normal.

I am attaching a dmesg log of the behavior I have described before (drm.debug=0xe is used in the kernel cmdline).


Kind regards
Comment 1 Daniel Vetter 2012-10-15 12:43:10 UTC
A few things:
- is this a regression?
- what happens if you boot up with that screen connected?
- can you enable CONFIG_PROVE_LOCKING and check whether that catches anything? Also, please retest and let the system hang for 2-3 minutes, that should be enough to anger to cpu stuck warning and print a backtrace of where we're stuck (if it's just a case of something stuck somewhere).
- Does the same happen with X hotplug (we kinda only check whether the console can print oopses).
- Can you ssh into the machine (might help for debuggin)?
Comment 2 Ioannis Koutras 2012-10-15 13:49:03 UTC
(In reply to comment #1)
> A few things:
> - is this a regression?

As far as I can tell, the bug was in kernel version 3.5.6, too. I had been using Linux in this laptop since June 2012 (not so sure about the Arch Linux kernel version at that time, 3.3 or 3.4, I guess), then I installed a different operating system. Until June I can verify that the external monitor was working. I do not know if it is relevant or not, but I have been always booting this machine via EFI, not BIOS (even before summer).

> - what happens if you boot up with that screen connected?

If I boot up with the external monitor connected, I get similar behavior: Screen blanks for a second as soon as KMS starts and I reach to the console's login screen with the text cursor blinking but without any response to typing.

> - can you enable CONFIG_PROVE_LOCKING and check whether that catches
> anything?
> Also, please retest and let the system hang for 2-3 minutes, that should be
> enough to anger to cpu stuck warning and print a backtrace of where we're
> stuck
> (if it's just a case of something stuck somewhere).

I have downloaded the vanilla sources for 3.6.2 and compiled the kernel with default Arch Linux kernel config + CONFIG_PROVE_LOCKING enabled. I have got a new log after waiting for 2-3 minutes and I will attach it soon. 

> - Does the same happen with X hotplug (we kinda only check whether the
> console
> can print oopses).

I am afraid I do not know what you mean by X hotplug. In case you are referring to plugging in the monitor while X is running, then I get the following behavior: The panel gets blank for one second, then everything goes back to normal, but the monitor does not show anything anyway. As soon as I use xrandr (i.e. I type xrandr -q on a terminal), the panel's screen gets stuck (similar to the console screen, I guess). If I disconnect the external monitor, everything goes back to normal. An X.org log file will also be attached in case you find it useful.

> - Can you ssh into the machine (might help for debuggin)?

I could provide SSH access to the machine, but it is not always turned on / online (it is a laptop, after all). So, please contact with me privately to arrange an SSH session in case you need access to it.
Comment 3 Ioannis Koutras 2012-10-15 13:50:01 UTC
Created attachment 83541 [details]
dmesg output with CONFIG_PROVE_LOCKING enabled
Comment 4 Ioannis Koutras 2012-10-15 13:51:37 UTC
Created attachment 83551 [details]
Xorg.0.log (external monitor connected while X is running and disconnected after a while)
Comment 5 Daniel Vetter 2012-10-15 14:20:56 UTC
Hm, nothing really seems to go wrong according to logs. The ssh access was more to check whether you can ssh into the box to check a few things (since the system seems to evidently be in good working order, safe that the display doesn't work).

Also the fact that the same thing happens under X suggest that it's a fundamental issue with our hotplug handling. So can you please ssh into that box while the external screen is plugged in and check whether anything unduly is going on? If your on the console, nothing really should happen. Most interesting is the irq/s rate (check vmstat 1) and if that's above just a few hundred, check which one's the culprit in /proc/interrupts.
Comment 6 Ioannis Koutras 2012-10-15 14:44:16 UTC
ok, I can login via SSH, so the system does not completely hang when an external monitor is connected. Nothing unduly seems to be happening, "vmstat 1" shows little to no difference during running.

Anything else I could try?
Comment 7 Ioannis Koutras 2012-10-17 10:07:37 UTC
I have also tried 3.4.14 and the problem persists here, too.

I want also to report that the external monitor uses VGA.

Additionally, the screen remains stuck if the Mini DisplayPort-to-VGA adapter stays connected to the laptop, i.e. I remove the VGA cable only.
Comment 8 Daniel Vetter 2012-10-17 13:39:56 UTC
Is this an apple dp->vga dongle or another one? If it's non-apple, please spec make&model.
Comment 9 Ioannis Koutras 2012-10-17 13:43:01 UTC
Yes, it is an Apple one, Model No.: A1307
Comment 10 Ioannis Koutras 2012-10-20 12:44:54 UTC
I have just tried connecting another external monitor by using an Apple DP->DVI adapter and I can report that it works.

Perhaps the issue is specific to VGA?
Comment 11 Daniel Vetter 2012-10-20 14:03:02 UTC
On Sat, Oct 20, 2012 at 2:44 PM,  <bugzilla-daemon@bugzilla.kernel.org> wrote:
> -- Comment #10 from Ioannis Koutras <ioannis.koutras@gmail.com>  2012-10-20
> 12:44:54 ---
> I have just tried connecting another external monitor by using an Apple
> DP->DVI
> adapter and I can report that it works.
>
> Perhaps the issue is specific to VGA?

The issue is likely specific to that specific dp->vga adaptor dongle -
other mostly work. We're trying to buy a few of the special ones, so
kink out the last few bugs in our dp dongle support code. Might take a
while to do all that though.
Comment 12 Ioannis Koutras 2012-10-20 19:10:33 UTC
(In reply to comment #11)
> On Sat, Oct 20, 2012 at 2:44 PM,  <bugzilla-daemon@bugzilla.kernel.org>
> wrote:
> The issue is likely specific to that specific dp->vga adaptor dongle -
> other mostly work. We're trying to buy a few of the special ones, so
> kink out the last few bugs in our dp dongle support code. Might take a
> while to do all that though.

I see. Is there anything I can do from my side to speed up the procedure?
Comment 13 Ioannis Koutras 2012-10-23 13:17:29 UTC
I'm starting to believe the problem is related to the monitor.

Samsung S22B150N is the external monitor which is not working (it's a VGA-only model).

Dell 2009Wt works in both DVI and VGA. I have used the same cable and adapter for the VGA setup, that I used for the Samsung monitor.

The Samsung monitor works though with the same setup in OS X.
Comment 14 Jani Nikula 2013-04-10 19:11:36 UTC
Ioannis, are you still experiencing the issue? Have you tried with more recent kernels; there have been plenty of KMS changes since 3.6.
Comment 15 Ioannis Koutras 2013-04-12 12:54:13 UTC
Dear all,

I do not own the notebook anymore, so I cannot test it out.