dect
/
linux-2.6
Archived
13
0
Fork 0

fib: suppress lockdep-RCU false positive in FIB trie.

Followup of commit 634a4b20

Allow tnode_get_child_rcu() to be called either under rcu_read_lock()
protection or with RTNL held.

Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
Eric Dumazet 2010-04-14 16:13:29 -07:00 committed by David S. Miller
parent 0110d6f22f
commit 4eaa0e3c86
1 changed files with 3 additions and 1 deletions

View File

@ -209,7 +209,9 @@ static inline struct node *tnode_get_child_rcu(struct tnode *tn, unsigned int i)
{
struct node *ret = tnode_get_child(tn, i);
return rcu_dereference(ret);
return rcu_dereference_check(ret,
rcu_read_lock_held() ||
lockdep_rtnl_is_held());
}
static inline int tnode_child_length(const struct tnode *tn)