summaryrefslogtreecommitdiffstats
path: root/include/trace
diff options
context:
space:
mode:
authorMasami Hiramatsu <masami.hiramatsu.pt@hitachi.com>2014-11-10 09:29:29 +1030
committerRusty Russell <rusty@rustcorp.com.au>2014-11-11 17:07:46 +1030
commit2f35c41f58a978dfa44ffa102249d556caa99eeb (patch)
tree871fdf31787639112af15e3532bb6617660f2e47 /include/trace
parent0286b5ea125e58b4797747f688949c05394412e8 (diff)
downloadlinux-stable-2f35c41f58a978dfa44ffa102249d556caa99eeb.tar.gz
linux-stable-2f35c41f58a978dfa44ffa102249d556caa99eeb.tar.bz2
linux-stable-2f35c41f58a978dfa44ffa102249d556caa99eeb.zip
module: Replace module_ref with atomic_t refcnt
Replace module_ref per-cpu complex reference counter with an atomic_t simple refcnt. This is for code simplification. Signed-off-by: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Diffstat (limited to 'include/trace')
-rw-r--r--include/trace/events/module.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/trace/events/module.h b/include/trace/events/module.h
index 7c5cbfe3fc49..81c4c183d348 100644
--- a/include/trace/events/module.h
+++ b/include/trace/events/module.h
@@ -80,7 +80,7 @@ DECLARE_EVENT_CLASS(module_refcnt,
TP_fast_assign(
__entry->ip = ip;
- __entry->refcnt = __this_cpu_read(mod->refptr->incs) - __this_cpu_read(mod->refptr->decs);
+ __entry->refcnt = atomic_read(&mod->refcnt);
__assign_str(name, mod->name);
),