summaryrefslogtreecommitdiffstats
path: root/kernel/pid.c
diff options
context:
space:
mode:
authorPaul E. McKenney <paulmck@linux.vnet.ibm.com>2015-06-18 15:50:02 -0700
committerPaul E. McKenney <paulmck@linux.vnet.ibm.com>2015-07-22 15:27:32 -0700
commitf78f5b90c4ffa559e400c3919a02236101f29f3f (patch)
treeded8a53b5c2bc06ab532d4b9a2e6e99a12912574 /kernel/pid.c
parent46f00d18fca42cc954c2e9e99a48b6f3a7741ed7 (diff)
downloadlinux-f78f5b90c4ffa559e400c3919a02236101f29f3f.tar.gz
linux-f78f5b90c4ffa559e400c3919a02236101f29f3f.tar.bz2
linux-f78f5b90c4ffa559e400c3919a02236101f29f3f.zip
rcu: Rename rcu_lockdep_assert() to RCU_LOCKDEP_WARN()
This commit renames rcu_lockdep_assert() to RCU_LOCKDEP_WARN() for consistency with the WARN() series of macros. This also requires inverting the sense of the conditional, which this commit also does. Reported-by: Ingo Molnar <mingo@kernel.org> Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Reviewed-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'kernel/pid.c')
-rw-r--r--kernel/pid.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/kernel/pid.c b/kernel/pid.c
index 4fd07d5b7baf..ca368793808e 100644
--- a/kernel/pid.c
+++ b/kernel/pid.c
@@ -451,9 +451,8 @@ EXPORT_SYMBOL(pid_task);
*/
struct task_struct *find_task_by_pid_ns(pid_t nr, struct pid_namespace *ns)
{
- rcu_lockdep_assert(rcu_read_lock_held(),
- "find_task_by_pid_ns() needs rcu_read_lock()"
- " protection");
+ RCU_LOCKDEP_WARN(!rcu_read_lock_held(),
+ "find_task_by_pid_ns() needs rcu_read_lock() protection");
return pid_task(find_pid_ns(nr, ns), PIDTYPE_PID);
}