diff options
author | Eric Dumazet <edumazet@google.com> | 2012-07-17 16:42:13 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2012-07-17 16:47:33 -0400 |
commit | 5abf7f7e0f6bdbfcac737f636497d7016d9507eb (patch) | |
tree | c52a21ed83a306c6626a00378934a28a6daa8db0 /net/ipv4/inet_connection_sock.c | |
parent | d3a25c980fc231238256f8d80816367674e5caaf (diff) |
ipv4: fix rcu splat
free_nh_exceptions() should use rcu_dereference_protected(..., 1)
since its called after one RCU grace period.
Also add some const-ification in recent code.
Signed-off-by: Eric Dumazet <edumazet@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4/inet_connection_sock.c')
-rw-r--r-- | net/ipv4/inet_connection_sock.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/net/ipv4/inet_connection_sock.c b/net/ipv4/inet_connection_sock.c index 3ea465286a39..c7a4de05ca04 100644 --- a/net/ipv4/inet_connection_sock.c +++ b/net/ipv4/inet_connection_sock.c | |||
@@ -806,8 +806,8 @@ EXPORT_SYMBOL_GPL(inet_csk_compat_setsockopt); | |||
806 | 806 | ||
807 | static struct dst_entry *inet_csk_rebuild_route(struct sock *sk, struct flowi *fl) | 807 | static struct dst_entry *inet_csk_rebuild_route(struct sock *sk, struct flowi *fl) |
808 | { | 808 | { |
809 | struct inet_sock *inet = inet_sk(sk); | 809 | const struct inet_sock *inet = inet_sk(sk); |
810 | struct ip_options_rcu *inet_opt; | 810 | const struct ip_options_rcu *inet_opt; |
811 | __be32 daddr = inet->inet_daddr; | 811 | __be32 daddr = inet->inet_daddr; |
812 | struct flowi4 *fl4; | 812 | struct flowi4 *fl4; |
813 | struct rtable *rt; | 813 | struct rtable *rt; |