projects
/
GitHub
/
moto-9609
/
android_kernel_motorola_exynos9610.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
6330d55
)
pstore: Avoid race in module unloading
author
Kees Cook
<keescook@chromium.org>
Sat, 4 Mar 2017 01:45:38 +0000
(17:45 -0800)
committer
Kees Cook
<keescook@chromium.org>
Tue, 7 Mar 2017 16:21:38 +0000
(08:21 -0800)
Technically, it might be possible for struct pstore_info to go out of
scope after the module_put(), so report the backend name first.
Signed-off-by: Kees Cook <keescook@chromium.org>
fs/pstore/platform.c
patch
|
blob
|
blame
|
history
diff --git
a/fs/pstore/platform.c
b/fs/pstore/platform.c
index 074fe85a207806b745d2748c1ea431e0da96a5cb..d69ef8a840b96152568073034b3c7d73377f2261 100644
(file)
--- a/
fs/pstore/platform.c
+++ b/
fs/pstore/platform.c
@@
-722,10
+722,10
@@
int pstore_register(struct pstore_info *psi)
*/
backend = psi->name;
- module_put(owner);
-
pr_info("Registered %s as persistent store backend\n", psi->name);
+ module_put(owner);
+
return 0;
}
EXPORT_SYMBOL_GPL(pstore_register);