powerpc fixes for 5.18 #5
- Fix KVM PR on 32-bit, which was broken by some MMU code refactoring. Thanks to: Alexander Graf, Matt Evans. -----BEGIN PGP SIGNATURE----- iQJHBAABCAAxFiEEJFGtCPCthwEv2Y/bUevqPMjhpYAFAmKA5psTHG1wZUBlbGxl cm1hbi5pZC5hdQAKCRBR6+o8yOGlgHnjD/4/YU1y7XU/h0RjYwiKfVlVbIFXjFkB xMgijdI87SCSU94O8h/7WqhVEwfS8dM+jBa9F4Ky6nOqLMnAE1B/zPzE1P9KAvLl kilLQ9Wl/VhR+PqD62UofevhwsPA+neLkKKAfWMjMvRp4wHvAk18ILNAxhq4D3hP 7KyK4sQntBVwnObWuopJoEeKuoDFa/0VRr/VC29CKowWRzIgwo/OVBBzAxrYUT0g HjhNO4zPyJ6mxanO24cWokXekxWKU07NvIeU4dP6nOreUJvfxfpmEbhsxrC8YLo1 Fy7MWGQLwvq8D7UHeWPh+OOhIuPQDIDseXaW3m4mkLmMqxy5Y+D2aCyto/Rl8B97 yPqWmcYjdLoac0CS3l+CQUcCTc5YPZ7zDkPkrKdvutyrPqgTkTgRFWrOIlLJtV7f H++hVj0RMiFyjPPAUWNtByKwdwq+lAN1OqrtrksWhX6aSZJIgcR0pUQM1YFqDQU1 IOErcs2JjrwxYOGDIgB6zE/UNClDaoS5J0p4utgtnRyQB1VHnUqv8+3wP3+7ATYG I7smX7ce/RRtLvJTXIgNc406ibj/TOW9icneBZ9m1+2WWcBb4JpUMiBBwyhCsn7x xHzJLof4LLKxCdjalBb8w7mQ4yO5i9IHrOEgb/TD3P5MXjBhWZOljky+j7NUXzgb 9IFdAGOPnXwcFw== =HVUs -----END PGP SIGNATURE----- Merge tag 'powerpc-5.18-5' of git://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux Pull powerpc fix from Michael Ellerman: - Fix KVM PR on 32-bit, which was broken by some MMU code refactoring. Thanks to: Alexander Graf, and Matt Evans. * tag 'powerpc-5.18-5' of git://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux: KVM: PPC: Book3S PR: Enable MSR_DR for switch_mmu_context()
This commit is contained in:
commit
bc403203d6
@ -122,11 +122,27 @@
|
|||||||
|
|
||||||
/* 0x0 - 0xb */
|
/* 0x0 - 0xb */
|
||||||
|
|
||||||
/* 'current->mm' needs to be in r4 */
|
/* switch_mmu_context() needs paging, let's enable it */
|
||||||
tophys(r4, r2)
|
mfmsr r9
|
||||||
lwz r4, MM(r4)
|
ori r11, r9, MSR_DR
|
||||||
tophys(r4, r4)
|
mtmsr r11
|
||||||
/* This only clobbers r0, r3, r4 and r5 */
|
sync
|
||||||
|
|
||||||
|
/* switch_mmu_context() clobbers r12, rescue it */
|
||||||
|
SAVE_GPR(12, r1)
|
||||||
|
|
||||||
|
/* Calling switch_mmu_context(<inv>, current->mm, <inv>); */
|
||||||
|
lwz r4, MM(r2)
|
||||||
bl switch_mmu_context
|
bl switch_mmu_context
|
||||||
|
|
||||||
|
/* restore r12 */
|
||||||
|
REST_GPR(12, r1)
|
||||||
|
|
||||||
|
/* Disable paging again */
|
||||||
|
mfmsr r9
|
||||||
|
li r6, MSR_DR
|
||||||
|
andc r9, r9, r6
|
||||||
|
mtmsr r9
|
||||||
|
sync
|
||||||
|
|
||||||
.endm
|
.endm
|
||||||
|
Loading…
Reference in New Issue
Block a user