Bug 67490 - Intel driver 2.21.13 hangs on shutdown process
Summary: Intel driver 2.21.13 hangs on shutdown process
Status: RESOLVED WORKSFORME
Alias: None
Product: xorg
Classification: Unclassified
Component: Driver/intel (show other bugs)
Version: unspecified
Hardware: Other All
: medium normal
Assignee: Chris Wilson
QA Contact: Intel GFX Bugs mailing list
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-07-29 15:54 UTC by Frederic Bezies
Modified: 2013-08-05 18:15 UTC (History)
3 users (show)

See Also:
i915 platform:
i915 features:


Attachments
Xorg.0.log with 2.21.13 driver (27.02 KB, text/plain)
2013-07-29 16:31 UTC, Frederic Bezies
no flags Details
dmesg with intel driver 2.21.13 (51.81 KB, text/plain)
2013-07-29 16:32 UTC, Frederic Bezies
no flags Details

Description Frederic Bezies 2013-07-29 15:54:36 UTC
Hello.

I'm getting an annoying bug I fixed by downgrading to intel driver 2.21.12. When I try to shutdown my laptop (a Toshiba Satellite L300-2CZ with an intel GMA 4500 GPU), my computer doesn't stop.

As I said, downgrading to previous driver version (2.21.12) fixes this behaviour.

I'm using a fully up-to-date Archlinux with testing repository enabled.

So, I have linux kernel 3.10.4, Xorg 1.14.2 and of course intel driver 2.21.12.

I open a bug on archlinux bugtracker : https://bugs.archlinux.org/task/36317

Feel free to ask me any info you need to fix this bug.
Comment 1 Chris Wilson 2013-07-29 16:03:14 UTC
Xorg.0.log and dmesg please.
Comment 2 Frederic Bezies 2013-07-29 16:31:16 UTC
Created attachment 83218 [details]
Xorg.0.log with 2.21.13 driver
Comment 3 Frederic Bezies 2013-07-29 16:32:39 UTC
Created attachment 83219 [details]
dmesg with intel driver 2.21.13
Comment 4 Chris Wilson 2013-07-29 17:11:40 UTC
Whereabouts does it hang during shutdown? Is the machine still accessible by the network at that point? Can you login/switch to a VT, and see what's hung?
Comment 5 Frederic Bezies 2013-07-29 17:29:19 UTC
(In reply to comment #4)
> Whereabouts does it hang during shutdown? Is the machine still accessible by
> the network at that point? Can you login/switch to a VT, and see what's hung?

Just after gdm is stopped. And I cannot login or switch to another tty.
Comment 6 Chris Wilson 2013-07-29 17:35:29 UTC
It is sounding like a kernel oops, and I can't identify any likely culprit between .12 and .13. Would you be able to bisect this?
Comment 7 Frederic Bezies 2013-07-29 17:36:45 UTC
I can try, just tell me how to do this :)
Comment 8 Chris Wilson 2013-07-29 17:49:00 UTC
(You may need to download some dependencies.)

$ git clone git://anongit.freedesktop.org/xorg/driver/xf86-video-intel
$ cd xf86-video-intel
$ ./autogen --prefix=/usr
$ make && sudo make install

# confirm everything boots fine and you can reproduce the bug

$ git checkout 2.21.12
$ make && sudo make install

# confirm it works

$ git bisect start
$ git bisect good
$ git bisect bad
# git will select a commit halfway between the two endpoints
$ make && sudo make install

# test
$ git bisect good # if it shuts down cleanly, or
$ git bisect bad 

