[ltp] Force removal of kernel module??

Leif Jonsson linux-thinkpad@www.bm-soft.com
Fri, 27 Apr 2001 11:09:39 +0200


Hi All!

First let me thank all of you for a great list! Much knowledge on TP in
one
place, great!

Second, I have two questions:

One, is there SOME way to really FORCE removal of a kernel module
without it's
modcount beeing zero?? Or is the only way to reboot? *shrug* Can I
perhaps
go to init 1 and remove it or something else?

Second, if it is not possible, Why is it so?? If I am SURE that the
module is 
unused but the modulecount isn't decreased of some reason, why can't I
be allowed
to FORCE it out as superuser? Is it some security policy or some other
unstability
policy or what?

As far as I could see the only possible way to achive this would be to
add a
systemcall which, unlike sys_delete_module, bypasses the check for
MOD_IN_USE and
directly do free_module. I understand that this would allow for possible
system 
instability/hang and/or resource waste but if I feel it's worth it...
and hey, I
must reboot anyway...

What typically happens to me is that the soundcard module (cs46xx) or
network module
(3c59x) hangs, often after apm (and yes I know I should remove it with
some 
apmscript =) and then I am sitting there with no sound and/or network
=P. And
the worst part is that I, a Linux advocate must swallow my own words by
having to
reboot the machine. =)

Thanks for the bandwidth, hope it's not ONLY noise!
And thanks in advance for any good advice!
Cheers!
-Leif

-- 
Leif Jonsson, ERA/T/KA       mailto:Leif.von.Jonsson@era-t.ericsson.se
Ericsson Radio Systems       phoneto:+46(0)84047215

----- The Linux ThinkPad mailing list -----
The linux-thinkpad mailing list home page is at:
http://www.bm-soft.com/~bm/tp_mailing.html