[Pkg-alsa-devel] Bug#586053: alsa-base: avoiding usb audio devices as card 0 makes no sense on machines without other audio

Daniel Kahn Gillmor dkg at fifthhorseman.net
Wed Jun 16 00:35:28 UTC 2010


Package: alsa-base
Version: 1.0.23+dfsg-1
Severity: normal

I'm writing this report from an NSLU2, which has no built-in audio (but does have USB ports).  After a recent upgrade to alsa-base 1.0.23+dfsg-1, alsamixer could not find my sound card.

This appears to be because of the following line in /etc/modprobe.d/alsa-base.conf:

----------------------
# Keep snd-usb-audio from beeing loaded as first soundcard
options snd-usb-audio index=-2
----------------------

This is problematic for a few reasons, but mainly because i use this NSLU2 as input to my stereo.  My mixer and mpd were both confused about which audio device to use, since there was no device 0.

I commented out the offending line from /etc/modprobe.d/alsa-base.conf, and then re-loaded the USB audio module and restarted mpd:

modprobe -v -r snd-usb-audio
modprobe -v snd-usb-audio
/etc/init.d/mpd restart

Then it worked fine again.

I understand in the (more common?) case with machines with built-in audio cards that you want the built-in cards to be "card 0", and USB to be "card 1" or something.

Maybe this is something that could be resolved the way that network devices and optical media are handled, with an auto-generated /etc/udev/rules.d/70-persistent-alsa.rules, managed from
/lib/udev/rules.d/60-persistent-alsa-generator.rules  (or something like that).

i see there is already /lib/udev/rules.d/60-persistent-alsa.rules, but that seems to only create symlinks in /dev/snd/by-id and /dev/snd/by-path, and it is not clear to me how i'd use such a thing 
in the mpd or alsamixer configuration (much less to have it "just work" generically, as most alsa-using tools default to "card 0").

Thanks for maintaining ALSA in debian!

	--dkg

-- Package-specific info: --- Begin additional package status --- 
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name                                          Version                                       Description
+++-=============================================-=============================================-==========================================================================================================
ii  libasound2                                    1.0.23-1                                      shared library for ALSA applications
--- End additional package status ---
--- Begin /proc/asound/version ---
Advanced Linux Sound Architecture Driver Version 1.0.21.
--- End /proc/asound/version ---
--- Begin /proc/asound/cards ---
 0 [Audio          ]: USB-Audio - USB Audio
                      USB Audio at usb-0000:00:01.0-1, full speed
--- End /proc/asound/cards ---
--- Begin /dev/snd/ listing ---
total 0
drwxr-xr-x 2 root root      60 Jun 15 20:13 by-id
drwxr-xr-x 2 root root      60 Jun 15 20:13 by-path
crw-rw---- 1 root audio 116, 6 Jun 15 20:13 controlC0
crw-rw---- 1 root audio 116, 5 Jun 15 20:13 pcmC0D0c
crw-rw---- 1 root audio 116, 4 Jun 15 20:14 pcmC0D0p
crw-rw---- 1 root audio 116, 3 Jun 15 20:13 seq
crw-rw---- 1 root audio 116, 2 Jun 15 20:13 timer
--- End /dev/snd/ listing ---

-- System Information:
Debian Release: squeeze/sid
  APT prefers testing
  APT policy: (500, 'testing'), (200, 'unstable'), (1, 'experimental')
Architecture: armel (armv5tel)

Kernel: Linux 2.6.32-5-ixp4xx
Locale: LANG=C, LC_CTYPE=C (charmap=ANSI_X3.4-1968)
Shell: /bin/sh linked to /bin/dash

Versions of packages alsa-base depends on:
ii  linux-sound-base           1.0.23+dfsg-1 base package for ALSA and OSS soun
ii  lsof                       4.81.dfsg.1-1 List open files
ii  module-init-tools          3.12~pre2-3   tools for managing Linux kernel mo
ii  udev                       157-1         /dev/ and hotplug management daemo

Versions of packages alsa-base recommends:
ii  alsa-utils                    1.0.23-2   Utilities for configuring and usin

Versions of packages alsa-base suggests:
pn  alsa-oss                      <none>     (no description available)
pn  apmd                          <none>     (no description available)
pn  oss-compat                    <none>     (no description available)

Versions of packages libasound2 depends on:
ii  libc6                         2.11.1-3   Embedded GNU C Library: Shared lib
ii  libgcc1                       1:4.4.4-1  GCC support library

-- Configuration Files:
/etc/modprobe.d/alsa-base.conf changed:
install sound-slot-0 /sbin/modprobe snd-card-0
install sound-slot-1 /sbin/modprobe snd-card-1
install sound-slot-2 /sbin/modprobe snd-card-2
install sound-slot-3 /sbin/modprobe snd-card-3
install sound-slot-4 /sbin/modprobe snd-card-4
install sound-slot-5 /sbin/modprobe snd-card-5
install sound-slot-6 /sbin/modprobe snd-card-6
install sound-slot-7 /sbin/modprobe snd-card-7
install snd /sbin/modprobe --ignore-install snd && { /sbin/modprobe --quiet snd-ioctl32 ; /sbin/modprobe --quiet snd-seq ; }
install snd-rawmidi /sbin/modprobe --ignore-install snd-rawmidi && { /sbin/modprobe --quiet snd-seq-midi ; : ; }
install snd-emu10k1 /sbin/modprobe --ignore-install snd-emu10k1 && { /sbin/modprobe --quiet snd-emu10k1-synth ; : ; }
options bt87x index=-2
options cx88_alsa index=-2
options snd-atiixp-modem index=-2
options snd-intel8x0m index=-2
options snd-via82xx-modem index=-2
options snd-pcsp index=-2


-- no debconf information





More information about the Pkg-alsa-devel mailing list