On Sun, Jul 02, 2006 at 09:39:45AM -0700, David Miller wrote:
> 
> So the templates are still using pure module references not object
> references?  They won't have the same kind of refcounting issues
> the algorithms will have now?

Unlike algorithms, templates are not directly used by algorithms or
other templates.  More importantly, they are never removed asynchronously
like algorithm instances (the latter can be removed when the algorithms
they depend on are being removed).  Therefore, the only time they can be
removed is when their module is being removed.

That's why it is OK to rely on only the module reference count.

The basic principle in the module reference handling is to allow the
replacement of modules even if they're in use.  This is achieved by:

1) Newly registered templates/algorithms always go in front of the list
   and can eclipse older copies.
2) New module reference counts can be inhibited by rmmod -w.

So if you wanted to replace your current md5 module by a new one you'd
do

modprobe md5-new

At this point all new users will latch onto it.

rmmod -w md5

This will complete once all current users relesae their md5 tfm's.

Cheers,
-- 
Visit Openswan at http://www.openswan.org/
Email: Herbert Xu ~{PmV>HI~} <[EMAIL PROTECTED]>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
-
To unsubscribe from this list: send the line "unsubscribe linux-crypto" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to