|
@@ -139,9 +139,12 @@ ENDPROC(cpu_do_resume)
|
|
*/
|
|
*/
|
|
ENTRY(cpu_do_switch_mm)
|
|
ENTRY(cpu_do_switch_mm)
|
|
pre_ttbr0_update_workaround x0, x2, x3
|
|
pre_ttbr0_update_workaround x0, x2, x3
|
|
|
|
+ mrs x2, ttbr1_el1
|
|
mmid x1, x1 // get mm->context.id
|
|
mmid x1, x1 // get mm->context.id
|
|
- bfi x0, x1, #48, #16 // set the ASID
|
|
|
|
- msr ttbr0_el1, x0 // set TTBR0
|
|
|
|
|
|
+ bfi x2, x1, #48, #16 // set the ASID
|
|
|
|
+ msr ttbr1_el1, x2 // in TTBR1 (since TCR.A1 is set)
|
|
|
|
+ isb
|
|
|
|
+ msr ttbr0_el1, x0 // now update TTBR0
|
|
isb
|
|
isb
|
|
post_ttbr0_update_workaround
|
|
post_ttbr0_update_workaround
|
|
ret
|
|
ret
|
|
@@ -224,7 +227,7 @@ ENTRY(__cpu_setup)
|
|
* both user and kernel.
|
|
* both user and kernel.
|
|
*/
|
|
*/
|
|
ldr x10, =TCR_TxSZ(VA_BITS) | TCR_CACHE_FLAGS | TCR_SMP_FLAGS | \
|
|
ldr x10, =TCR_TxSZ(VA_BITS) | TCR_CACHE_FLAGS | TCR_SMP_FLAGS | \
|
|
- TCR_TG_FLAGS | TCR_ASID16 | TCR_TBI0
|
|
|
|
|
|
+ TCR_TG_FLAGS | TCR_ASID16 | TCR_TBI0 | TCR_A1
|
|
tcr_set_idmap_t0sz x10, x9
|
|
tcr_set_idmap_t0sz x10, x9
|
|
|
|
|
|
/*
|
|
/*
|