linux/drivers/net
Sven Eckelmann a02192151b macvtap: advertise link netns via netlink
Assign rtnl_link_ops->get_link_net() callback so that IFLA_LINK_NETNSID is
added to rtnetlink messages. This fixes iproute2 which otherwise resolved
the link interface to an interface in the wrong namespace.

Test commands:

  ip netns add nst
  ip link add dummy0 type dummy
  ip link add link macvtap0 link dummy0 type macvtap
  ip link set macvtap0 netns nst
  ip -netns nst link show macvtap0

Before:

  10: macvtap0@gre0: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN mode DEFAULT group default qlen 500
      link/ether 5e:8f:ae:1d:60:50 brd ff:ff:ff:ff:ff:ff

After:

  10: macvtap0@if2: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN mode DEFAULT group default qlen 500
      link/ether 5e:8f:ae:1d:60:50 brd ff:ff:ff:ff:ff:ff link-netnsid 0

Reported-by: Leonardo Mörlein <freifunk@irrelefant.net>
Signed-off-by: Sven Eckelmann <sven@narfation.org>
Link: https://lore.kernel.org/r/20220228003240.1337426-1-sven@narfation.org
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
2022-03-01 17:59:28 -08:00
..
appletalk
arcnet
bonding bonding: add new option ns_ip6_target 2022-02-21 12:13:45 +00:00
caif
can spi: Make remove() return void 2022-02-28 10:43:07 -08:00
dsa spi: Make remove() return void 2022-02-28 10:43:07 -08:00
ethernet nfp: avoid newline at end of message in NL_SET_ERR_MSG_MOD 2022-03-01 17:42:26 -08:00
fddi
fjes
hamradio net: hamradio: use time_is_after_jiffies() instead of open coding it 2022-02-28 13:21:31 +00:00
hippi
hyperv
ieee802154 spi: Make remove() return void 2022-02-28 10:43:07 -08:00
ipa
ipvlan
mctp mctp i2c: Fix hard head TX bounds length check 2022-02-25 22:23:33 -08:00
mdio Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2022-02-24 17:54:25 -08:00
netdevsim
pcs
phy spi: Make remove() return void 2022-02-28 10:43:07 -08:00
plip
ppp
slip
team teaming: deliver link-local packets with the link they arrive on 2022-02-18 11:40:52 +00:00
usb net: asix: remove code duplicates in asix_mdio_read/write and asix_mdio_read/write_nopm 2022-02-24 21:21:30 -08:00
vmxnet3
vxlan drivers: vxlan: vnifilter: add support for stats dumping 2022-03-01 08:38:02 +00:00
wan spi: Make remove() return void 2022-02-28 10:43:07 -08:00
wireguard
wireless spi: Make remove() return void 2022-02-28 10:43:07 -08:00
wwan
xen-netback Revert "xen-netback: Check for hotplug-status existence before watching" 2022-02-24 08:58:37 -08:00
amt.c
bareudp.c
dummy.c
eql.c
geneve.c
gtp.c
ifb.c
Kconfig
LICENSE.SRC
loopback.c
macsec.c
macvlan.c
macvtap.c macvtap: advertise link netns via netlink 2022-03-01 17:59:28 -08:00
Makefile vxlan: move to its own directory 2022-03-01 08:38:01 +00:00
mdio.c
mhi_net.c
mii.c
net_failover.c
netconsole.c
nlmon.c
ntb_netdev.c
rionet.c
sb1000.c
Space.c
sungem_phy.c
tap.c
thunderbolt.c
tun.c tun: support NAPI for packets received from batched XDP buffs 2022-03-01 17:27:53 -08:00
veth.c
virtio_net.c
vrf.c
vsockmon.c
xen-netfront.c