[PATCH v2 1/2] kthread: remove kthread_exit()
Steven Rostedt
rostedt at goodmis.org
Wed Mar 18 23:12:46 UTC 2026
On Wed, 11 Mar 2026 10:47:36 +0000
David Laight <david.laight.linux at gmail.com> wrote:
> > -#define module_put_and_kthread_exit(code) kthread_exit(code)
> > +#define module_put_and_kthread_exit(code) do_exit(code)
>
> I'm intrigued...
> How does that actually know to do the module_put()?
> (I know it does one - otherwise my driver wouldn't unload.)
It's in the !CONFIG_MODULES section. No module_put() necessary. Only the
kthread_exit (do_exit) is needed.
-- Steve
More information about the Linux-security-module-archive
mailing list