OSDN Git Service

libbpf: add support for need_wakeup flag in AF_XDP part
authorMagnus Karlsson <magnus.karlsson@intel.com>
Wed, 14 Aug 2019 07:27:20 +0000 (09:27 +0200)
committerDaniel Borkmann <daniel@iogearbox.net>
Sat, 17 Aug 2019 21:07:32 +0000 (23:07 +0200)
commita4500432c2587cb2ae7554537886a4516ff2e7aa
tree0d47b6abb6500eec416b23f908a974e101aff3b2
parent5c129241e2de79f09cb4e50bbca09e1c14ad787d
libbpf: add support for need_wakeup flag in AF_XDP part

This commit adds support for the new need_wakeup flag in AF_XDP. The
xsk_socket__create function is updated to handle this and a new
function is introduced called xsk_ring_prod__needs_wakeup(). This
function can be used by the application to check if Rx and/or Tx
processing needs to be explicitly woken up.

Signed-off-by: Magnus Karlsson <magnus.karlsson@intel.com>
Acked-by: Jonathan Lemon <jonathan.lemon@gmail.com>
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
tools/include/uapi/linux/if_xdp.h
tools/lib/bpf/xsk.c
tools/lib/bpf/xsk.h