powerpc/fsl: Enable runtime patching if nospectre_v2 boot arg is used
commit 3bc8ea8603ae4c1e09aca8de229ad38b8091fcb3 upstream. If the user choses not to use the mitigations, replace the code sequence with nops. Signed-off-by: Diana Craciun <diana.craciun@nxp.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
6d9d895ee2
commit
804cc27e08
@ -323,6 +323,7 @@ void __init setup_arch(char **cmdline_p)
|
|||||||
if ( ppc_md.progress ) ppc_md.progress("arch: exit", 0x3eab);
|
if ( ppc_md.progress ) ppc_md.progress("arch: exit", 0x3eab);
|
||||||
|
|
||||||
setup_barrier_nospec();
|
setup_barrier_nospec();
|
||||||
|
setup_spectre_v2();
|
||||||
|
|
||||||
paging_init();
|
paging_init();
|
||||||
|
|
||||||
|
@ -737,6 +737,7 @@ void __init setup_arch(char **cmdline_p)
|
|||||||
ppc_md.setup_arch();
|
ppc_md.setup_arch();
|
||||||
|
|
||||||
setup_barrier_nospec();
|
setup_barrier_nospec();
|
||||||
|
setup_spectre_v2();
|
||||||
|
|
||||||
paging_init();
|
paging_init();
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user