Closed bersoare closed 4 years ago
thanks for the feedback! just adjusted formatting, added comments and did a small change to the kernel code
@bersoare i was just looking into this example and don't see examples/xdp/bpf_redirect_map/bpf_redirect_map
being used anywhere, was that intentionally included in this PR? If so, how/where is it used?
hey @waynr ,
thanks for pointing out. that is the compiled binary, i included it unintentionally. i will go ahead remove it
added ingress_ifindex, rx_queue_index, egress_ifindex fields to xdp_md struct (https://elixir.bootlin.com/linux/latest/source/include/uapi/linux/bpf.h#L3909) adjusted argument types for bpf_redirect_map prototype (https://man7.org/linux/man-pages/man7/bpf-helpers.7.html) added struct bpf_fib_lookup, as well as the constants for flags and return codes (https://elixir.bootlin.com/linux/latest/source/include/uapi/linux/bpf.h#L4303) added simple example of bpf_fib_lookup and bpf_redirect_map used in conjunction