weird sound problems with ATIIXP, skype problems

I have an ACER Travelmate laptop with an IXP150 AC’97 sound card, and I’ve been having sound-related problems for a long time. I recently upgraded to opensuse 11.0 (new installation) but that didn’t solve the problem.

When I log in, sometimes I can hear the greeting sound, but it suddenly stops and there is no sound. For example, MPlayer talks about broken pipe in AO_ALSA. I have to restart the soundcard.
Sometimes I don’t hear the greeting sound at all, I have sound, but knotify eats 99% CPU… strange that it behaves differently every time.

Skype doesn’t work. I can login, I can set the sound options, sometimes I can even have a good test sound, but during the test call I don’t hear anything starting from the ringing. And skype seems to block sound: if I try to run mplayer, it says that device is busy. In skype I get error messages like this:

ALSA lib pcm.c:2202:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.hdmi
RtApiAlsa: callback thread error (RtApiAlsa: audio write error for device (ATI IXP (hw:IXP,0)): Exec format error.) … closing stream.

However, the problem seems to be more general than only a skype bug. I’ve tried to search the forums, and I’ve tried quite a few things, I installed the newest alsa (which I could through yast), alsa-firmware, I blacklisted the snd_atiixp_modem module, I played around with the options (ac97_codec=0 etc.) in /etc/modprobe.d/sound…

Here are my sound setting details (outputs of tsalsa and alsa-info.sh):

tsalsa.txt - nopaste.com (beta)
http://www.alsa-project.org/db/?f=0d9a46dfe068943dbffe419cbd8afb85ecbd68db

Any help would be really appreciated.

I don’t understand.

You stated you installed the latest alsa (which happens to be 1.0.19) but the scripts you provided indicate 1.0.17 and 1.0.18, which is the stock version of alsa that comes with openSUSE-11.1. There is a newer version (of alsa) that can be applied thru YaST with the appropriate repos in place.

There is no point in my looking at the script, if it was run before you updated alsa.

So please run the script again, so that it reflects the version of alsa that you have installed (which I assume is 1.0.19 as you stated you installed the latest version) and please also provide the output of: rpm -qa | grep alsa
rpm -qa | grep pulse
rpm -q libasound2
uname -a
cat /etc/modprobe.d/soundWith that information, I can do some research to see if there are any updates or configuration tweaks that can be applied.

Further to my previous post, if you wish to do this on your own (although I am more than willing to try to help with basic sound (not with skype - as I do not have any skype knowledge)) you could try working your way through: SDB:AudioTroubleshooting - openSUSE

Note there is a guide here for updating to the latest alsa version via zypper/yast: Alsa-update - openSUSE Note as part of that update you need to update all the alsa applications (you currently have installed) plus install the appropriate alsa-driver-kmp …

Thank you very much for your help.

You were right, I didn’t try hard enough to install the latest alsa packages. Now I hope I managed:

> rpm -qa | grep alsa
alsa-tools-1.0.19.git20090120-1.7
alsa-firmware-1.0.19.git20090120-1.1
alsa-oss-1.0.17.git20080715-2.16
alsa-utils-1.0.19.git20090130-2.1
alsa-plugins-jack-1.0.19.git20090123-1.4
alsa-driver-kmp-default-1.0.19.20090201_2.6.27.7_9.1-1.1
alsa-plugins-pulse-1.0.19.git20090123-1.4
tsalsa-20080914-0.pm.1
alsa-driver-unstable-kmp-default-1.0.19.20090131_2.6.27.7_9.1-1.1
alsa-plugins-1.0.19.git20090123-1.4
alsa-1.0.19.git20090130-1.1

> rpm -qa | grep pulse
pulseaudio-module-zeroconf-0.9.12-9.6
libpulsecore4-0.9.12-9.6
pulseaudio-utils-0.9.12-9.6
pulseaudio-module-jack-0.9.12-9.6
libpulse0-0.9.12-9.6
libpulse-mainloop-glib0-0.9.12-9.6
pulseaudio-module-lirc-0.9.12-9.6
pulseaudio-0.9.12-9.6
pulseaudio-module-bluetooth-0.9.12-9.6
alsa-plugins-pulse-1.0.19.git20090123-1.4
libpulse-browse0-0.9.12-9.6
pulseaudio-esound-compat-0.9.12-9.6
libxine1-pulse-1.1.15-20.8
pulseaudio-module-x11-0.9.12-9.6

> rpm -q libasound2
libasound2-1.0.19.git20090130-1.1

> uname -a
Linux linux-5u22 2.6.27.7-9-default #1 SMP 2008-12-04 18:10:04 +0100 i686 i686 i386 GNU/Linux

