Page MenuHomeFreeBSD

Add some more checking to the page fault handler.
ClosedPublic

Authored by markj on Dec 14 2018, 8:07 PM.
Tags
None
Referenced Files
F167973161: D18561.diff
Tue, Aug 25, 5:07 PM
F167852993: D18561.id52021.diff
Tue, Aug 25, 12:38 AM
F167852992: D18561.id52030.diff
Tue, Aug 25, 12:38 AM
F167852955: D18561.diff
Tue, Aug 25, 12:38 AM
Unknown Object (File)
Mon, Aug 24, 2:21 AM
Unknown Object (File)
Tue, Aug 18, 8:26 PM
Unknown Object (File)
Tue, Aug 11, 4:43 PM
Unknown Object (File)
Tue, Aug 11, 5:39 AM
Subscribers

Details

Summary
  • Rename "lower" to "usermode" to make its meaning more clear. I am happy to revert this part if there is some reason "lower" is a better name, but I don't see one.
  • Panic immediately if witness says we're holding non-sleepable locks. This helps ensure that we don't recurse on the pmap lock in pmap_fault_fixup().
  • Panic if the kernel faults on a user address without setting an onfault handler.
  • Panic if the fault occurred in a critical section or interrupt handler, like we do on other platforms.
  • Use VM_MAX_USER_ADDRESS instead of checking the high bit in the fault address. I think the previous trick is too magical and makes it harder to change the address space layout if or when we decide to do so (e.g., switching to SV48).
  • Fix a few style issues.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable