WSL2-Linux-Kernel/arch/arm64/net
Hou Tao c08f23081c bpf, arm64: Feed byte-offset into bpf line info
[ Upstream commit dda7596c10 ]

insn_to_jit_off passed to bpf_prog_fill_jited_linfo() is calculated in
instruction granularity instead of bytes granularity, but BPF line info
requires byte offset.

bpf_prog_fill_jited_linfo() will be the last user of ctx.offset before
it is freed, so convert the offset into byte-offset before calling into
bpf_prog_fill_jited_linfo() in order to fix the line info dump on arm64.

Fixes: 37ab566c17 ("bpf: arm64: Enable arm64 jit to provide bpf_line_info")
Suggested-by: Daniel Borkmann <daniel@iogearbox.net>
Signed-off-by: Hou Tao <houtao1@huawei.com>
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
Link: https://lore.kernel.org/bpf/20220226121906.5709-3-houtao1@huawei.com
Signed-off-by: Sasha Levin <sashal@kernel.org>
2022-04-08 14:23:35 +02:00
..
Makefile treewide: Add SPDX license identifier - Makefile/Kconfig 2019-05-21 10:50:46 +02:00
bpf_jit.h Merge branch 'for-next/bti' into for-next/core 2020-05-28 18:00:51 +01:00
bpf_jit_comp.c bpf, arm64: Feed byte-offset into bpf line info 2022-04-08 14:23:35 +02:00