This is a note to let you know that I've just added the patch titled selftests/bpf: fix compiler warnings in RELEASE=1 mode to the 6.7-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary The filename of the patch is: selftests-bpf-fix-compiler-warnings-in-release-1-mod.patch and it can be found in the queue-6.7 subdirectory. If you, or anyone else, feels it should not be added to the stable tree, please let <stable@xxxxxxxxxxxxxxx> know about it. commit e5d23d028bee0819d71b16ce8432edba604c3380 Author: Andrii Nakryiko <andrii@xxxxxxxxxx> Date: Tue Dec 12 14:53:43 2023 -0800 selftests/bpf: fix compiler warnings in RELEASE=1 mode [ Upstream commit 62d9a969f4a95219c757831e9ad66cd4dd9edee5 ] When compiling BPF selftests with RELEASE=1, we get two new warnings, which are treated as errors. Fix them. Signed-off-by: Andrii Nakryiko <andrii@xxxxxxxxxx> Acked-by: Yonghong Song <yonghong.song@xxxxxxxxx> Acked-by: John Fastabend <john.fastabend@xxxxxxxxx> Link: https://lore.kernel.org/r/20231212225343.1723081-1-andrii@xxxxxxxxxx Signed-off-by: Alexei Starovoitov <ast@xxxxxxxxxx> Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx> diff --git a/tools/testing/selftests/bpf/veristat.c b/tools/testing/selftests/bpf/veristat.c index 655095810d4a..0ad98b6a8e6e 100644 --- a/tools/testing/selftests/bpf/veristat.c +++ b/tools/testing/selftests/bpf/veristat.c @@ -1214,7 +1214,7 @@ static int cmp_join_stat(const struct verif_stats_join *s1, enum stat_id id, enum stat_variant var, bool asc) { const char *str1 = NULL, *str2 = NULL; - double v1, v2; + double v1 = 0.0, v2 = 0.0; int cmp = 0; fetch_join_stat_value(s1, id, var, &str1, &v1); diff --git a/tools/testing/selftests/bpf/xdp_hw_metadata.c b/tools/testing/selftests/bpf/xdp_hw_metadata.c index c3ba40d0b9de..c5e7937d7f63 100644 --- a/tools/testing/selftests/bpf/xdp_hw_metadata.c +++ b/tools/testing/selftests/bpf/xdp_hw_metadata.c @@ -70,7 +70,7 @@ static int open_xsk(int ifindex, struct xsk *xsk, __u32 queue_id) .frame_size = XSK_UMEM__DEFAULT_FRAME_SIZE, .flags = XDP_UMEM_UNALIGNED_CHUNK_FLAG, }; - __u32 idx; + __u32 idx = 0; u64 addr; int ret; int i;