> kernel needs a module, calls kmod
> kmod does modprobe -k module_name
> crond kicks in with rmmod -a (see Documentation/kmod.txt)
> *** With your patch, unused modules are removed ***
> kernel uses module that it thought was loaded but has been removed, splat!
Yes, I see the race condition now. However, I still feel my patch is
correct (in theory) and what is also needed with it, is a some kind of user
space lock (a lock file, for example).
>find out why you are loading modules marked as autoclean but not using
>them.
Ok, this is as good solution as my patch, in practise. In theory, though, I
find it strange that modules marked "(autoclean)" are not autocleaned if
they happen to be also "(unused)" -- for whatever reason.
I had this situation a while ago, but I don't know/remember why. Right now
I cannot think about any legitimate reason for unused modules.
-- | Tuukka Toivonen <tuukkat@ee.oulu.fi> [PGP public key | Homepage: http://www.ee.oulu.fi/~tuukkat/ available] | Try also finger -l tuukkat@ee.oulu.fi | Studying information engineering at the University of Oulu +-----------------------------------------------------------
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/