mirror of
https://github.com/freebsd/freebsd-src
synced 2024-09-22 17:54:52 +00:00
Add a comment documenting a race condition in vm_fault(): Specifically, a
modification is made to the vm_map while only a read lock is held.
This commit is contained in:
parent
91e007dc70
commit
ff8f4ebe22
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=94981
|
@ -258,6 +258,9 @@ RetryFault:;
|
|||
* If we don't COW now, on a user wire, the user will never
|
||||
* be able to write to the mapping. If we don't make this
|
||||
* restriction, the bookkeeping would be nearly impossible.
|
||||
*
|
||||
* XXX The following assignment modifies the map without
|
||||
* holding a write lock on it.
|
||||
*/
|
||||
if ((fs.entry->protection & VM_PROT_WRITE) == 0)
|
||||
fs.entry->max_protection &= ~VM_PROT_WRITE;
|
||||
|
|
Loading…
Reference in a new issue