Bug 34345 - [SNB] closing armagetron makes screen black on SandyBridge
Summary: [SNB] closing armagetron makes screen black on SandyBridge
Status: RESOLVED FIXED
Alias: None
Product: xorg
Classification: Unclassified
Component: Driver/intel (show other bugs)
Version: git
Hardware: x86 (IA32) Linux (All)
: medium normal
Assignee: Chris Wilson
QA Contact: Xorg Project Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-02-16 08:54 UTC by Paulo Zanoni
Modified: 2011-11-09 05:31 UTC (History)
1 user (show)

See Also:
i915 platform:
i915 features:


Attachments
dmesg (36.85 KB, text/plain)
2011-02-21 05:10 UTC, Paulo Zanoni
no flags Details
Xorg.0.log (23.62 KB, text/plain)
2011-02-21 05:11 UTC, Paulo Zanoni
no flags Details
All files inside /sys/kernel/debug/dri/0 (236.65 KB, application/x-bzip)
2011-02-21 05:30 UTC, Paulo Zanoni
no flags Details
dump before (11.06 KB, text/plain)
2011-02-25 10:52 UTC, Paulo Zanoni
no flags Details
dump after (11.06 KB, text/plain)
2011-02-25 10:53 UTC, Paulo Zanoni
no flags Details
diff between the 2 dump files (1.18 KB, text/plain)
2011-02-25 10:54 UTC, Paulo Zanoni
no flags Details

Description Paulo Zanoni 2011-02-16 08:54:28 UTC
Hello

I came from bug #33422

Whenever I close Armagetron on a SandyBrige machine, the screen gets black. Changing to VT1 and back to X doesn't fix anything. This is under IceWM (which I belive is not composited).

