On Sun, Sep 12, 2010 at 04:59:14PM +0200, Denys Vlasenko wrote: > On Thu, Sep 9, 2010 at 10:14 PM, Dan Fandrich <[email protected]> wrote: > > Previously, rmmod would display an error message when the module > > WAS removed, > > Can't reproduce this. Can you give exact steps how to make it happen?
I don't have to do anything special to make rmmod say nothing when it fails to remove a module. But it looks like modules.dep et. al. must not exist in order for rmmod to complain when it DOES remove a module (i.e. /lib/modules/`uname -r`/ must exist but be empty). On a defconfig busybox on x86: $ sudo ./busybox rmmod NON_LOADED_MODULE # Should give error, but doesn't $ sudo ./busybox insmod qnx4.ko $ sudo ./busybox rmmod qnx4 # Gives error when it shouldn't rmmod: module 'qnx4' not found $ sudo ./busybox rmmod qnx4 # This time should give error but doesn't $ > > and would display no error when the module WAS NOT removed. > > This seems to be a feature. MODPROBE_SMALL is making some > simplifying assumptions, one of them is that "rmmod == modprobe -r". > And "modprobe -r NON_LOADED_MODULE" does not error out. modprobe from module-init-tools does show an error message if NON_LOADED_MODULE is also not found in modules.dep (this is assuming modules.dep exists or it gives another error): $ sudo modprobe -r xyzzy FATAL: Module xyzzy not found. $ It does not show anything if the modules is found in modules.dep, even if it's not loaded: $ sudo modprobe -r qnx4 $ sudo modprobe -r qnx4 $ >>> Dan _______________________________________________ busybox mailing list [email protected] http://lists.busybox.net/mailman/listinfo/busybox
