android_kernel_xiaomi_sm7250/arch/powerpc/net
Naveen N. Rao aa634dbbee powerpc/bpf: Emit stf barrier instruction sequences for BPF_NOSPEC
upstream commit b7540d62509453263604a155bf2d5f0ed450cba2

Emit similar instruction sequences to commit a048a07d7f
("powerpc/64s: Add support for a store forwarding barrier at kernel
entry/exit") when encountering BPF_NOSPEC.

Mitigations are enabled depending on what the firmware advertises. In
particular, we do not gate these mitigations based on current settings,
just like in x86. Due to this, we don't need to take any action if
mitigations are enabled or disabled at runtime.

Signed-off-by: Naveen N. Rao <naveen.n.rao@linux.vnet.ibm.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/956570cbc191cd41f8274bed48ee757a86dac62a.1633464148.git.naveen.n.rao@linux.vnet.ibm.com
[adjust macros to account for commits 0654186510a40e, 3a181237916310 and ef909ba954145e.
adjust security feature checks to account for commit 84ed26fd00c514]
Signed-off-by: Naveen N. Rao <naveen.n.rao@linux.vnet.ibm.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2021-11-26 11:36:17 +01:00
..
bpf_jit32.h powerpc: bpf: Fix generation of load/store DW instructions 2019-04-03 06:26:21 +02:00
bpf_jit64.h powerpc/bpf: Emit stf barrier instruction sequences for BPF_NOSPEC 2021-11-26 11:36:17 +01:00
bpf_jit_asm.S powerpc: move ASM_CONST and stringify_in_c() into asm-const.h 2018-07-30 22:48:16 +10:00
bpf_jit_comp64.c powerpc/bpf: Emit stf barrier instruction sequences for BPF_NOSPEC 2021-11-26 11:36:17 +01:00
bpf_jit_comp.c powerpc: move ASM_CONST and stringify_in_c() into asm-const.h 2018-07-30 22:48:16 +10:00
bpf_jit.h powerpc/bpf: Validate branch ranges 2021-11-26 11:36:17 +01:00
Makefile powerpc/Makefiles: Convert ifeq to ifdef where possible 2018-08-08 00:32:36 +10:00