diff options
author | Ilya Leoshkevich <[email protected]> | 2024-01-02 20:30:35 +0100 |
---|---|---|
committer | Alexei Starovoitov <[email protected]> | 2024-01-04 11:35:40 -0800 |
commit | ecba66cb36e3428e9f0c2362b45e213ad43ba8d0 (patch) | |
tree | 27f069acb175e293df7874bfd48b73011ca38a3f | |
parent | 98e20e5e13d2811898921f999288be7151a11954 (diff) |
s390/bpf: Fix gotol with large offsets
The gotol implementation uses a wrong data type for the offset: it
should be s32, not s16.
Fixes: c690191e23d8 ("s390/bpf: Implement unconditional jump with 32-bit offset")
Signed-off-by: Ilya Leoshkevich <[email protected]>
Acked-by: Yonghong Song <[email protected]>
Acked-by: John Fastabend <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Alexei Starovoitov <[email protected]>
-rw-r--r-- | arch/s390/net/bpf_jit_comp.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/s390/net/bpf_jit_comp.c b/arch/s390/net/bpf_jit_comp.c index 7f0a7b97ef4c..b418333bb086 100644 --- a/arch/s390/net/bpf_jit_comp.c +++ b/arch/s390/net/bpf_jit_comp.c @@ -779,7 +779,7 @@ static noinline int bpf_jit_insn(struct bpf_jit *jit, struct bpf_prog *fp, int i, bool extra_pass, u32 stack_depth) { struct bpf_insn *insn = &fp->insnsi[i]; - s16 branch_oc_off = insn->off; + s32 branch_oc_off = insn->off; u32 dst_reg = insn->dst_reg; u32 src_reg = insn->src_reg; int last, insn_count = 1; |