Re: SB AWE32 PnP module to use?

Kerin Millar <[email protected]>
Newsgroups gmane.linux.gentoo.newbies
Message-ID <[email protected]>
Adam Theo wrote:
> Hi all.
> 
> I'm trying to install ALSA sound support into my new Gentoo desktop. I 
> initially ran into trouble emerging alsa-driver, but that was fixed 
> after I went back and made sure I had supported the Sound Blaster 
> modules out of the OSS category (But aren't OSS and ALSA two different 
> sound systems? hm...), then it emerged fine. But now that I have

Yes, they are two separate sound systems. All that's required to use 
ALSA is to have Sound Support compiled in to your kernel (i.e. the first 
option under that category in the kernel configuration menu). You don't 
have to select support for any specific sound card. However, if you wish 
to be able to switch between OSS and ALSA, you may select a specific 
model of sound card in the kernel config menu and compile as a module. 
For example, I have practically the same card as you (AWE 64) so I 
selected Sound Support (soundcore.o) and Sound Blaster support (sb.o) as 
modules. As long as soundcore.o is available, ALSA will start. But I can 
stop ALSA live with /etc/init.d/alsa stop and modprobe sb if I want to 
switch on OSS drivers. By the same token, I could have not chosen to 
compile in Sound Blaster support and ALSA would still have worked 
perfectly. I just wouldn't be able to switch back to the *real* OSS 
without a recompile.

> followed the directions in the Gentoo Desktop config file, I am running 
> into this error when ALSA is started up at boot:
> 
> /lib/modules/2.4.19-gentoo-r7/kernel/sound/isa/sb/snd-sbawe.o: 
> init_module: No such device
> Hint: insmod errors can be caused by incorrect module parameters, 
> including invalid IO or IRQ parameters.
> You may find more information in syslog or the output from dmesg
> /lib/modules/2.4.19-gentoo-r7/kernel/sound/isa/sb/snd-sbawe.o: insmod 
> /lib/modules/2.4.19-gentoo-r7/kernel/sound/isa/sb/snd-sbawe.o failed
> /lib/modules/2.4.19-gentoo-r7/kernel/sound/isa/sb/snd-sbawe.o: insmod 
> snd-sbawe failed

Hmm. Alas, I'm not on my Gentoo box at the moment, but I believe the 
kernel should be looking for the modules in 
/lib/modules/2.4.19-gentoo-r7/kernel/asound (asound being ALSA sound), 
so something seems very wrong here. Also have you tried looking at your 
system log as recommmended? Have a look under /var/log/everything and 
look at some of the files in there.


> I have a "Sound Blaster AWE32 PnP" card.
> 
> I have edited the /etc/modules.d/alsa file as so:
> 
> ## ALSA portion
> ## alias snd-card-0 snd-interwave
> ## alias snd-card-1 snd-ens1371
> alias snd-card-0 snd-sbawe
> ## OSS/Free portion
> ## alias sound-slot-0 snd-card-0
> ## alias sound-slot-1 snd-card-1
> 
> I have also tried the modules "snd-sb16" and "snd-card-sb16" (shots in 
> the dark from Google results). All the same error. I searched the Gentoo 
> forums here, but no previous threads.

Yup, you should be using the snd-sbawe module (which is similar to sb16, 
but will give you AWE synth support too). Make sure you've got something 
like (I'm not sure why you have to specify this many entries, but I can 
assure you things are less problematic if you do):

alias snd-card-0 snd-sbawe
alias snd-card-1 snd-sbawe
alias snd-card-2 snd-sbawe
alias snd-card-3 snd-sbawe
alias snd-card-4 snd-sbawe
alias snd-card-5 snd-sbawe
alias snd-card-6 snd-sbawe
alias snd-card-7 snd-sbawe

and do the same sort of thing for the OSS/Free portion (for backward 
compatibility):

