mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-30 03:27:44 -04:00
rcu: Put names into TINY_RCU structures under RCU_TRACE
In order to allow event tracing to distinguish between flavors of RCU, we need those names in the relevant RCU data structures. TINY_RCU has avoided them for memory-footprint reasons, so add them only if CONFIG_RCU_TRACE=y. Signed-off-by: Paul E. McKenney <[email protected]> Signed-off-by: Paul E. McKenney <[email protected]>
This commit is contained in:
parent
300df91ca9
commit
e99033c5c1
5 changed files with 18 additions and 27 deletions
10
kernel/rcu.h
10
kernel/rcu.h
|
|
@ -23,6 +23,12 @@
|
|||
#ifndef __LINUX_RCU_H
|
||||
#define __LINUX_RCU_H
|
||||
|
||||
#ifdef CONFIG_RCU_TRACE
|
||||
#define RCU_TRACE(stmt) stmt
|
||||
#else /* #ifdef CONFIG_RCU_TRACE */
|
||||
#define RCU_TRACE(stmt)
|
||||
#endif /* #else #ifdef CONFIG_RCU_TRACE */
|
||||
|
||||
/*
|
||||
* debug_rcu_head_queue()/debug_rcu_head_unqueue() are used internally
|
||||
* by call_rcu() and rcu callback execution, and are therefore not part of the
|
||||
|
|
@ -68,10 +74,10 @@ static inline void __rcu_reclaim(struct rcu_head *head)
|
|||
unsigned long offset = (unsigned long)head->func;
|
||||
|
||||
if (__is_kfree_rcu_offset(offset)) {
|
||||
trace_rcu_invoke_kfree_callback(head, offset);
|
||||
RCU_TRACE(trace_rcu_invoke_kfree_callback(head, offset));
|
||||
kfree((void *)head - offset);
|
||||
} else {
|
||||
trace_rcu_invoke_callback(head);
|
||||
RCU_TRACE(trace_rcu_invoke_callback(head));
|
||||
head->func(head);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue