Bug 56171
Summary: | Audio stop working after unplugging AC power | ||
---|---|---|---|
Product: | Drivers | Reporter: | Nikita Tsukanov (keks9n) |
Component: | Sound(ALSA) | Assignee: | Jaroslav Kysela (perex) |
Status: | RESOLVED CODE_FIX | ||
Severity: | normal | CC: | tiwai |
Priority: | P1 | ||
Hardware: | All | ||
OS: | Linux | ||
Kernel Version: | 3.9-rc5 | Subsystem: | |
Regression: | Yes | Bisected commit-id: | |
Attachments: |
lsa-info with 42c364ace52ae6b4699105b39f2559c256b6cd4c, good
alsa-info with e152f18027552eb34006b35347e72bc805783027, bad More output |
Description
Nikita Tsukanov
2013-04-03 09:34:47 UTC
I have no other idea than the power-saving stuff if it's about HD-audio driver. Is it a regression? If so, could you bisect? Sound works fine with kernels prior to 3.9. I'll try to find the exact commit caused the issue. # git bisect log git bisect start # bad: [da241efcd9c3da2af6ba20055c7e158ec725005c] Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net git bisect bad da241efcd9c3da2af6ba20055c7e158ec725005c # good: [19f949f52599ba7c3f67a5897ac6be14bfcb1200] Linux 3.8 git bisect good 19f949f52599ba7c3f67a5897ac6be14bfcb1200 # bad: [7c2db36e730ee4facd341679ecb21ee73ba92831] Merge branch 'akpm' (incoming from Andrew) git bisect bad 7c2db36e730ee4facd341679ecb21ee73ba92831 # good: [c4bc705e45d91f900f7ec2e23a458280b084ae91] Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mszeredi/fuse git bisect good c4bc705e45d91f900f7ec2e23a458280b084ae91 # bad: [b5c78e04dd061b776978dad61dd85357081147b0] Merge tag 'staging-3.9-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging git bisect bad b5c78e04dd061b776978dad61dd85357081147b0 # bad: [06991c28f37ad68e5c03777f5c3b679b56e3dac1] Merge tag 'driver-core-3.9-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core git bisect bad 06991c28f37ad68e5c03777f5c3b679b56e3dac1 # bad: [83048ea7b1d11f5e560dea53873fb51d860202eb] Merge tag 'asoc-3.9' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-next git bisect bad 83048ea7b1d11f5e560dea53873fb51d860202eb # bad: [4e637c6e09fde6c1984a820621b5a77fad1acd34] ALSA: hda - add support for IDT 92HD95 HDA codec git bisect bad 4e637c6e09fde6c1984a820621b5a77fad1acd34 # good: [0b4df931ce3502311928bf66088cd76a2b5e604f] ALSA: hda - Avoid auto-mute or auto-mic of retasked jacks git bisect good 0b4df931ce3502311928bf66088cd76a2b5e604f # good: [0712eea349d8e2b6d0e44b94a752d999319027fb] ALSA: hda - Add a fixup for Packard-Bell desktop with ALC880 git bisect good 0712eea349d8e2b6d0e44b94a752d999319027fb # good: [6f7c83afc6cc3f66d13e4ad0a0f5693d9175e1ab] ALSA: hda - Look for boost controls more deeply git bisect good 6f7c83afc6cc3f66d13e4ad0a0f5693d9175e1ab # good: [657e1b931d42882cb0a59b599247bef696c22406] ALSA: hda - Select auto-parser as default for AD codecs git bisect good 657e1b931d42882cb0a59b599247bef696c22406 # bad: [5397145f4faeabbb7937ac784f734b06b20ed921] ALSA: hda - Add auto-mute support to PB desktop git bisect bad 5397145f4faeabbb7937ac784f734b06b20ed921 # good: [49ba4f94bddb7f5272c4596d505f94355cc3fbd2] ALSA: hdsp - Remove obsolete settings functions git bisect good 49ba4f94bddb7f5272c4596d505f94355cc3fbd2 # bad: [e4a395e7819b1e666b2e9da22234059f403dbc11] ALSA: hda - Fix missing path between aamix and outputs in AD codecs git bisect bad e4a395e7819b1e666b2e9da22234059f403dbc11 # bad: [2cf215bfaa01384374291a118c8152ab18a55a63] Merge branch 'topic/hda-gen-parser' into for-next git bisect bad 2cf215bfaa01384374291a118c8152ab18a55a63 # bad: [e152f18027552eb34006b35347e72bc805783027] Merge branch 'for-linus' into for-next git bisect bad e152f18027552eb34006b35347e72bc805783027 Make sure that the last commit e152f18027 is really still a bad commit. The previous one, 2cf215bfaa0, is the commit merging the whole bunch of new stuff, but the last one contains really little changes regarding HD-audio. Also, please give alsa-info.sh outputs (run with --no-upload option) on both working and non-working kernels to this bugzilla. Created attachment 97311 [details]
lsa-info with 42c364ace52ae6b4699105b39f2559c256b6cd4c, good
Created attachment 97321 [details]
alsa-info with e152f18027552eb34006b35347e72bc805783027, bad
git log commit e152f18027552eb34006b35347e72bc805783027 Merge: 49ba4f9 42c364a Author: Takashi Iwai <tiwai@suse.de> Date: Wed Jan 23 08:31:34 2013 +0100 Merge branch 'for-linus' into for-next This is a preliminary merge before the upcoming merge of generic parser branch. commit 42c364ace52ae6b4699105b39f2559c256b6cd4c Author: Takashi Iwai <tiwai@suse.de> Date: Mon Jan 21 16:53:37 2013 +0100 ALSA: hda - Add Conexant CX20755/20756/20757 codec IDs These are just compatible with other CX2075x codecs. Cc: <stable@vger.kernel.org> Signed-off-by: Takashi Iwai <tiwai@suse.de> e152f18027552eb34006b35347e72bc805783027 - problem is present 42c364ace52ae6b4699105b39f2559c256b6cd4c - problem isn't present Note: Both attached outputs were taken after testing (i. e. running mplayer, unpluggin AC power and running alsa force-reload in case of bad one. If you need alsa-info from "clean" system I can take one. Created attachment 97331 [details]
More output
before_mplayer - before doing anything (pulseaudio probably has already started)
before_unplug - mplayer is playing music
after_unplug - WRWRWRWRWRWR instead of music, mplayer's UI shows that music plays extremely slow (1 second per 4-5 real seconds)
Hmm, if your bisection is really correct, there only three commits relevant with HD-audio: 42c364ace52ae6b4699105b39f2559c256b6cd4c ALSA: hda - Add Conexant CX20755/20756/20757 codec IDs 6ab317419c62850a71e2adfd1573e5ee87d8774f ALSA: hda - Allow power_save_controller option override DCAPS f4f0a8c4783a0258f2d0020a67fd619ce41a02a3 ALSA: hda - print power state for AFG node in proc file Most doubtful one is the second commit, but I see no problem there. Could you continue bisection until spotting out the culprit commit? git checkout 42c364ace52ae6b4699105b39f2559c256b6cd4c # Last good one git cherry-pick 6ab317419c62850a71e2adfd1573e5ee87d8774f #Suspicious one Compile && Install && Reboot && mplayer + unplug power = awful noise When booting without AC adapter plugged in I get this on dmesg: [ 14.204371] hda-intel 0000:00:1b.0: azx_get_response timeout, switching to polling mode: last cmd=0x010f0600 [ 15.212210] hda-intel 0000:00:1b.0: No response from codec, disabling MSI: last cmd=0x010f0600 [ 16.220015] hda-intel 0000:00:1b.0: spurious response 0x0:0x0, last cmd=0x10f0600 [ 16.220020] hda-intel 0000:00:1b.0: spurious response 0x0:0x0, last cmd=0x10f0600 [ 16.220021] hda-intel 0000:00:1b.0: spurious response 0x0:0x0, last cmd=0x10f0600 [ 16.220022] hda-intel 0000:00:1b.0: spurious response 0x0:0x0, last cmd=0x10f0600 [ 16.220023] hda-intel 0000:00:1b.0: spurious response 0x0:0x0, last cmd=0x10f0600 [ 16.220024] hda-intel 0000:00:1b.0: spurious response 0x0:0x0, last cmd=0x10f0600 [ 16.220025] hda-intel 0000:00:1b.0: spurious response 0x0:0x0, last cmd=0x10f0600 [ 16.220026] hda-intel 0000:00:1b.0: spurious response 0x0:0x0, last cmd=0x10f0600 [ 16.220027] hda-intel 0000:00:1b.0: spurious response 0x0:0x0, last cmd=0x10f0600 [ 16.220028] hda-intel 0000:00:1b.0: spurious response 0x0:0x0, last cmd=0x10f0600 [ 16.220029] hda-intel 0000:00:1b.0: spurious response 0x0:0x0, last cmd=0x10f0600 [ 16.220030] hda-intel 0000:00:1b.0: spurious response 0x0:0x0, last cmd=0x10f0600 [ 16.220031] hda-intel 0000:00:1b.0: spurious response 0x0:0x0, last cmd=0x10f0600 [ 16.220031] hda-intel 0000:00:1b.0: spurious response 0x0:0x0, last cmd=0x10f0600 [ 16.220032] hda-intel 0000:00:1b.0: spurious response 0x0:0x0, last cmd=0x10f0600 [ 16.220033] hda-intel 0000:00:1b.0: spurious response 0x0:0x0, last cmd=0x10f0600 [ 16.220034] hda-intel 0000:00:1b.0: spurious response 0x0:0x0, last cmd=0x10f0600 [ 16.220035] hda-intel 0000:00:1b.0: spurious response 0x0:0x0, last cmd=0x10f0600 [ 16.220036] hda-intel 0000:00:1b.0: spurious response 0x0:0x0, last cmd=0x10f0600 [ 16.220037] hda-intel 0000:00:1b.0: spurious response 0x0:0x0, last cmd=0x10f0600 [ 16.220038] hda-intel 0000:00:1b.0: spurious response 0x0:0x0, last cmd=0x10f0600 [ 16.220039] hda-intel 0000:00:1b.0: spurious response 0x0:0x0, last cmd=0x10f0600 [ 16.220040] hda-intel 0000:00:1b.0: spurious response 0x0:0x0, last cmd=0x10f0600 [ 16.220041] hda-intel 0000:00:1b.0: spurious response 0x0:0x0, last cmd=0x10f0600 [ 16.220042] hda-intel 0000:00:1b.0: spurious response 0x0:0x0, last cmd=0x10f0600 Looking at alsa-info.sh output, I think this must be related with power-saving. The power_save option value has been changed to 1. Also, power_save_controller is set to 1 as well. It means, someone screws up power_save_controller option unnecessarily. The commit 6ab31741 changed the power_save_controller option so that it can override the behavior even if the driver capability disables the feature. This assumed that no one actively changes this option, but my assumption was too naive -- it seems that some power-management stuff tries to screw up things stupidly without knowing what's doing. So, could you try to revert 6ab31741 and check whether this fixes the issue? If so, I'll revert for the next rc. Reverting this commit solves the problem OK. I reverted the affecting commit now. It'll be included in the next pull request sent to Linus. Thanks for your quick tests! BTW, I have simular issue with 3.11 and Dell M4800: when power_save_controller=Y and power_save=1 it occasionly stops any audio output. Unfortunately, I don't know the exact sequence of actions to reproduce it, but turning off power saving "solves" the problem. If it's a Haswell chip, this might be rather the runtime PM. In that case, setting power_save_controller=n should suffice. Yes, it's i7-4800MQ with Realtek ALC292. OK, then please open another bug report. I can add a patch to disable the runtime PM for the corresponding chipset. (I guess it's either LynxPoint or LynxPoint-LP?) Once I get it another time to gather alsa-info, I'll fill a new bug report. Or you need just alsa-info from normal state? Yes, I just need the PCI ID. But, of course, it'd be better if you can confirm power_save_controller=0 fixes the issue. |