alias sound-slot-0 snd-card-0
alias sound-slot-1 snd-card-1
# ... repeat this up to 7 too ...

> I have also run the "update-modules" command, and the "rc-update" 
> command to have ALSA start on boot.

If you're having problems with ALSA, then perhaps you should use 
rc-update to remove it from a runlevel. That way you can test it after 
you've booted, when you're ready with /etc/init.d/alsasound start (and, 
indeed, stop).

> Many Google searches later, I still have no idea what sound module to 
> use for this "Sound Blaster AWE32 PnP" card. Any ideas?

snd-sbawe, as mentioned above. I believe you could have ascertained that 
by doing: zmore /usr/share/doc/alsa/INSTALL.gz (where the /alsa/ part 
probably has the version number included).

You probably know this but ... remember to check your /etc for updated 
configuration files that may need to be applied (see my reply to John 
Batistic re: LS120 problems for some more info on that). In particular, 
make sure your devfsd is up-to-date (emerge rsync && emerge devfsd), and 
make sure there are no newer devfsd.conf files that need to be copied 
over your old one. This may be *critical*!

If you still have no joy, I would recommend recompiling your kernel and 
ALSA again - cleanly. Do an emerge rsync first to make sure everything 
you use is up-to-date. Here are my recommended steps:

1) emerge -C alsa-driver (this won't delete your config in /etc and it 
won't get re-written when you emerge it again)
2) cd /lib/modules
3) mv 2.4.19 2.4.19.orig
4) cd /usr/src/linux
5) make mrproper (warning: the kernel will "forget" the settings you las 
t used so recommend storing the configuration to a file before doing 
this unless you want to enter all the settings again)
6) make menuconfig (load in your configuration, or set everything again. 
Just choose Sound Support only, unless you want OSS capability too. I 
compile Sound Support as a module (static should be fine too) but 
*don't* compile an OSS module statically otherwise ALSA will surely 
choke!!!)
7) make dep && make clean bzImage modules modules_install (now your new 
clean module tree will be in /lib/modules/2.4.19 but you backed up your 
old ones in step 3)
8) mount /boot
9) cp /boot/bzImage /boot/bzImage.orig && cp arch/i386/boot/bzImage /boot
10) umount boot
11) Reboot your PC
12) emerge alsa-driver (again)
13) If you set-up your config before, then it shouldn't need changing 
now but check it out anyway and do "update-modules". Now reboot. And 
don't forget to check that a newer alsa template file was merged in 
(find /etc -iname "._cfg*") ! If so, then copy it over your old alsa 
file and add the aliases as specified earlier on.
14) If everything is in order, you shouldn't get that error anymore - 
although you will probably see an error to do with "alsactl". This can 
be solved by:
15) emerge alsa-utils

If things seem to be in order, then you should be able to proceed and 
lsmod should show a healthy selection of modules belonging to ALSA. Have 
a look at http://www.gentoo.org/doc/desktop.html in order to test your 
card. And make sure you have alsa in your make.conf USE flags. If you 
compiled things like arts (the sound server in KDE) and SDL wihout that 
flag then you'll have to compile them again. Existing OSS compatible 
stuff should work just fine.

Hopefully, you should be OK. I have found that doing "make mrproper" and 
making sure the kernel cannot see your old modules (as per step 3) is 
beneficial when re-compiling the kernel. Don't forget that you can go 
back to your old kernel and module set by undoing the renaming to *.orig 
  steps you performed.

Ah yes, and make sure "Set version information on all module symbols" is 
set to Yes in the kernel config (which is beneficial when compiling 
kernel modules which weren't supplied as part of the kernel sources - as 
you are).

Good luck ...

--kerframil

PS: I found that ALSA can be cagey about compiling if you're using any 
funky kernel patches. I have had had 100% success with the 
vanilla-sources. I haven't tried with gentoo-sources. But I had problems 
when using vanilla kernel patched with some of the more popular kernel 
patches out there. Worth knowing.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.