arm64, insn: Add ldr/str with immediate offset
authorXu Kuohai <xukuohai@huawei.com>
Mon, 21 Mar 2022 15:28:48 +0000 (11:28 -0400)
committerDaniel Borkmann <daniel@iogearbox.net>
Thu, 31 Mar 2022 22:27:29 +0000 (00:27 +0200)
commit30c90f6757a7b38bc95069725657a647873e2ab3
treec91afc0e0dd0fb28f2069af0b894d2d1abf5f61e
parent2975dbdc3989cd66a4cb5a7c5510de2de8ee4d14
arm64, insn: Add ldr/str with immediate offset

This patch introduces ldr/str with immediate offset support to simplify
the JIT implementation of BPF LDX/STX instructions on arm64. Although
arm64 ldr/str immediate is available in pre-index, post-index and
unsigned offset forms, the unsigned offset form is sufficient for BPF,
so this patch only adds this type.

Signed-off-by: Xu Kuohai <xukuohai@huawei.com>
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
Link: https://lore.kernel.org/bpf/20220321152852.2334294-2-xukuohai@huawei.com
arch/arm64/include/asm/insn.h
arch/arm64/lib/insn.c