diff options
author | Kumar Kartikeya Dwivedi <memxor@gmail.com> | 2021-07-02 14:18:21 +0300 |
---|---|---|
committer | Alexei Starovoitov <ast@kernel.org> | 2021-07-08 06:01:45 +0300 |
commit | fe21cb91ae7bca1ae7805454be80b6d03bec85f7 (patch) | |
tree | 91a88140fb07744b5809d5791e6c1e99896de020 /include/linux/bitops.h | |
parent | a080cdccc93da8754e4a20aea4f9c5fcc448547f (diff) | |
download | linux-fe21cb91ae7bca1ae7805454be80b6d03bec85f7.tar.xz |
net: core: Split out code to run generic XDP prog
This helper can later be utilized in code that runs cpumap and devmap
programs in generic redirect mode and adjust skb based on changes made
to xdp_buff.
When returning XDP_REDIRECT/XDP_TX, it invokes __skb_push, so whenever a
generic redirect path invokes devmap/cpumap prog if set, it must
__skb_pull again as we expect mac header to be pulled.
It also drops the skb_reset_mac_len call after do_xdp_generic, as the
mac_header and network_header are advanced by the same offset, so the
difference (mac_len) remains constant.
Signed-off-by: Kumar Kartikeya Dwivedi <memxor@gmail.com>
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Reviewed-by: Toke Høiland-Jørgensen <toke@redhat.com>
Link: https://lore.kernel.org/bpf/20210702111825.491065-2-memxor@gmail.com
Diffstat (limited to 'include/linux/bitops.h')
0 files changed, 0 insertions, 0 deletions