From: Paul E. McKenney Date: Tue, 8 Jun 2010 00:09:45 +0000 (-0700) Subject: idr: fix RCU lockdep splat in idr_get_next() X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=94bfa3b6692c7a3f6f119596724204ec975d3ef0;p=GitHub%2Fmoto-9609%2Fandroid_kernel_motorola_exynos9610.git idr: fix RCU lockdep splat in idr_get_next() Convert to rcu_dereference_raw() given that many callers may have many different locking models. Located-by: Miles Lane Tested-by: Miles Lane Signed-off-by: Paul E. McKenney --- diff --git a/lib/idr.c b/lib/idr.c index c1a206901761..7f1a4f0acf50 100644 --- a/lib/idr.c +++ b/lib/idr.c @@ -602,7 +602,7 @@ void *idr_get_next(struct idr *idp, int *nextidp) /* find first ent */ n = idp->layers * IDR_BITS; max = 1 << n; - p = rcu_dereference(idp->top); + p = rcu_dereference_raw(idp->top); if (!p) return NULL; @@ -610,7 +610,7 @@ void *idr_get_next(struct idr *idp, int *nextidp) while (n > 0 && p) { n -= IDR_BITS; *paa++ = p; - p = rcu_dereference(p->ary[(id >> n) & IDR_MASK]); + p = rcu_dereference_raw(p->ary[(id >> n) & IDR_MASK]); } if (p) {