Skip to content

net: devlink: Finish network namespace support

Jiri Pirko netdev 3 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v3 Latest3 patches 9 repliesIn review
  2. v23 patches 22 repliesSuperseded
  3. v13 patches 14 repliesSuperseded

Patches in v3 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/3net: devlink: allow to change namespacesinclude/uapi/linux/devlink.h net/core/devlink.c+167 -33 replies
2/3net: devlink: export devlink net set/get helpersinclude/net/devlink.h net/core/devlink.c+17 -40 replies
3/3netdevsim: create devlink and netdev instances in namespacedrivers/net/netdevsim/bus.c drivers/net/netdevsim/dev.c drivers/net/netdevsim/netdev.c +1 more+22 -80 replies

Reviews trailers per patch

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

PatchJakub Kicinski
1/3
2/3A-b
3/3R-b

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

Read the v3 thread

Cover letter [patch net-next v3 0/3] net: devlink: Finish network namespace support

From: Jiri Pirko <[email protected]>

Devlink from the beginning counts with network namespaces, but the instances has been fixed to init_net. The first patch allows user to move existing devlink instances into namespaces:

$ devlink dev
netdevsim/netdevsim1
$ ip netns add ns1
$ devlink dev set netdevsim/netdevsim1 netns ns1
$ devlink -N ns1 dev
netdevsim/netdevsim1

The last patch allows user to create new netdevsim instance directly inside network namespace of a caller.

Jiri Pirko (3):
net: devlink: allow to change namespaces
net: devlink: export devlink net set/get helpers
netdevsim: create devlink and netdev instances in namespace

 drivers/net/netdevsim/bus.c       |   1 +
 drivers/net/netdevsim/dev.c       |  17 ++-
 drivers/net/netdevsim/netdev.c    |   4 +-
 drivers/net/netdevsim/netdevsim.h |   8 +-
 include/net/devlink.h             |   3 +
 include/uapi/linux/devlink.h      |   4 +
 net/core/devlink.c                | 182 +++++++++++++++++++++++++++++-
 7 files changed, 205 insertions(+), 14 deletions(-)
Signature · 1 line
2.21.0