Page MenuHomeFreeBSD

arm: Clear TTBCR before enabling the MMU
ClosedPublic

Authored by markj on Aug 4 2022, 1:36 PM.
Tags
None
Referenced Files
Unknown Object (File)
Mon, Jan 13, 3:21 PM
Unknown Object (File)
Fri, Jan 3, 9:18 PM
Unknown Object (File)
Dec 22 2024, 7:11 PM
Unknown Object (File)
Dec 21 2024, 4:26 PM
Unknown Object (File)
Dec 19 2024, 9:32 PM
Unknown Object (File)
Dec 17 2024, 4:56 PM
Unknown Object (File)
Dec 17 2024, 4:24 PM
Unknown Object (File)
Dec 17 2024, 11:56 AM
Subscribers

Details

Summary

Upon reset, this register is supposed to have a value of zero. But when
booting certain v7 CPUs in QEMU, we enter the kernel with several bits
set, including the EAE bit, which enables ARM's PAE extension. I'm not
sure if QEMU is setting, or the uboot loader. Because we don't
implement that extension and use regular 32-bit page tables, the kernel
hangs after enabling the MMU.

Just clear everything in TTBCR before enabling the MMU. FreeBSD doesn't
toggle anything in that register, and a look through the flag
definitions suggests that setting everything to zero is what we want.

PR: 251187

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable