Re: Can not remove a module which has no cleanup_module()

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

 



On 12/24/06, Smith Norton <smith.norton@xxxxxxxxx> wrote:
What's the concept behind this?

the kernel has no way of knowing the lack of a cleanup function means
"there are no resources to cleanup" or "this module cannot be cleaned
up" so it's safer to err on the side of caution and not unload the
module since it may have resources in use ... especially since the
latter condition makes a lot more sense

simply write a correct module and it wont be a problem:
static void __exit cleanup_module(void)
{
}
module_exit(cleanup_module);
-mike

--
Kernelnewbies: Help each other learn about the Linux kernel.
Archive:       http://mail.nl.linux.org/kernelnewbies/
FAQ:           http://kernelnewbies.org/faq/


[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux