RFC net: L3 master device
Get series with b4
b4 am [email protected]Versions newest first
- v1 RFC Latest11 patches 0 repliesNew
Patches in v1 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/11 | net: Introduce L3 Master device abstractionMAINTAINERS include/ include/ +5 more | +241 | 0 replies | |
| 2/11 | net: Rename IFF_VRF_MASTER to IFF_L3MDEVdrivers/ include/ include/ +4 more | +16 | 0 replies | |
| 3/11 | net: Add support for l3mdev ops to VRF driverdrivers/ drivers/ | +30 | 0 replies | |
| 4/11 | net: Replace vrf_master_ifindex{,_rcu} with l3mdev equivalentsinclude/ net/ net/ +4 more | +20 | 0 replies | |
| 5/11 | net: Replace vrf_dev_table and friendsinclude/ net/ net/ | +5 | 0 replies | |
| 6/11 | net: Replace calls to vrf_dev_get_rthinclude/ net/ | +4 | 0 replies | |
| 7/11 | net: Remove the now unused vrf_ptrdrivers/ include/ include/ | +2 | 0 replies | |
| 8/11 | net: Remove vrf header fileMAINTAINERS drivers/ include/ | +15 | 0 replies | |
| 9/11 | net: Move netif_index_is_l3_master to l3mdev.hinclude/ include/ include/ | +25 | 0 replies | |
| 10/11 | net: Rename FLOWI_FLAG_VRFSRC to FLOWI_FLAG_L3MDEV_SRCdrivers/ include/ include/ +2 more | +6 | 0 replies | |
| 11/11 | net: Add netif_is_l3_slavedrivers/ include/ net/ | +12 | 0 replies |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.
Cover letter [RFC net-next 00/11] net: L3 master device
The VRF device is essentially a Layer 3 master device used to associate netdevices with a specific routing table and to influence FIB lookups via 'ip rules' and controlling the oif/iif used for the lookup.
This series generalizes the VRF into L3 master device, l3mdev. Similar to switchdev it has a Kconfig option and separate set of operations in net_device allowing it to be completely compiled out if not wanted. The l3mdev methods rely on the 'master' aspect and use of netdev_master_upper_dev_get_rcu to retrieve the master device from a given netdevice if it is enslaved to an L3_MASTER.
The VRF device is converted to use the l3mdev operations. At the end the vrf_ptr is no longer and removed, as are all direct references to VRF. The end result is a much simpler implementation for VRF.
Thanks to Nikolay for suggestions (eg., use of the master linkage which is the key to making this work) and to Roopa, Andy and Shrijeet for early reviews.
David Ahern (11):
net: Introduce L3 Master device abstraction
net: Rename IFF_VRF_MASTER to IFF_L3MDEV
net: Add support for l3mdev ops to VRF driver
net: Replace vrf_master_ifindex{,_rcu} with l3mdev equivalents
net: Replace vrf_dev_table and friends
net: Replace calls to vrf_dev_get_rth
net: Remove the now unused vrf_ptr
net: Remove vrf header file
net: Move netif_index_is_l3_master to l3mdev.h
net: Rename FLOWI_FLAG_VRFSRC to FLOWI_FLAG_L3MDEV_SRC
net: Add netif_is_l3_slave
MAINTAINERS | 8 ++- drivers/net/Kconfig | 1 + drivers/net/vrf.c | 87 ++++++++++++---------- include/linux/netdevice.h | 41 ++++------- include/net/flow.h | 2 +- include/net/l3mdev.h | 152 +++++++++++++++++++++++++++++++++++++++ include/net/route.h | 5 +- include/net/vrf.h | 178 ---------------------------------------------- net/Kconfig | 1 + net/Makefile | 3 + net/ipv4/af_inet.c | 4 +- net/ipv4/fib_frontend.c | 12 ++-- net/ipv4/fib_trie.c | 2 +- net/ipv4/icmp.c | 8 +-- net/ipv4/ip_fragment.c | 6 +- net/ipv4/ip_output.c | 2 +- net/ipv4/route.c | 16 ++--- net/ipv4/udp.c | 4 +- net/ipv4/xfrm4_policy.c | 8 +-- net/ipv6/xfrm6_policy.c | 8 +-- net/l3mdev/Kconfig | 10 +++ net/l3mdev/Makefile | 5 ++ net/l3mdev/l3mdev.c | 74 +++++++++++++++++++ 23 files changed, 354 insertions(+), 283 deletions(-) create mode 100644 include/net/l3mdev.h delete mode 100644 include/net/vrf.h create mode 100644 net/l3mdev/Kconfig create mode 100644 net/l3mdev/Makefile create mode 100644 net/l3mdev/l3mdev.c
Signature · 1 line
1.9.1