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, Dec 9, 9:53 PM
Unknown Object (File)
Wed, Dec 4, 3:21 PM
Unknown Object (File)
Oct 30 2024, 3:43 PM
Unknown Object (File)
Oct 8 2024, 4:52 PM
Unknown Object (File)
Sep 4 2024, 8:29 AM
Unknown Object (File)
Aug 16 2024, 10:18 PM
Unknown Object (File)
Aug 13 2024, 1:37 PM
Unknown Object (File)
Aug 6 2024, 7:28 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