Messages in this thread | | | From | Keith Owens <> | Subject | Re: Registering for notifier chains in modules (was Linux 2.4.21-rc3 - ipmi unresolved) | Date | Tue, 27 May 2003 15:30:43 +1000 |
| |
On Mon, 26 May 2003 23:45:39 -0500, Corey Minyard <minyard@acm.org> wrote: >Keith Owens wrote: >>>Why can't you have a module id in the notifier chain, and use a boolean >>>to tell if it is set, or something similar to that? That way you could >>>mix them, if the bool is set then do the try_in_module_count thing, if >>>not then just call the function. It does add some components to the >>>register structure, but that shouldn't hurt anything besides taking a >>>little more memory. >> >>It is a change of API in a 2.4 kernel. Not a good idea. >> >Does adding a field to a structure (where the user does not have to do >anything with the >field) change the API? That would be the only API change here.
The user does have to do something. Every piece of code that calls notify_register has to set the new field to __THIS_MODULE. WIthout that field being set, you are no better off, the race still exists.
- 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/
| |