|
@@ -25,6 +25,8 @@
|
|
#include <asm/hwcap.h>
|
|
#include <asm/hwcap.h>
|
|
#include <asm/pgtable-hwdef.h>
|
|
#include <asm/pgtable-hwdef.h>
|
|
#include <asm/pgtable.h>
|
|
#include <asm/pgtable.h>
|
|
|
|
+#include <asm/cpufeature.h>
|
|
|
|
+#include <asm/alternative.h>
|
|
|
|
|
|
#include "proc-macros.S"
|
|
#include "proc-macros.S"
|
|
|
|
|
|
@@ -137,7 +139,17 @@ ENTRY(cpu_do_switch_mm)
|
|
bfi x0, x1, #48, #16 // set the ASID
|
|
bfi x0, x1, #48, #16 // set the ASID
|
|
msr ttbr0_el1, x0 // set TTBR0
|
|
msr ttbr0_el1, x0 // set TTBR0
|
|
isb
|
|
isb
|
|
|
|
+alternative_if_not ARM64_WORKAROUND_CAVIUM_27456
|
|
ret
|
|
ret
|
|
|
|
+ nop
|
|
|
|
+ nop
|
|
|
|
+ nop
|
|
|
|
+alternative_else
|
|
|
|
+ ic iallu
|
|
|
|
+ dsb nsh
|
|
|
|
+ isb
|
|
|
|
+ ret
|
|
|
|
+alternative_endif
|
|
ENDPROC(cpu_do_switch_mm)
|
|
ENDPROC(cpu_do_switch_mm)
|
|
|
|
|
|
.pushsection ".idmap.text", "ax"
|
|
.pushsection ".idmap.text", "ax"
|