Skip to content

net: fixes for cached dsts are never invalidated

Benjamin LaHaise netdev 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest6 patches 12 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/6ipv4: check rt_genid in dst_checknet/ipv4/route.c+12 -50 replies
2/6net: Document dst->obsolete better.include/net/dst.h net/core/dst.c net/ipv4/route.c +2 more+33 -200 replies
3/6ipv6: use DST_* macro to set obselete fieldnet/ipv6/route.c+5 -50 replies
4/6netns: move net->ipv4.rt_genid to net->rt_genidinclude/net/net_namespace.h include/net/netns/ipv4.h net/ipv4/route.c+15 -90 replies
5/6ipv6: use net->rt_genid to check dst validityinclude/net/ip6_fib.h net/ipv6/inet6_connection_sock.c net/ipv6/route.c+23 -340 replies
6/6xfrm: invalidate dst on policy insertion/deletionnet/xfrm/xfrm_policy.c security/selinux/include/xfrm.h+2 -00 replies

Reviews trailers per patch

2 of 6 patches have a Reviewed-by or Acked-by.

PatchHerbert XuEric Dumazet
1/6A-b
2/6
3/6A-b
4/6
5/6
6/6

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v1 thread

Cover letter [stable 2.6.32.y PATCH 0/6] net: fixes for cached dsts are never invalidated

This is v2 of an attempt to pull in the relevant fixes for a problem in v2.6.32 kernels where invalid cached routes are retained even after changes to the routing table have been made. A simple test case can be found at
http://marc.info/?l=linux-netdev&m=135015076708950&w=2 . Based on feedback from David Miller, additional changes have been pulled in, including fixes for the same issue in IPv6. Most of the patches required some rework owing to the large differences in the networking stack between 2.6.32 and 3.6.

I have performed basic tests to confirm that the cases I was hitting are now fixed, including a couple of tests with IPv4 and IPv6. Comments? Thanks again to David for the pointers to the additional fixes required in this area.

Benjamin LaHaise (6):
ipv4: check_rt_genid in dst_check
net: Document dst->obsolete better.
ipv6: use DST_* macro to set obselete field
netns: move net->ipv4.rt_genid to net->rt_genid
ipv6: use net->rt_genid to check dst validity
xfrm: invalidate dst on policy insertion/deletion

 include/net/dst.h                |   14 +++++++++++++-
 include/net/ip6_fib.h            |    4 +---
 include/net/net_namespace.h      |   12 ++++++++++++
 include/net/netns/ipv4.h         |    1 -
 net/core/dst.c                   |    4 ++--
 net/ipv4/route.c                 |   28 +++++++++++++++-------------
 net/ipv6/inet6_connection_sock.c |   24 +-----------------------
 net/ipv6/route.c                 |   35 ++++++++++++++++++++++++-----------
 net/sctp/output.c                |    2 +-
 net/xfrm/xfrm_policy.c           |   22 ++++++++++++----------
 security/selinux/include/xfrm.h  |    1 +
 11 files changed, 82 insertions(+), 65 deletions(-)
Signature · 1 line
"Thought is the essence of where you are now."