Then repeat the make, install, test, git bisect (good|bad) until git pronounces a winner.
Comment 9 Frederic Bezies 2013-07-29 18:34:26 UTC
(In reply to comment #8)
> (You may need to download some dependencies.)
> 
> $ git clone git://anongit.freedesktop.org/xorg/driver/xf86-video-intel
> $ cd xf86-video-intel
> $ ./autogen --prefix=/usr
> $ make && sudo make install
> 
> # confirm everything boots fine and you can reproduce the bug

Ok, worked.

> 
> $ git checkout 2.21.12
> $ make && sudo make install
> 
> # confirm it works
> 

Worked too.

> $ git bisect start
> $ git bisect good
> $ git bisect bad
> # git will select a commit halfway between the two endpoints
> $ make && sudo make install

Nothing happened here :( 

git did not grab anything :(

A step is missing here, or did I missed something ?

> 
> # test
> $ git bisect good # if it shuts down cleanly, or
> $ git bisect bad 
> 
> Then repeat the make, install, test, git bisect (good|bad) until git
> pronounces a winner.

I hope I can help more !
Comment 10 Chris Wilson 2013-07-29 18:40:22 UTC
(In reply to comment #9)
> (In reply to comment #8)
> > $ git bisect start
> > $ git bisect good
> > $ git bisect bad
> > # git will select a commit halfway between the two endpoints
> > $ make && sudo make install
> 
> Nothing happened here :( 
> 
> git did not grab anything :(
> 
> A step is missing here, or did I missed something ?]

No, I missed something.

That should have been:
$ git bisect start
$ git bisect good
$ git bisect bad master

In order to restart, you will want to first do a "git bisect reset"
Comment 11 Frederic Bezies 2013-07-29 18:51:25 UTC
(In reply to comment #10)
> (In reply to comment #9)
> > (In reply to comment #8)
> > > $ git bisect start
> > > $ git bisect good
> > > $ git bisect bad
> > > # git will select a commit halfway between the two endpoints
> > > $ make && sudo make install
> > 
> > Nothing happened here :( 
> > 
> > git did not grab anything :(
> > 
> > A step is missing here, or did I missed something ?]
> 
> No, I missed something.
> 
> That should have been:
> $ git bisect start
> $ git bisect good
> $ git bisect bad master
> 
> In order to restart, you will want to first do a "git bisect reset"

Ok. Thanks for the info. Don't have time tonight. Will report early tomorrow morning. Sorry for the delay. Real life...
Comment 12 Frederic Bezies 2013-07-30 08:30:06 UTC
Do not understand. Try this morning, and git version is working. No more shutdown hang.

Looked at git log, and did this commit the answer to my problem ?!

http://cgit.freedesktop.org/xorg/driver/xf86-video-intel/commit/?id=d7465ece29c9ae665a5a9f5bdac764a19062786e

Or this one ?

http://cgit.freedesktop.org/xorg/driver/xf86-video-intel/commit/?id=5751b9f1f5beb943db8cb5d260379ae39eb18db4

Will try to verify with this AUR package and report : https://aur.archlinux.org/packages/xf86-video-intel-git/
Comment 13 Frederic Bezies 2013-07-30 08:43:01 UTC
Verified again. Less than 12 hours ago, shutdown wasn't working on git. Now, with the new commits, shutdown is ok.

So, one of the commits fixed the hanging shutdown bug. But which one ?
Comment 14 Chris Wilson 2013-07-30 08:59:40 UTC
You are not using SNA, which is why this is quite strange. You have two choices, either do a normal bisect looking for the commit that introduced the hang, or a "reversed" bisect that looks for the commit that fixes the hang. In a reversed bisect, you would treat as any hang as good, and any working commit as bad:

$ git bisect start good 2.21.13 # broken
$ git bisect bad master # works
$ make && sudo make install # test
$ git bisect bad # if it works (shuts down without a hang)
$ git bisect good # if it hangs

and repeat make / git bisect (bad|good).

I suspect that both bisects will be useful to understanding this mystery.
Comment 15 Frederic Bezies 2013-07-30 09:15:39 UTC
Well, I will try. But I still do not understand why hang disappeared. Will try to broke shutdown again today, on my spare time.
Comment 16 Frederic Bezies 2013-07-30 13:47:22 UTC
Starting get bissecting now, but one more info : I'm using --enable-dri options in configure step.

Don't know if it is matters or not.
Comment 17 Chris Wilson 2013-07-30 13:52:50 UTC
--enable-dri is the default, so it should be fine.
Comment 18 Frederic Bezies 2013-07-30 14:23:10 UTC
I'm speechless. All is working now, even driver 2.21.13 !!!! I noticed libx11 was upgraded. Related or not ?!
Comment 19 Chris Wilson 2013-07-30 14:26:24 UTC
Unlikely, it all doesn't make a lot of sense. My suspicion is something went wrong in the packaging and shutdown scripts...
Comment 20 Frederic Bezies 2013-08-05 10:19:41 UTC
I have to add this in /etc/X11/xorg.conf.d/20-intel.conf:

Section "Device"
Identifier "Intel Graphics"
Driver "intel"
Option "AccelMethod" "uxa"
EndSection

Sna seems to be buggy with my laptop GPU.
Comment 21 Chris Wilson 2013-08-05 13:11:24 UTC
See above. Very, very unlikely to be the reason.
Comment 22 Frederic Bezies 2013-08-05 17:59:06 UTC
So explain me why I do not use 20-intel.conf with official driver, shutdown is hanging.

I'm only reporting what is happening !
Comment 23 Chris Wilson 2013-08-05 18:15:47 UTC
As a userspace process, X is killable just like any other. The only times it cannot are if the kernel is broken - that is the i915.ko oops whilst holding its mutex is often enough to wedge the system. Until you can pinpoint where it actually dies, probably requiring remote logging, you're not going to be able to solve this other than using a bisect.

Note in the original bug report, the issue occurred with UXA. And a broken package is a far more likely explanation.


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.