samples: bpf: Fix lwt_len_hist reusing previous BPF map
authorDaniel T. Lee <danieltimlee@gmail.com>
Tue, 24 Nov 2020 09:03:09 +0000 (09:03 +0000)
committerCosmin Tanislav <demonsingur@gmail.com>
Thu, 16 May 2024 07:58:23 +0000 (10:58 +0300)
commit71bd2b7d4a42856fc3532e6f393a0a459e731615
tree93f7082c317814266f359df59f4c9341c29fa3fe
parent3dd509f37ef9491da5cfc6abd4c84e840142cc30
samples: bpf: Fix lwt_len_hist reusing previous BPF map

[ Upstream commit 0afe0a998c40085a6342e1aeb4c510cccba46caf ]

Currently, lwt_len_hist's map lwt_len_hist_map is uses pinning, and the
map isn't cleared on test end. This leds to reuse of that map for
each test, which prevents the results of the test from being accurate.

This commit fixes the problem by removing of pinned map from bpffs.
Also, this commit add the executable permission to shell script
files.

Fixes: f74599f7c5309 ("bpf: Add tests and samples for LWT-BPF")
Signed-off-by: Daniel T. Lee <danieltimlee@gmail.com>
Signed-off-by: Andrii Nakryiko <andrii@kernel.org>
Link: https://lore.kernel.org/bpf/20201124090310.24374-7-danieltimlee@gmail.com
Signed-off-by: Sasha Levin <sashal@kernel.org>
samples/bpf/lwt_len_hist.sh [changed mode: 0644->0755]
samples/bpf/test_lwt_bpf.sh [changed mode: 0644->0755]