--- In [email protected], "Santosh Vernekar" <[EMAIL PROTECTED]> wrote: > > You have already got the correct response about using the panic() api. > > But only a thing about what you had written in your previous solution: > > "for(;;) schedule();" > > This will infinitely schedule out your module process until it gets > scheduled again!! > This is like a sleeping while loop. Thats the reason you cannot remove the > module as > it still holds the reference and won't be cleaned up. > If you hit an ASSERT situation, you need to print debug/backtrace > information > and either unload i.e module_exit or allow it to panic after you have all > the debug info.
Thanks for the quick reply :-) Regarding module_exit(), AFAIK it just specifies the function which gets called when the module is removed. But how can the module remove itself, or at least indicate that it wants to be removed? Doesn't module removal only happen as a result of the user doing an rmmod on the command line, or a system shut down? John
