ALSA on 2.5.x
Jerry McBride
mcbrides9
Mon May 17 11:29:58 PDT 2004
I've been asked off list as to HOW I got ALSA in 2.5.7 up and running.
Here's a mini-howto, difinitely for the nerds amongst us... :')
First off... if you have previously installed ALSA for a 2.4.x or earlier
kernel... The mods you made to modules.conf won't work. The ALSA module
names have been changed and most, if not all, ALSA modules options are
gone or abbreviated. So rem all of those ALSA changes and get ready for
"the new way" of doing business.
Also, if you don't have a previously installed ALSA sound support, don't
worry. There's nothing for you to do, other than what I list below. No
device creation, etc..
Second, compile your 2.5.7 kernel with sound options that look similar to
those listed below. What this snip provides is ALSA support for VIA sound
chips with OSS emulation on the PCI variety of harware. Your needs will
vary, I can't cover all permutations here in this text, but I'm willing to
help you via email if you need some hand-holding.
#
# Sound
#
CONFIG_SOUND=m
#
# Open Sound System
#
# CONFIG_SOUND_PRIME is not set
#
# Advanced Linux Sound Architecture
#
CONFIG_SND=m
CONFIG_SND_SEQUENCER=m
# CONFIG_SND_SEQ_DUMMY is not set
CONFIG_SND_OSSEMUL=y
CONFIG_SND_MIXER_OSS=m
CONFIG_SND_PCM_OSS=m
CONFIG_SND_SEQUENCER_OSS=m
CONFIG_SND_RTCTIMER=m
# CONFIG_SND_VERBOSE_PRINTK is not set
# CONFIG_SND_DEBUG is not set
#
# Generic devices
#
# CONFIG_SND_DUMMY is not set
# CONFIG_SND_VIRMIDI is not set
# CONFIG_SND_MTPAV is not set
# CONFIG_SND_SERIAL_U16550 is not set
CONFIG_SND_MPU401=m
#
# ISA devices
#
# CONFIG_SND_AD1816A is not set
# CONFIG_SND_AD1848 is not set
# CONFIG_SND_CS4231 is not set
# CONFIG_SND_CS4232 is not set
# CONFIG_SND_CS4236 is not set
# CONFIG_SND_ES968 is not set
# CONFIG_SND_ES1688 is not set
# CONFIG_SND_ES18XX is not set
# CONFIG_SND_GUSCLASSIC is not set
# CONFIG_SND_GUSEXTREME is not set
# CONFIG_SND_GUSMAX is not set
# CONFIG_SND_INTERWAVE is not set
# CONFIG_SND_INTERWAVE_STB is not set
# CONFIG_SND_OPTI92X_AD1848 is not set
# CONFIG_SND_OPTI92X_CS4231 is not set
# CONFIG_SND_OPTI93X is not set
# CONFIG_SND_SB8 is not set
# CONFIG_SND_SB16 is not set
# CONFIG_SND_SBAWE is not set
# CONFIG_SND_WAVEFRONT is not set
# CONFIG_SND_ALS100 is not set
# CONFIG_SND_AZT2320 is not set
# CONFIG_SND_CMI8330 is not set
# CONFIG_SND_DT0197H is not set
# CONFIG_SND_OPL3SA2 is not set
# CONFIG_SND_SGALAXY is not set
#
# PCI devices
#
# CONFIG_SND_ALI5451 is not set
# CONFIG_SND_CS46XX is not set
# CONFIG_SND_EMU10K1 is not set
# CONFIG_SND_KORG1212 is not set
# CONFIG_SND_NM256 is not set
# CONFIG_SND_RME96 is not set
# CONFIG_SND_RME9652 is not set
# CONFIG_SND_TRIDENT is not set
# CONFIG_SND_YMFPCI is not set
# CONFIG_SND_ALS4000 is not set
# CONFIG_SND_CMIPCI is not set
# CONFIG_SND_ENS1370 is not set
# CONFIG_SND_ENS1371 is not set
# CONFIG_SND_ES1938 is not set
# CONFIG_SND_ES1968 is not set
# CONFIG_SND_MAESTRO3 is not set
# CONFIG_SND_FM801 is not set
# CONFIG_SND_ICE1712 is not set
# CONFIG_SND_INTEL8X0 is not set
# CONFIG_SND_SONICVIBES is not set
CONFIG_SND_VIA686=m
# CONFIG_SND_VIA8233 is not set
The short story is... enable Sound Card Support as a module. Don't enable
any Open Sound System options. In ALSA enable OSS API emulation with
everything enabled as modules. In Generic Devices I enabled Generic
MPU-401 UART, nothing in ISA and only my desired VIA Southbridge driver
enabled as a module. That's it.
Once properly configed, compiled and rebooted... edit your
/etc/modules.conf file and add the following lines of text. Change the
snd-via686 to whatever the appropriate module name should be for your
sound card. If you get it wrong... no worries. It just won't work, nothing
blows up.
alias char-major-116 snd
alias char-major-14 soundcore
alias snd-card-0 snd-via686 # <== change the ALSA module named on this
line. alias sound-slot-0 snd-card-0
alias sound-service-0-0 snd-mixer-oss
alias sound-service-0-1 snd-seq-oss
alias sound-service-0-3 snd-pcm-oss
alias sound-service-0-12 snd-pcm-oss
The ALSA modules are at /lib/modules/2.5.7/kernel/sound. My via
driver was in /lib/modules/2.5.7/kernel/sound/pci... it was named
snd-via686.o
Once you get that figured out... save it, close the editor and test your
work... Do a : modprobe snd-via686
All the neccessay modules should load and ALSA sound support will be up
and running. Remember, the default ALSA sound volume is MUTE. Fire up a
mixer (amix) and set the voulmes accordingly and play an mp3 or
something...
Ain't it grand?
If it fails... don't worry mate. Go back and enable
CONFIG_SND_VERBOSE_PRINTK and CONFIG_SND_DEBUG in the kernel (recompile).
This will print out ALL KINDS of VERBOSE debug info that should help your
figure out what you did wrong. The other thing you could try is see what
options your ALSA module needs/accepts via the modinfo command. Perhaps
you will need to add them into /etc/modules.conf as a "options
alsa-module-name" entry.
That said... this should be enough to get ALSA support in your shiney new
2.5.x kernel. If it doesn't, drop me a line and I'll try to sort it out
for you.
NOTE: Do not modprobe your ALSA sound module BEFORE you add the aliases in
/etc/modules.conf. I did that, ONCE, out of curiosity and wound up with a
totally locked up laptop. Sitting through an fsck on a 40gig drive is...
well...not much fun. So learn from my goof and add the data to
modules.conf.... then probe the module.
Cheers.
--
*************************************************************************
***** Registered Linux User Number 185956
http://groups.google.com/groups?hl=en&safe=off&group=linux
9:29pm up 35 days, 2:46, 4 users, load average: 0.03, 0.01, 0.00
More information about the Linux-users
mailing list