Steps to reproduce:
- start Armagetron on IceWM (or probably any other non-composited desktop)
- select "exit game" (you don't need to play)
- screen will get black.

This bug happens with Xserver 1.9.4, ddx 2.14, drm 2.4.23, kernel 2.6.37, Mesa7.10.

Today I also tested the same stack but with Mesa git (7.11) and kernel tarball downloaded from kernel.org (2.6.38-rc5).

[pzanoni@mandriva ~]$ lspci -nn | grep VGA
00:02.0 VGA compatible controller [0300]: Intel Corporation Device [8086:0116] (rev 09)

[pzanoni@mandriva ~]$ cat /proc/cpuinfo | grep "model name"
model name	: Intel(R) Core(TM) i7-2630QM CPU @ 2.00GHz
model name	: Intel(R) Core(TM) i7-2630QM CPU @ 2.00GHz
model name	: Intel(R) Core(TM) i7-2630QM CPU @ 2.00GHz
model name	: Intel(R) Core(TM) i7-2630QM CPU @ 2.00GHz
model name	: Intel(R) Core(TM) i7-2630QM CPU @ 2.00GHz
model name	: Intel(R) Core(TM) i7-2630QM CPU @ 2.00GHz
model name	: Intel(R) Core(TM) i7-2630QM CPU @ 2.00GHz
model name	: Intel(R) Core(TM) i7-2630QM CPU @ 2.00GHz

Link to armagetron .spec file and sources:
http://svn.mandriva.com/cgi-bin/viewvc.cgi/packages/cooker/armagetron/current/

If you need me to do any debugging/printf/breakpoint/patching, just ask. Any debugging tips would be welcome.
Comment 1 Chris Wilson 2011-02-19 04:14:50 UTC
dmesg, Xorg.log and /sys/kernel/debug/dri/0/i915_error_state?
Comment 2 Paulo Zanoni 2011-02-21 05:09:52 UTC
(In reply to comment #1)
> dmesg, Xorg.log and /sys/kernel/debug/dri/0/i915_error_state?

Just after reproducing the "black screen" error:

[root@mandriva 0]# cat /sys/kernel/debug/dri/0/i915_error_state
no error state collected

Other files will be attached.
Comment 3 Paulo Zanoni 2011-02-21 05:10:42 UTC
Created attachment 43595 [details]
dmesg

Dmesg after reproducing the bug.
Comment 4 Paulo Zanoni 2011-02-21 05:11:53 UTC
Created attachment 43596 [details]
Xorg.0.log

Xorg log after reproducing the bug.
Comment 5 Paulo Zanoni 2011-02-21 05:21:26 UTC
Just an additional information:

After I get the black screen, it seems that X is still working. If I ssh to the machine and do some command like "DISPLAY=:0 xdpyinfo", it still works.

[pzanoni@mandriva ~]$ DISPLAY=:0 xrandr
Screen 0: minimum 320 x 200, current 1366 x 768, maximum 8192 x 8192
LVDS1 connected 1366x768+0+0 (normal left inverted right x axis y axis) 309mm x 174mm
   1366x768       60.0*+
   1024x768       60.0  
   800x600        60.3     56.2  
   640x480        59.9  
VGA1 disconnected (normal left inverted right x axis y axis)
HDMI1 disconnected (normal left inverted right x axis y axis)
DP1 disconnected (normal left inverted right x axis y axis)

So I did:

[pzanoni@mandriva ~]$ export DISPLAY=:0
[pzanoni@mandriva ~]$ xrandr --output LVDS1 --mode 1024x768

And now I *can* see my desktop! (although the different aspect ratio gives me 2 ugly black rectangles on the screen borders).

But then I did:

[pzanoni@mandriva ~]$ xrandr --output LVDS1 --mode 1366x768

And the screen is black again·

Then I noticed there is new information in Xorg.0.log. Pasting here just the end of the file (since the beginning is already attached in previous comment):

[   639.351] (II) intel(0): EDID vendor "INL", prod id 20
[   639.351] (II) intel(0): DDCModeFromDetailedTiming: 1366x768 Warning: We only handle separate sync.
[   639.351] (II) intel(0): Printing DDC gathered Modelines:
[   639.351] (II) intel(0): Modeline "1366x768"x0.0   71.00  1366 1414 1446 1498  768 769 773 790 -hsync -vsync (47.4 kHz)
[   679.006] (II) intel(0): EDID vendor "INL", prod id 20
[   679.006] (II) intel(0): DDCModeFromDetailedTiming: 1366x768 Warning: We only handle separate sync.
[   679.006] (II) intel(0): Printing DDC gathered Modelines:
[   679.006] (II) intel(0): Modeline "1366x768"x0.0   71.00  1366 1414 1446 1498  768 769 773 790 -hsync -vsync (47.4 kHz)
[   679.017] (II) intel(0): Allocated new frame buffer 1024x768 stride 4096, tiled
[   701.377] (II) intel(0): EDID vendor "INL", prod id 20
[   701.377] (II) intel(0): DDCModeFromDetailedTiming: 1366x768 Warning: We only handle separate sync.
[   701.377] (II) intel(0): Printing DDC gathered Modelines:
[   701.377] (II) intel(0): Modeline "1366x768"x0.0   71.00  1366 1414 1446 1498  768 769 773 790 -hsync -vsync (47.4 kHz)
[   701.385] (II) intel(0): Allocated new frame buffer 1408x768 stride 5632, tiled


[root@mandriva pzanoni]# cat /sys/kernel/debug/dri/0/i915_error_state
no error state collected

[pzanoni@mandriva ~]$ dmesg | tail
xt_time: kernel timezone is -0300
u32 classifier
    Actions configured
composite sync not supported
fuse init (API version 7.16)
composite sync not supported
composite sync not supported
composite sync not supported
composite sync not supported
composite sync not supported
Comment 6 Paulo Zanoni 2011-02-21 05:30:02 UTC
Created attachment 43599 [details]
All files inside /sys/kernel/debug/dri/0

Generated with the following commands:

[root@mandriva 0]# for i in *; do echo "== File $i:" >> /tmp/debugfiles.txt; cat $i >> /tmp/debugfiles.txt; done
[root@mandriva 0]# cd /tmp/
[root@mandriva tmp]# tar cvjf debugfiles.tar.bz2 debugfiles.txt
Comment 7 Paulo Zanoni 2011-02-21 06:08:15 UTC
For the record:
- After the last comments I wrote, I decided to test today's mesa master branch (commit 2c6793fb6bc89df16c23f727bcb072a157ab8d10 is the latest), and the problem still happens.
Comment 8 Chris Wilson 2011-02-24 02:24:17 UTC
So it appears to be a modesetting fail.

After a fresh boot, can the problem be reproduced simply by:

$ xrandr --output LVDS1 --mode 1024x768
$ xrandr --output LVDS1 --preferred

If so, lets start with the basics and grab a intel_reg_dumper before and after that sequence.
Comment 9 Paulo Zanoni 2011-02-25 10:50:37 UTC
(In reply to comment #8)
> So it appears to be a modesetting fail.
> 
> After a fresh boot, can the problem be reproduced simply by:
> 
> $ xrandr --output LVDS1 --mode 1024x768
> $ xrandr --output LVDS1 --preferred
> 

No =(
Also tried 640x480.

I reproduced the bug with "armagetron" and I'll attach the reg dumps.
Comment 10 Paulo Zanoni 2011-02-25 10:52:27 UTC
Created attachment 43824 [details]
dump before

Regdump before reproducing the bug with armagetron.

Before booting the machine I removed it from the power chord and also removed the battery (it's a laptop).
Comment 11 Paulo Zanoni 2011-02-25 10:53:34 UTC
Created attachment 43825 [details]
dump after

Dump after starting armagetron and selecting "exit game" (i.e: I had a black screen)
Comment 12 Paulo Zanoni 2011-02-25 10:54:40 UTC
Created attachment 43826 [details]
diff between the 2 dump files

Diff between the dump files
Comment 13 Kenneth Graunke 2011-11-08 21:58:23 UTC
Paulo, does this still happen with a recent stack?  A lot has changed since February.
Comment 14 Paulo Zanoni 2011-11-09 05:31:37 UTC
(In reply to comment #13)
> Paulo, does this still happen with a recent stack?  A lot has changed since
> February.

I don't have that machine anymore, many many things have changed and I can't reproduce the bug using the current stack on my "current" SNB machine, so I guess we can close this... If anyone can reproduce the bug, feel free to reopen.


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.