> cat /etc/modprobe.d/sound

options snd slots=snd-atiixp

hB6S.2vvYHXqtdU0:IXP150 AC’97 Audio Controller

alias snd-card-0 snd-atiixp

> cat /proc/asound/cards
0 [IXP ]: ATIIXP - ATI IXP
ATI IXP rev 0 with ALC202 at 0xe8003000, irq 17
1 [Modem ]: ATIIXP-MODEM - ATI IXP Modem
ATI IXP Modem rev 1 at 0xe8003400, irq 17

> cat /proc/asound/modules
0 snd_atiixp
1 snd_atiixp

Further information:
tsalsa.txt - nopaste.com (beta)
http://www.alsa-project.org/db/?f=7417f5c91980f21d533acd7358579ec980bc6632

I rebooted after updating the packages, there was no greeting sound. When I tried to run speaker-test I got

> speaker-test 1.0.19

Playback device is plug:front
Stream parameters are 48000Hz, S16_LE, 2 channels
WAV file(s)
Playback open error: -16,Device or resource busy
Playback open error: -16,Device or resource busy
Playback open error: -16,Device or resource busy
^C

Then I found out that knotify eats CPU, I killed it, and then speaker-test worked properly.

I noticed the following lines in /var/log/boot.msg:

<4>snd_atiixp_modem: Unknown symbol snd_verbose_printd
<4>snd_atiixp_modem: disagrees about version of symbol snd_pcm_new
<4>snd_atiixp_modem: Unknown symbol snd_pcm_new
<4>snd_atiixp_modem: disagrees about version of symbol snd_pcm_lib_preallocate_pages_for_all
<4>snd_atiixp_modem: Unknown symbol snd_pcm_lib_preallocate_pages_for_all
<4>snd_atiixp_modem: disagrees about version of symbol snd_pcm_stop
<4>snd_atiixp_modem: Unknown symbol snd_pcm_stop
<4>snd_atiixp_modem: disagrees about version of symbol snd_verbose_printk
<4>snd_atiixp_modem: Unknown symbol snd_verbose_printk
<4>snd_atiixp_modem: disagrees about version of symbol snd_pcm_lib_malloc_pages
<4>snd_atiixp_modem: Unknown symbol snd_pcm_lib_malloc_pages
<4>snd_atiixp_modem: disagrees about version of symbol snd_pcm_lib_ioctl
<4>snd_atiixp_modem: Unknown symbol snd_pcm_lib_ioctl
<4>snd_atiixp_modem: disagrees about version of symbol snd_pcm_lib_free_pages
<4>snd_atiixp_modem: Unknown symbol snd_pcm_lib_free_pages
<4>snd_atiixp_modem: disagrees about version of symbol snd_pcm_set_ops
<4>snd_atiixp_modem: Unknown symbol snd_pcm_set_ops
<4>snd_atiixp_modem: disagrees about version of symbol snd_pcm_hw_constraint_list
<4>snd_atiixp_modem: Unknown symbol snd_pcm_hw_constraint_list
<4>snd_atiixp_modem: disagrees about version of symbol snd_pcm_suspend_all
<4>snd_atiixp_modem: Unknown symbol snd_pcm_suspend_all
<4>snd_atiixp_modem: disagrees about version of symbol snd_pcm_hw_constraint_integer
<4>snd_atiixp_modem: Unknown symbol snd_pcm_hw_constraint_integer
<4>snd_atiixp_modem: disagrees about version of symbol snd_pcm_period_elapsed
<4>snd_atiixp_modem: Unknown symbol snd_pcm_period_elapsed

The snd_atiixp_modem module is not blacklisted at the moment, but lsmod doesn’t show it.

The line

<6>ATI IXP AC97 controller 0000:00:14.5: PCI INT B -> GSI 17 (level, low) ->
IRQ 1

appears twice in boot.msg, I don’t know if it’s normal.

Following the step on the troubleshooting page I tried to search for codec ALC202 on the ALSA homepage, but didn’t find anything.
Another tip is to play around with the model option, but I couldn’t do that because snd_atiixp doesn’t have such an option.

I hope this time I gave some valuable information.

I don’t know if this is your only problem, but it is enough to block your sound. … please keep ‘alsa’ and keep ‘alsa-driver-kmp-default’ but remove ‘alsa-driver-unstable-kmp-default’. That should not be installed at the same time as alsa-driver-kmp-default.

Then reboot and test your sound.

