Re: alpha fp-emu vs module refcounting

Christoph Hellwig
2004-05-07T14:36:23Z

On Fri, May 07, 2004 at 06:32:08PM +0400, Ivan Kokshaysky wrote:
> - MOD_INC_USE_COUNT;
> + BUG_ON(!try_module_get(THIS_MODULE));

This is broken. If you know you already have a reference somewhere -
and I can't find how that would work - you'd have to use __module_get,
but if it's not you can get a failure from try_module_get legally and
you should do the try_module_get outside the module, before it's code
is exectuted.