summaryrefslogtreecommitdiffstats
path: root/include/linux/module.h
diff options
context:
space:
mode:
authorTejun Heo <tj@kernel.org>2010-03-10 18:57:54 +0900
committerTejun Heo <tj@kernel.org>2010-03-29 23:07:12 +0900
commit10fad5e46f6c7bdfb01b1a012380a38e3c6ab346 (patch)
tree9ec6e3955e7f879f64ea79812cf5ecd41baa6939 /include/linux/module.h
parent259354deaaf03d49a02dbb9975d6ec2a54675672 (diff)
downloadop-kernel-dev-10fad5e46f6c7bdfb01b1a012380a38e3c6ab346.zip
op-kernel-dev-10fad5e46f6c7bdfb01b1a012380a38e3c6ab346.tar.gz
percpu, module: implement and use is_kernel/module_percpu_address()
lockdep has custom code to check whether a pointer belongs to static percpu area which is somewhat broken. Implement proper is_kernel/module_percpu_address() and replace the custom code. On UP, percpu variables are regular static variables and can't be distinguished from them. Always return %false on UP. Signed-off-by: Tejun Heo <tj@kernel.org> Acked-by: Peter Zijlstra <a.p.zijlstra@chello.nl> Cc: Rusty Russell <rusty@rustcorp.com.au> Cc: Ingo Molnar <mingo@redhat.com>
Diffstat (limited to 'include/linux/module.h')
-rw-r--r--include/linux/module.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/include/linux/module.h b/include/linux/module.h
index 87d247a..f0e2659 100644
--- a/include/linux/module.h
+++ b/include/linux/module.h
@@ -395,6 +395,7 @@ static inline int module_is_live(struct module *mod)
struct module *__module_text_address(unsigned long addr);
struct module *__module_address(unsigned long addr);
bool is_module_address(unsigned long addr);
+bool is_module_percpu_address(unsigned long addr);
bool is_module_text_address(unsigned long addr);
static inline int within_module_core(unsigned long addr, struct module *mod)
OpenPOWER on IntegriCloud