]> git.baikalelectronics.ru Git - kernel.git/commit
module: set nx before marking module MODULE_STATE_COMING.
authorRusty Russell <rusty@rustcorp.com.au>
Wed, 14 May 2014 01:24:19 +0000 (10:54 +0930)
committerRusty Russell <rusty@rustcorp.com.au>
Wed, 14 May 2014 01:25:47 +0000 (10:55 +0930)
commite264905c7106758a91a8b58b1ebe9e808c3caf14
treec944679cbc1b341771eceea899f0cccdf64c4c64
parentd0f70d9ec2f682e13a02cd7cbb36deb7596989f4
module: set nx before marking module MODULE_STATE_COMING.

We currently set RO & NX on modules very late: after we move them from
MODULE_STATE_UNFORMED to MODULE_STATE_COMING, and after we call
parse_args() (which can exec code in the module).

Much better is to do it in complete_formation() and then call
the notifier.

This means that the notifiers will be called on a module which
is already RO & NX, so that may cause problems (ftrace already
changed so they're unaffected).

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
kernel/module.c