Page MenuHomeFreeBSD

Fix fault_type handling in vm_map_lookup().
ClosedPublic

Authored by markj on Dec 4 2019, 8:14 PM.
Tags
None
Referenced Files
F82381158: D22683.diff
Sat, Apr 27, 11:30 PM
Unknown Object (File)
Dec 20 2023, 8:26 AM
Unknown Object (File)
Nov 10 2023, 2:36 AM
Unknown Object (File)
Nov 1 2023, 9:54 AM
Unknown Object (File)
Oct 28 2023, 11:07 AM
Unknown Object (File)
Oct 12 2023, 12:52 AM
Unknown Object (File)
Oct 9 2023, 1:21 AM
Unknown Object (File)
Sep 30 2023, 7:06 PM
Subscribers

Details

Summary

Suppose that the map entry is wired, so that we later assign
fault_type = entry->protection. Suppose further that we jump back to
RetryLookup. Then fault_type will no longer contain the original
fault protection mask.

I think this is mostly harmless from a correctness standpoint. We end
up with a fault_type that is a superset of its correct value. We may
trigger a copy-on-write update to the entry while handling a read fault,
or we may end up returning KERN_PROTECTION_FAILURE for a fault that
should have succeeded if the entry protections change while the map lock
was dropped.

Submitted by: Wuyang Chung <wuyang.chung1@gmail.com>

Diff Detail

Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 27963
Build 26129: arc lint + arc unit