Kernel wipes ALSA typo.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



My previous message said compiler install where it should have said KERNEL
install loses the ALSA drivers.
This is a rewrite and covers some new ground too.
This includes a suggested fix to the problem.

I have spent 10 months without sound ( VIA8237 ) on my machine because ALSA
would not work.  I tried ALSA 1.0.9, 1.0.16.  and now 1.0.17.
I have discovered while working on another machine that compiling and
installing a new version of your KERNEL will wipe out your ALSA driver
modules.
That is not something that would be obvious nor expected.
The INSTALL documentation should definitely warn and inform.

I do not know if it works now on my VIA8237 because the 1.0.17 fixed
something important, or simply because kernel module installs were wiping
out the ALSA drivers before.
I saw in the changlog that the via82xx driver fixed something, but I also
think that I never had
the older version ALSA installed long enough to try it.  I was fixing other
kernel problems at the same time..
In this latest case I had to add a new network driver to the kernel because
the old card died, and ALSA was working on that machine before the network
problem.

The following is the kernel makefile lines that does the deed.
<< FROM KERNEL MAKEFILE >>
.PHONY: modules_install
modules_install: _modinst_ $(patsubst %, _modinst_%, $(SUBDIRS))
_modinst_post

.PHONY: _modinst_
_modinst_:
 @rm -rf $(MODLIB)/kernel                 <<<<<< Removes ALSA
 @rm -f $(MODLIB)/build
 @mkdir -p $(MODLIB)/kernel
 @ln -s $(TOPDIR) $(MODLIB)/build

<< END KERNEL MAKEFILE >>

I change the extraversion of my kernel for the custom install so that it has
a separate modules directory, keeping it independent of the default kernel
binary, which is kept as backup.
I also configure the kernel with things like karch=Athlon, and do not like
to mix those modules with old modules.
I keep the default kernel as backup during testing of the new kernel, and
trying to delete the default kernel modules afterwards, when they are mixed
in with new ones, would be inviting disaster.
The interaction of the extraversion with the ALSA modules is not obvious,
nor documented.

The following is my suggested text to be included in INSTALL:

 << START INSTALL TEXT >>

Compile and install ALSA drivers after customizing your kernel.  The driver
modules will be installed to
"/lib/modules/2.4.31/kernel/sound", where 2.4.31 will be your kenel version
as detected by the ALSA configure.
OSS and older ALSA installed the driver modules to
"/lib/modules/2.4.31/kernel/drivers/sound.
A new ALSA will not overwrite the modules from an old ALSA.  You do not want
two different versions of any driver module
installed as modprobe could easily get the old version.

Install of kernel modules will wipe out your ALSA driver modules, as it
cleans the entire kernel modules directory of everything.
If you change a kernel config, or add a module, and reinstall your kernel
modules, you will have to reinstall ALSA again afterwards!
If you update kernels, or change the extraversion of your kernel, then you
will have to configure, compile, and install ALSA afterwards.

Save a copy of all ALSA configure files that you create or modify, in case
you have to reinstall ALSA.
The ALSA install likes to reinstall all files and may wipe out config file
changes, and this behavior can vary from version to version.
If you have to install a new kernel module someday, it is likely that
suddenly ALSA does not work.
Saving all ALSA config will save you from having to recreate all your ALSA
setups too, when you are already fighting other problems.
I suggest an easy to remember, easy to find, directory for such things, such
as /root/configs.

Another tactic is to save a copy of the ALSA drivers from
"/lib/modules/2.4.31/kernel/sound" to someplace safe
 (outside "/lib/modules":),
so it can be restored after kernel installs.
example>> mkdir /root/modules_backup
example>> mkdir /root/modues_backup/2.4.31
example>> cp -a   /lib/modules/2.4.31/kernel/sound
/root/modules_backup/2.4.31/sound

Kernel install only wipes out the kernel modules directory, so a copy of the
saved modules back into "/lib/modules/2.4.31/kernel" is
all that is needed to restore the ALSA drivers.
example>> cp -a   /root/modules_backup/2.4.31/sound
/lib/modules/2.4.31/kernel/sound

Another place to keep backup modules could be:
"/lib/modules_backup/...
but I do not like to put such things into directory space that is package
install territory, as those directories are handled by package-install and
package-remove scripts from the distributor, and it can be hard to find them
later.

<< END INSTALL TEXT >>

I think these few paragraphs are not too much, and can save some people
considerable wasted time and aggravation.

Wesley D. Johnson,   Linux user since 1994



.






--- Get FREE High Speed Internet from USFamily.Net! -- http://www.usfamily.net/mkt-freepromo.html ---


-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Alsa-user mailing list
Alsa-user@xxxxxxxxxxxxxxxxxxxxx
https://lists.sourceforge.net/lists/listinfo/alsa-user

[Index of Archives]     [ALSA Devel]     [Linux Audio Users]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]

  Powered by Linux