selftests/bpf: convert bpf tunnel test to BPF_ADJ_ROOM_MAC
authorWillem de Bruijn <willemb@google.com>
Fri, 22 Mar 2019 18:32:58 +0000 (14:32 -0400)
committerAlexei Starovoitov <ast@kernel.org>
Fri, 22 Mar 2019 20:52:45 +0000 (13:52 -0700)
commit005edd16562b78f416e2f576a64789c90d96882f
treeae38689ac20f4f963741428327536efc34fa8393
parent6c408decbdc8a12a12a93c4d763cbc2a264f9332
selftests/bpf: convert bpf tunnel test to BPF_ADJ_ROOM_MAC

Avoid moving the network layer header when prefixing tunnel headers.

This avoids an explicit call to bpf_skb_store_bytes and an implicit
move of the network header bytes in bpf_skb_adjust_room.

Signed-off-by: Willem de Bruijn <willemb@google.com>
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
tools/testing/selftests/bpf/progs/test_tc_tunnel.c