Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 313920
b: refs/heads/master
c: 56a6b24
h: refs/heads/master
v: v3
  • Loading branch information
David S. Miller committed Jun 9, 2012
1 parent b2aabe5 commit 7258b92
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 15 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: c3426b47190d7c6785230c91a706fd42208b4120
refs/heads/master: 56a6b248eb345c1948ee60bf426de1ff7dd81509
3 changes: 1 addition & 2 deletions trunk/include/net/inetpeer.h
Original file line number Diff line number Diff line change
Expand Up @@ -113,8 +113,7 @@ static inline struct inet_peer *inet_getpeer_v6(struct net *net,
extern void inet_putpeer(struct inet_peer *p);
extern bool inet_peer_xrlim_allow(struct inet_peer *peer, int timeout);

extern void __inetpeer_invalidate_tree(struct inet_peer_base *);
extern void inetpeer_invalidate_tree(struct net *net, int family);
extern void inetpeer_invalidate_tree(struct inet_peer_base *);

/*
* temporary check to make sure we dont access rid, ip_id_count, tcp_ts,
Expand Down
10 changes: 1 addition & 9 deletions trunk/net/ipv4/inetpeer.c
Original file line number Diff line number Diff line change
Expand Up @@ -564,7 +564,7 @@ static void inetpeer_inval_rcu(struct rcu_head *head)
schedule_delayed_work(&gc_work, gc_delay);
}

void __inetpeer_invalidate_tree(struct inet_peer_base *base)
void inetpeer_invalidate_tree(struct inet_peer_base *base)
{
struct inet_peer *old, *new, *prev;

Expand All @@ -585,12 +585,4 @@ void __inetpeer_invalidate_tree(struct inet_peer_base *base)
out:
write_sequnlock_bh(&base->lock);
}
EXPORT_SYMBOL(__inetpeer_invalidate_tree);

void inetpeer_invalidate_tree(struct net *net, int family)
{
struct inet_peer_base *base = family_to_base(net, family);

__inetpeer_invalidate_tree(base);
}
EXPORT_SYMBOL(inetpeer_invalidate_tree);
4 changes: 2 additions & 2 deletions trunk/net/ipv4/route.c
Original file line number Diff line number Diff line change
Expand Up @@ -935,7 +935,7 @@ static void rt_cache_invalidate(struct net *net)

get_random_bytes(&shuffle, sizeof(shuffle));
atomic_add(shuffle + 1U, &net->ipv4.rt_genid);
inetpeer_invalidate_tree(net, AF_INET);
inetpeer_invalidate_tree(net->ipv4.peers);
}

/*
Expand Down Expand Up @@ -3401,7 +3401,7 @@ static void __net_exit ipv4_inetpeer_exit(struct net *net)
struct inet_peer_base *bp = net->ipv4.peers;

net->ipv4.peers = NULL;
__inetpeer_invalidate_tree(bp);
inetpeer_invalidate_tree(bp);
kfree(bp);
}

Expand Down
2 changes: 1 addition & 1 deletion trunk/net/ipv6/route.c
Original file line number Diff line number Diff line change
Expand Up @@ -3012,7 +3012,7 @@ static void __net_exit ipv6_inetpeer_exit(struct net *net)
struct inet_peer_base *bp = net->ipv6.peers;

net->ipv6.peers = NULL;
__inetpeer_invalidate_tree(bp);
inetpeer_invalidate_tree(bp);
kfree(bp);
}

Expand Down

0 comments on commit 7258b92

Please sign in to comment.