diff options
author | Paul E. McKenney <paulmck@linux.vnet.ibm.com> | 2015-09-02 20:11:22 -0400 |
---|---|---|
committer | Paul E. McKenney <paulmck@linux.vnet.ibm.com> | 2015-09-03 21:13:10 -0400 |
commit | dc3a04d551b5d21f1badbb39bfe8e5bc1289b184 (patch) | |
tree | 52fa90b97123f88e22d498e1676cf0c65431a96b | |
parent | 12d560f4ea87030667438a169912380be00cea4b (diff) |
security/device_cgroup: Fix RCU_LOCKDEP_WARN() condition
f78f5b90c4ff ("rcu: Rename rcu_lockdep_assert() to RCU_LOCKDEP_WARN()")
introduced a bug by incorrectly inverting the condition when moving from
rcu_lockdep_assert() to RCU_LOCKDEP_WARN(). This commit therefore fixes
the inversion.
Reported-by: Felipe Balbi <balbi@ti.com>
Reported-by: Tejun Heo <tj@kernel.org>
Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
Acked-by: Serge Hallyn <serge.hallyn@canonical.com>
Tested-by: Josh Boyer <jwboyer@fedoraproject.org>
-rw-r--r-- | security/device_cgroup.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/security/device_cgroup.c b/security/device_cgroup.c index 73455089feef..03c1652c9a1f 100644 --- a/security/device_cgroup.c +++ b/security/device_cgroup.c | |||
@@ -401,7 +401,7 @@ static bool verify_new_ex(struct dev_cgroup *dev_cgroup, | |||
401 | bool match = false; | 401 | bool match = false; |
402 | 402 | ||
403 | RCU_LOCKDEP_WARN(!rcu_read_lock_held() && | 403 | RCU_LOCKDEP_WARN(!rcu_read_lock_held() && |
404 | lockdep_is_held(&devcgroup_mutex), | 404 | !lockdep_is_held(&devcgroup_mutex), |
405 | "device_cgroup:verify_new_ex called without proper synchronization"); | 405 | "device_cgroup:verify_new_ex called without proper synchronization"); |
406 | 406 | ||
407 | if (dev_cgroup->behavior == DEVCG_DEFAULT_ALLOW) { | 407 | if (dev_cgroup->behavior == DEVCG_DEFAULT_ALLOW) { |