diff options
author | Martin Schwidefsky <schwidefsky@de.ibm.com> | 2018-08-06 14:26:39 +0200 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2018-09-05 09:29:52 +0200 |
commit | dacf5e5947082e8ae4df3b3105eb3d851bcda23a (patch) | |
tree | 59eb7bbdd8a16c7e0fef9dc5eb3d666e0aebdd73 /arch | |
parent | 6a32f6f857afff26a736997a0bd702e33aaf6582 (diff) | |
download | linux-stable-dacf5e5947082e8ae4df3b3105eb3d851bcda23a.tar.gz linux-stable-dacf5e5947082e8ae4df3b3105eb3d851bcda23a.tar.bz2 linux-stable-dacf5e5947082e8ae4df3b3105eb3d851bcda23a.zip |
s390: fix br_r1_trampoline for machines without exrl
commit 26f843848bae973817b3587780ce6b7b0200d3e4 upstream.
For machines without the exrl instruction the BFP jit generates
code that uses an "br %r1" instruction located in the lowcore page.
Unfortunately there is a cut & paste error that puts an additional
"larl %r1,.+14" instruction in the code that clobbers the branch
target address in %r1. Remove the larl instruction.
Cc: <stable@vger.kernel.org> # v4.17+
Fixes: de5cb6eb51 ("s390: use expoline thunks in the BPF JIT")
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'arch')
-rw-r--r-- | arch/s390/net/bpf_jit_comp.c | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/arch/s390/net/bpf_jit_comp.c b/arch/s390/net/bpf_jit_comp.c index 5f0234ec8038..d7052cbe984f 100644 --- a/arch/s390/net/bpf_jit_comp.c +++ b/arch/s390/net/bpf_jit_comp.c @@ -485,8 +485,6 @@ static void bpf_jit_epilogue(struct bpf_jit *jit, u32 stack_depth) /* br %r1 */ _EMIT2(0x07f1); } else { - /* larl %r1,.+14 */ - EMIT6_PCREL_RILB(0xc0000000, REG_1, jit->prg + 14); /* ex 0,S390_lowcore.br_r1_tampoline */ EMIT4_DISP(0x44000000, REG_0, REG_0, offsetof(struct lowcore, br_r1_trampoline)); |