Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 218419
b: refs/heads/master
c: 1c87733
h: refs/heads/master
i:
  218417: 57bede5
  218415: 5baaf70
v: v3
  • Loading branch information
Eric Dumazet authored and David S. Miller committed Oct 25, 2010
1 parent e532404 commit 4500b42
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 6e3f7faf3e8a3e226b1a6b955aac12abf2f2e1b6
refs/heads/master: 1c87733d0682547050ccccb400cdac425fa43b39
2 changes: 1 addition & 1 deletion trunk/include/net/net_namespace.h
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ struct net {
#ifdef CONFIG_WEXT_CORE
struct sk_buff_head wext_nlevents;
#endif
struct net_generic *gen;
struct net_generic __rcu *gen;

/* Note : following structs are cache line aligned */
#ifdef CONFIG_XFRM
Expand Down
4 changes: 3 additions & 1 deletion trunk/net/core/net_namespace.c
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,9 @@ static int net_assign_generic(struct net *net, int id, void *data)
BUG_ON(!mutex_is_locked(&net_mutex));
BUG_ON(id == 0);

ng = old_ng = net->gen;
old_ng = rcu_dereference_protected(net->gen,
lockdep_is_held(&net_mutex));
ng = old_ng;
if (old_ng->len >= id)
goto assign;

Expand Down

0 comments on commit 4500b42

Please sign in to comment.