When testing your sound, please use the sound test (copy and paste it into a konsole or terminal): speaker-test -c2 -l5 -twavyou should hear a lady’s voice saying ‘FRONT LEFT’,‘FRONT RIGHT’ five times. Ensure you check your mixer, and move BOTH master and PCM volume controls up to 95% when testing for basic sound functionality. Once you have basic sound functionality, you can move them down to a much lower level to remove distortion.

I thought of adding some error messages that mplayer and skype give, perhaps these can also orient us:

[AO OSS] audio_setup: Can’t open audio device /dev/dsp: Device or resource busy
[AO_ALSA] alsa-lib: pcm_hw.c:1321:(snd_pcm_hw_open) open /dev/snd/pcmC0D0p failed: Device or resource busy
[AO_ALSA] alsa-lib: pcm_dmix.c:1008:(snd_pcm_dmix_open) unable to open slave
[AO_ALSA] Playback open error: Device or resource busy
[AO ESD] esd_open_sound failed: Connection timed out
AO: [pulse] 22050Hz 2ch s16le (2 bytes per sample

and

ALSA lib pcm.c:2202:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.hdmi

RtApiAlsa: callback thread error (RtApiAlsa: audio write error for device (ATI IXP (hw:IXP,0)): No room on device.) … closing stream.

Please remove the alsa-driver-unstable-kmp-default rpm that I noted above.

OK, … After re-booting, if your sound still does not work, try a restart of alsa with:
su -c ‘rcalsasound restart’ and try the speaker test I recommended.

I also note the “external amp” is OFF in your mixer. What happens if you switch that ON and test your sound? If it does not help, put it back to how it was before (OFF).

I don’t think this module is the problem, I’ve just installed it. I thought that it might be a mistake to install it, but Yast offered it together with the other kmp package.

I removed it, rebooted to find

<4>snd_ac97_codec: disagrees about version of symbol ac97_bus_type
<4>snd_ac97_codec: Unknown symbol ac97_bus_type
<4>snd_atiixp: Unknown symbol snd_ac97_pcm_close
<4>snd_atiixp: Unknown symbol snd_ac97_resume
<4>snd_atiixp: Unknown symbol snd_ac97_pcm_open
<4>snd_atiixp: Unknown symbol snd_ac97_update_bits
<4>snd_atiixp: Unknown symbol snd_ac97_mixer
<4>snd_atiixp: Unknown symbol snd_ac97_bus
<4>snd_atiixp: Unknown symbol snd_ac97_suspend
<4>snd_atiixp: Unknown symbol snd_ac97_get_short_name
<4>snd_atiixp: Unknown symbol snd_ac97_pcm_assign
<4>snd_atiixp: Unknown symbol snd_ac97_tune_hardware

Then I tried

> rcalsasound restart
Shutting down sound driver done
Starting sound driver: atiixpWARNING: Error inserting snd_ac97_codec (/lib/modules/2.6.27.7-9-default/kernel/sound/pci/ac97/snd-ac97-codec.ko): Unknown symbol in module, or unknown parameter (see dmesg)
FATAL: Error inserting snd_atiixp (/lib/modules/2.6.27.7-9-default/kernel/sound/pci/snd-atiixp.ko): Unknown symbol in module, or unknown parameter (see dmesg)

OK… I will reinstall all the alsa packages, I hope it will be enough… otherwise I will have to reinstall the whole system, I guess…

Huhh, now everything “works” just like before, the problems are the same.
I find interesting that the speaker-test worked after login, but when I tried to play a video file with mplayer it said

[AO_ALSA] Trying to reset soundcard.
[AO_ALSA] Write error: Broken pipe

After “rcalsasound restart” mplayer works again…

Now I have (snd_atiixp_modem is blacklisted):

> cat /proc/asound/modules
0 snd_atiixp
> cat /proc/asound/cards
0 [IXP ]: ATIIXP - ATI IXP
ATI IXP rev 0 with ALC202 at 0xe8003000, irq 17

> rpm -qa | grep alsa
alsa-plugins-jack-1.0.19.git20090123-1.4
alsa-driver-kmp-default-1.0.19.20090201_2.6.27.7_9.1-1.1
alsa-1.0.19.git20090130-1.1
alsa-plugins-1.0.19.git20090123-1.4
alsa-utils-1.0.19.git20090130-2.1
alsa-oss-1.0.17.git20080715-2.16
tsalsa-20080914-0.pm.1
alsa-firmware-1.0.19.git20090120-1.1
alsa-tools-1.0.19.git20090120-1.7
alsa-plugins-pulse-1.0.19.git20090123-1.4

What should I try next?

Set up your repositories for software package management with ONLY oss, non-oss, update and packman. No others. Just those 4. There is guidance here for how to setup those 4: Repositories/11.1 - openSUSE-Community

Again, only those 4: oss, non-oss, update and packman. In particular remove videolan and replace any apps (except libdvdcss2) with packman versions.

With those 4 setup, install packman packaged version of smplayer. Then using smplayer as a front end to mplayer, try changing your output audio module to alsa (from auto) and your output video module from auto to “xv” (if you do not have desktop effects enabled) and to “x11” if you have desktop effects enabled.

You could also try playing with your sound with desktop effects disabled (and “x11” selected as output video module).

I’m not convinced black listing is necessary. When happens if you do not black list?

You could also take a read of the HDA-Audio.txt file (in the 1.0.19 alsa documentation) to see if there are any relevant hints there reference your symptoms.

In that vain, can you reboot your PC, and immediately after the reboot, with your PC connected to the internet, run: dmesg > dmesg.txt && curl -F file=@dmesg.txt nopaste.com/a

and post here the URL provided (just the URL)

I kept only these for repos. After that I searched in Yast for “videolan”, found 3 things, none of them was installed.
What do you mean by replacing any apps? Should I replace all applications?

OK, but I’ve been able to use mplayer so far if I really wanted. I had to “rcalsasound restart” and use -vo x11.
But ok, I’ve installed smplayer. The working settings are -vo=x11 and for audio the “alsa(0.0 - ATI IXP)” from the menu. If I choose simply “alsa”, mplayer “crashes” with
[AO_ALSA] Write error: Broken pipe
[AO_ALSA] Trying to reset soundcard.

Nothing special… lsmod doesn’t show it loaded.

I haven’t found this file neither on the harddisk nor on the web by doing a Google search. I found the file Linux Kernel Documentation :: sound : alsa : ALSA-Configuration.txt instead.

Here it is:
dmesg.txt - nopaste.com (beta)

I note this:

ATI IXP MC97 controller 0000:00:14.6: PCI INT B -> GSI 17 (level, low) -> IRQ 17
ATI IXP AC97 controller 0000:00:14.5: PCI INT B -> GSI 17 (level, low) -> IRQ 17

which does not appear out of the ordinary.

I am wondering what else (if anything) uses IRQ 17. From your dmesg file it appears IRQ 17 is not dedicated to your audio.

Also, it was only after you ran “rcalsasound restart” that you were advised to check the contents of dmesg. So could you restart your PC, then run with root permissions “rcalsasound restart”, and then run the “dmesg/curl” command :
dmesg > dmesg.txt && curl -F file=@dmesg.txt nopaste.com/a to post your dmesg contents to a web site, and post the URL here … presumeably that will give us the information in the dmesg that was hinted at earlier by running the “rcalsasound restart”.

Also, reference IRQ 17, what is the output of:cat /proc/interrupts(I hope I have that syntax correct … I’m not at a linux PC and I am going by memory). Could it be possible this problem is interrupt related?

Reference the HDA-Audio.txt file, … it comes with 1.0.19 of alsa (I obtained it by downloading the tarball). I uploaded it here for you to examine: general pastebin - HDA-Audio.txt - post number 1325394
That URL will expire in one year.

Users don’t always get assigned to the group “audio”. So that is another thing to check. There may be a difference in running the sound server in half-duplex as opposed to full duplex as well.

Yes, I also noted this… what is MC97? Could it be a problem?

Here is the dmesg file after reboot and “rcalsasound restart”

dmesg.txt - nopaste.com (beta)

and here are the interrupts (also after rcalsasound restart):

> cat /proc/interrupts
CPU0
0: 97 IO-APIC-edge timer
1: 229 IO-APIC-edge i8042
4: 2 IO-APIC-edge
6: 5 IO-APIC-edge floppy
7: 0 IO-APIC-edge parport0
8: 0 IO-APIC-edge rtc0
12: 8499 IO-APIC-edge i8042
14: 10467 IO-APIC-edge pata_atiixp
15: 2807 IO-APIC-edge pata_atiixp
16: 25729 IO-APIC-fasteoi uhci_hcd:usb3, ohci1394, yenta, radeon@pci:0000:01:05.0
17: 70 IO-APIC-fasteoi uhci_hcd:usb4, yenta, ATI IXP
18: 127 IO-APIC-fasteoi ehci_hcd:usb5, rtl8180
19: 5298 IO-APIC-fasteoi ohci_hcd:usb1, ohci_hcd:usb2, eth0
21: 510 IO-APIC-fasteoi acpi
NMI: 0 Non-maskable interrupts
LOC: 50314 Local timer interrupts
RES: 0 Rescheduling interrupts
CAL: 0 function call interrupts
TLB: 0 TLB shootdowns
TRM: 0 Thermal event interrupts
SPU: 0 Spurious interrupts
ERR: 0
MIS: 0

I’ve always suspected that this may be az interrupt problem… if it actually is, I hope we’ll figure it out.

Thank you for the HD-Audio.txt file. It starts with the sentence
“HD-audio is the new standard on-board audio component on modern PCs after AC97.”.
But then does it concern me? I mean, I see ac97 everywhere and not hd-something. (Sorry if it’s a dumb question.)

I noticed some very weird thing.

I tried to play the test melody in Yast>sound card>other> volume control, and the sound suddenly stops when I move the mouse ! I checked what dmesg had to say about this:

ATI IXP AC97 controller 0000:00:14.5: PCI INT B disabled
ATI IXP AC97 controller 0000:00:14.5: PCI INT B -> GSI 17 (level, low) -> IRQ 17

After “rcalsasound restart” I can play the test sound again.
Isn’t this a sign of interrupt problems?

MC97? I’ve never paid much attention to it. I believe its just another way of saying AC97. ie Modem Codec '97 or something like that.

so this is your interrupt, sharing APIC, a USB device, yenta, and your sound device, where I believe yenta is your PC’s card bus controller. Yenta - Wikipedia, the free encyclopedia Do you have anything plugged in there nominally?

Interrupts can be difficult to sort. Sometimes the BIOS provides options for sorting interrupts. In the case of desktop PCs, sometimes one can change the location of PCI cards to change interrupts.

I note this in the HD-Audio.txt file:

Interrupt Handling
~~~~~~~~~~~~~~~~~~
In rare but some cases, the interrupt isn't properly handled as
default.  You would notice this by the DMA transfer error reported by
ALSA PCM core, for example.  Using MSI might help in such a case.
Pass `enable_msi=1` option for enabling MSI.

I do not know if that will make any difference, but you could try changing your /etc/modprobe.d/sound file to:

options snd slots=snd-atiixp
options snd-atiixp enable_msi=1
# hB6S.2vvYHXqtdU0:IXP150 AC'97 Audio Controller
alias snd-card-0 snd-atiixp

restart your PC and test your sound. That may break your sound. It may make no difference (in which case, simply remove it).

If you wish to learn more about this, you could read these sites:

I wasn’t assigned to audio, indeed (only video). I changed this, but this didn’t seem to change too much. (I had had sound before, at least after “rcalsasound restart”.)

Where can I set the sound server things?

It may be a silly question but how do I find it out?

After making this change in /etc/modprobe.d/sound “rcalsasound restart” says:
Starting sound driver: atiixpFATAL: Error inserting snd_atiixp (/lib/modules/2.6.27.7-9-default/updates/alsa/pci/snd-atiixp.ko): Unknown symbol in module, or unknown parameter (see dmesg)

dmesg
snd_atiixp: Unknown parameter `enable_msi’

This is understandable, regarding that the ALSA-Configuration.txt file doesn’t list this option for snd-atiixp:

"
Module snd-atiixp
225 -----------------
226
227 Module for ATI IXP 150/200/250/400 AC97 controllers.
228
229 ac97_clock - AC’97 clock (default = 48000)

230 ac97_quirk - AC’97 workaround for strange hardware
231 See “AC97 Quirk Option” section below.

232 ac97_codec - Workaround to specify which AC’97 codec
233 instead of probing. If this works for you
234 file a bug with your lspci -vn output.
235 -2 – Force probing.
236 -1 – Default behavior.
237 0-2 – Use the specified codec.

238 spdif_aclink - S/PDIF transfer over AC-link (default = 1)
239
240 This module supports one card and autoprobe.
241
242 ATI IXP has two different methods to control SPDIF output. One is
243 over AC-link and another is over the “direct” SPDIF output. The
244 implementation depends on the motherboard, and you’ll need to
245 choose the correct one via spdif_aclink module option.
246
247 The power-management is supported.
"

Should I disable now yenta somehow?

OK, so enable_msi=1 doesn’t work.

Did you try disabling desktop effects like I suggested you try many posts back?

Do you mean in System settings>Desktop? I switched it off, then when I pressed “Apply”, the machine got completely frozen. But after reboot the desktop effects are switched off. Needless to say, nothing is different with the sound.

Anyway, I had these problems already with suse10, where there were no fancy dekstop effects (if I remember well).

It’s really misterious… This problem persists after upgrading to suse11.1, to the latest version of alsa etc. I start thinking that it might be a hardwer problem with my sound card…