Skip to content
Commit 08c19b24 authored by Alexandru Elisei's avatar Alexandru Elisei Committed by Andrew Jones
Browse files

lib: arm/arm64: Refuse to disable the MMU with non-identity stack pointer



When the MMU is off, all addresses are physical addresses. If the stack
pointer is not an identity mapped address (the virtual address is not the
same as the physical address), then we end up trying to access an invalid
memory region. This can happen if we call mmu_disable from a secondary CPU,
which has its stack allocated from the vmalloc region.

Reviewed-by: Andrew Jones's avatarAndrew Jones <drjones@redhat.com>
Signed-off-by: Alexandru Elisei's avatarAlexandru Elisei <alexandru.elisei@arm.com>
Signed-off-by: Andrew Jones's avatarAndrew Jones <drjones@redhat.com>
parent 08ae0906
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment