Bug 11889

Summary: snd-hda-intel prevents machine to power off
Product: Drivers Reporter: Luiz Fernando N. Capitulino (lcapitulino)
Component: Sound(ALSA)Assignee: Jaroslav Kysela (perex)
Status: RESOLVED CODE_FIX    
Severity: normal CC: tiwai
Priority: P1    
Hardware: All   
OS: Linux   
Kernel Version: 2.6.28-rc2 Subsystem:
Regression: --- Bisected commit-id:
Attachments: patch from Takashi Iwai

Description Luiz Fernando N. Capitulino 2008-10-29 08:00:08 UTC
Distribution: Mandriva 2009.0 (there are reports from others)
Hardware Environment: eeepc 701
Problem Description:

If there is some process with the sound device opened and I try to power off the machine, it will not power off completely. Ie, it will shutdown all the devices (display inclusive) but its power led will remain lighted-up and the fan running.

Steps to reproduce:

1. Open the sound device or log into some window manager which opens the sound device (eg, KDE)
2. Try to power off, for example with:

# echo o > /proc/sysrq-trigger

References

This problem has been reported for various distros:

https://qa.mandriva.com/show_bug.cgi?id=44752
https://bugzilla.redhat.com/show_bug.cgi?id=444115
https://bugs.launchpad.net/ubuntu/+source/linux-source-2.6.22/+bug/126140
Comment 1 Luiz Fernando N. Capitulino 2008-10-29 08:02:50 UTC
Created attachment 18496 [details]
patch from Takashi Iwai

This problem has been discussed upstream in this thread:

http://lkml.org/lkml/2008/10/28/198

And the attached patch has been made by Takashi Iwai.
Comment 2 Luiz Fernando N. Capitulino 2008-10-29 08:07:11 UTC
I have tested the patch from comment #1, and it fixes the problem for me.

Just for reference, loading the module with power_save=10 also fixes the problem and the patch is based on this fact.
Comment 3 Luiz Fernando N. Capitulino 2008-10-29 08:11:29 UTC
Takashi, what's your plan for this patch? I think it should be merged in Linus's tree and 2.6.27-stable.

Also, I've found that this bug might be a dupe of #7195.
Comment 4 Takashi Iwai 2008-10-29 08:16:17 UTC
Thanks for checking.  Glad to hear that works.

I'll try the patch for another couple of my machines to confirm that it doesn't break, at least.  After that, I'll merge it to sound git tree and send a pull request for 2.6.28.

And, yes, it can be a good candidate for stable kernels.
Comment 5 Luiz Fernando N. Capitulino 2008-10-29 08:49:37 UTC
Please, let me know when you are done with the tests so that I can merge this on Mandriva kernel.
Comment 6 Takashi Iwai 2008-10-31 01:45:57 UTC
Now it's merged to Linus tree.
Comment 7 Luiz Fernando N. Capitulino 2008-10-31 05:10:45 UTC
Great! Closing as fixed then.