]> git.baikalelectronics.ru Git - kernel.git/commit
bpf: Extend the sk_lookup() helper to XDP hookpoint.
authorNitin Hande <nitin.hande@gmail.com>
Mon, 29 Oct 2018 04:02:45 +0000 (21:02 -0700)
committerDaniel Borkmann <daniel@iogearbox.net>
Fri, 9 Nov 2018 09:14:54 +0000 (10:14 +0100)
commit8a7eb9c508e8252c035463c126394c30f174a19d
treebcaf2c624e5c4cf7f51fb33dd1c4bf115cc6c3fb
parentb8310770b31234e3e01f20ddddac2ad70784e559
bpf: Extend the sk_lookup() helper to XDP hookpoint.

This patch proposes to extend the sk_lookup() BPF API to the
XDP hookpoint. The sk_lookup() helper supports a lookup
on incoming packet to find the corresponding socket that will
receive this packet. Current support for this BPF API is
at the tc hookpoint. This patch will extend this API at XDP
hookpoint. A XDP program can map the incoming packet to the
5-tuple parameter and invoke the API to find the corresponding
socket structure.

Signed-off-by: Nitin Hande <Nitin.Hande@gmail.com>
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
include/uapi/linux/bpf.h
net/core/filter.c