linux/arch/s390/net
Michael Holzheu b035b60ded s390/bpf: Fix backward jumps
Currently all backward jumps crash for JITed s390x eBPF programs
with an illegal instruction program check and kernel panic. Because
for negative values the opcode of the jump instruction is overriden
by the negative branch offset an illegal instruction is generated
by the JIT:

 000003ff802da378: c01100000002   lgfi    %r1,2
 000003ff802da37e: fffffff52065   unknown <-- illegal instruction
 000003ff802da384: b904002e       lgr     %r2,%r14

So fix this and mask the offset in order not to damage the opcode.

Cc: stable@vger.kernel.org # 4.0+
Signed-off-by: Michael Holzheu <holzheu@linux.vnet.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
2015-06-25 09:39:18 +02:00
..
bpf_jit_comp.c s390/bpf: Fix backward jumps 2015-06-25 09:39:18 +02:00
bpf_jit.h s390/bpf: implement bpf_tail_call() helper 2015-06-09 11:47:10 -07:00
bpf_jit.S s390/bpf: Add s390x eBPF JIT compiler backend 2015-04-15 12:23:49 +02:00
Makefile