]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
net: Implement netdev_nl_queue_create_doit
authorDaniel Borkmann <daniel@iogearbox.net>
Thu, 15 Jan 2026 08:25:49 +0000 (09:25 +0100)
committerPaolo Abeni <pabeni@redhat.com>
Tue, 20 Jan 2026 10:58:49 +0000 (11:58 +0100)
commit31127deddef4a13628202a7bfef912e6c1ba3e57
tree0bbeb87bc621a76bbaaa3ced5f4f150d5f18c400
parenta5546e18f77c0cb15d434bf5b92647687fe483e3
net: Implement netdev_nl_queue_create_doit

Implement netdev_nl_queue_create_doit which creates a new rx queue in a
virtual netdev and then leases it to a rx queue in a physical netdev.

Example with ynl client:

  # ./pyynl/cli.py \
      --spec ~/netlink/specs/netdev.yaml \
      --do queue-create \
      --json '{"ifindex": 8, "type": "rx", "lease": {"ifindex": 4, "queue": {"type": "rx", "id": 15}}}'
  {'id': 1}

Note that the netdevice locking order is always from the virtual to
the physical device.

Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
Co-developed-by: David Wei <dw@davidwei.uk>
Signed-off-by: David Wei <dw@davidwei.uk>
Acked-by: Stanislav Fomichev <sdf@fomichev.me>
Reviewed-by: Nikolay Aleksandrov <razor@blackwall.org>
Link: https://patch.msgid.link/20260115082603.219152-3-daniel@iogearbox.net
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
include/net/netdev_queues.h
include/net/netdev_rx_queue.h
include/net/xdp_sock_drv.h
net/core/dev.c
net/core/dev.h
net/core/netdev-genl.c
net/core/netdev_queues.c
net/core/netdev_rx_queue.c
net/xdp/xsk.c