Re: [PATCH] Remove module reference counting.

From: Rahul Karnik (rahul@genebrew.com)
Date: Mon Jul 28 2003 - 06:51:22 EST


Rusty Russell wrote:

> If module removal is to be a rare and unusual event, it
> doesn't seem so sensible to go to great lengths in the code to handle
> just that case. In fact, it's easier to leave the module memory in
> place, and not have the concept of parts of the kernel text (and some
> types of kernel data) vanishing.

Rusty and others,

Module removal is *not* a rare event. One common case it is used is on
laptops during suspend. A lot of drivers do not do proper PM and so must
be unloaded before suspend and relaoaded after resume. How will this be
affected by removing module refcounting, even if we use your <deleted>
idea? If nothing else, having the ability to *reload* a module --
thereby reinitializing the device and achieving the same effect as
actually rmmod/insmod is what is needed.

I must say that it is somewhat disconcerting that I can rmmod a network
driver while it is being used by a network interface. A stupid user like
me can definitely shoot myself in the foot now.

Last but not least weren't we moving towards a more modular kernel with
early userspace loading things from initrd as needed? Removing existing
module functionality, however broken it may be, seems to me a step
backward in this regard.

Thanks,
Rahul

-- 
Rahul Karnik
rahul@genebrew.com

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Thu Jul 31 2003 - 22:00:35 EST