]> git.baikalelectronics.ru Git - kernel.git/commit
samples/bpf: Decrement ttl in fib forwarding example
authorDavid Ahern <dsahern@gmail.com>
Tue, 15 May 2018 23:20:52 +0000 (16:20 -0700)
committerDaniel Borkmann <daniel@iogearbox.net>
Wed, 16 May 2018 20:04:52 +0000 (22:04 +0200)
commit5035b5b22978d19e7af1173684498f0315855687
treec974f9f6e52e873b0444c3f8f634741fbf74c88f
parentf6b91fc319e11cd68958aa6fa6ff9e9cf1e96334
samples/bpf: Decrement ttl in fib forwarding example

Only consider forwarding packets if ttl in received packet is > 1 and
decrement ttl before handing off to bpf_redirect_map.

Signed-off-by: David Ahern <dsahern@gmail.com>
Acked-by: Yonghong Song <yhs@fb.com>
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
samples/bpf/xdp_fwd_kern.c