From: Luis R. Rodriguez Date: Fri, 26 May 2017 21:12:25 +0000 (-0700) Subject: module: use list_for_each_entry_rcu() on find_module_all() X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=93437353daeff31bd5b11810daa4d2d509d1a64e;p=GitHub%2Fmoto-9609%2Fandroid_kernel_motorola_exynos9610.git module: use list_for_each_entry_rcu() on find_module_all() The module list has been using RCU in a lot of other calls for a while now, we just overlooked changing this one over to use RCU. Signed-off-by: Luis R. Rodriguez Signed-off-by: Jessica Yu --- diff --git a/kernel/module.c b/kernel/module.c index f546d574f436..afc6ede7bcdf 100644 --- a/kernel/module.c +++ b/kernel/module.c @@ -603,7 +603,7 @@ static struct module *find_module_all(const char *name, size_t len, module_assert_mutex_or_preempt(); - list_for_each_entry(mod, &modules, list) { + list_for_each_entry_rcu(mod, &modules, list) { if (!even_unformed && mod->state == MODULE_STATE_UNFORMED) continue; if (strlen(mod->name) == len && !memcmp(mod->name, name, len))