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>
This commit is contained in:

committed by
Rusty Russell

parent
0286b5ea12
commit
2f35c41f58
@@ -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);
|
||||
),
|
||||
|
||||
|
Reference in New Issue
Block a user