Re: simple handling of module removals Re: [OKS] Module removal

From: Keith Owens (kaos@ocs.com.au)
Date: Wed Jul 03 2002 - 23:08:13 EST


On Wed, 03 Jul 2002 22:25:34 -0400,
Brian Gerst <bgerst@didntduck.org> wrote:
>Why not treat a module just like any other structure? Obtain a
>reference to it _before_ using it.

That is what try_inc_use_count() does. But the interface is messy and
difficult to audit. It relies on the caller taking some other lock
first to ensure that the module address will not change while you are
trying to call try_inc_use_count.

-
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 : Sun Jul 07 2002 - 22:00:12 EST