summaryrefslogtreecommitdiffstats
path: root/kernel/module.c
diff options
context:
space:
mode:
authorLinus Walleij <linus.walleij@linaro.org>2020-01-17 08:59:29 +0100
committerLinus Walleij <linus.walleij@linaro.org>2020-01-17 08:59:29 +0100
commit6a77de2596a8d02cbfe9cebe448d8575e4354c9a (patch)
tree13e7621c147ef1415195213089ce3c2c94590bde /kernel/module.c
parent59c324683400b41caa6d85b091e812ee3d5415c3 (diff)
parentb3a987b0264d3ddbb24293ebff10eddfc472f653 (diff)
downloadlinux-6a77de2596a8d02cbfe9cebe448d8575e4354c9a.tar.bz2
Merge tag 'v5.5-rc6' into devel
Linux 5.5-rc6
Diffstat (limited to 'kernel/module.c')
-rw-r--r--kernel/module.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/kernel/module.c b/kernel/module.c
index 3a486f826224..b56f3224b161 100644
--- a/kernel/module.c
+++ b/kernel/module.c
@@ -3730,6 +3730,7 @@ static int complete_formation(struct module *mod, struct load_info *info)
module_enable_ro(mod, false);
module_enable_nx(mod);
+ module_enable_x(mod);
/* Mark state as coming so strong_try_module_get() ignores us,
* but kallsyms etc. can see us. */
@@ -3752,11 +3753,6 @@ static int prepare_coming_module(struct module *mod)
if (err)
return err;
- /* Make module executable after ftrace is enabled */
- mutex_lock(&module_mutex);
- module_enable_x(mod);
- mutex_unlock(&module_mutex);
-
blocking_notifier_call_chain(&module_notify_list,
MODULE_STATE_COMING, mod);
return 0;