c936cb6f | 19-May-2022 |
Matthew Dillon <dillon@apollo.backplane.com> |
kernel - Implement mlockall() properly
* Implement mlockall()'s MCL_CURRENT, and generalaly reimplement mlockall() using linux-like expectations. This generally means that the system will do a
kernel - Implement mlockall() properly
* Implement mlockall()'s MCL_CURRENT, and generalaly reimplement mlockall() using linux-like expectations. This generally means that the system will do a best-effort to allocate and lock the memory associated with the process's address space.
* Prior semantics which disallowed protection changes on locked memory have been removed. Modern applications assume that protection changes will work on locked memory, even if it would force a fault.
* As with linux, some license is taken and mlockall() will only force fault any copy-on-write flagged anonymous pages at the time of the call. It will not force a copy-on-write operation on unmodified file-backed pages that have been mapped MAP_PRIVATE, but not yet modified (still represent the file's actual content). Nor will it force-fault the parent process's pages when the parent issues a fork() (which forces all anonymous pages in both the parent and child to become copy-on-write).
Such pages can still take a write-fault and be COWd. The resulting newly allocated page will be wired as expected.
Submitted-by: tuxillo Testing-by: tuxillo, dillon
show more ...
|
ee5a5918 | 14-Sep-2021 |
Sascha Wildner <saw@online.de> |
Some additions and fixes related to fdatasync(2) and posix_fallocate(2).
* Fix a small issue in VOP_FDATASYNC()'s definition in <sys/vfsops.h>.
* Mention fdatasync() in fsync.2 (this basically sync
Some additions and fixes related to fdatasync(2) and posix_fallocate(2).
* Fix a small issue in VOP_FDATASYNC()'s definition in <sys/vfsops.h>.
* Mention fdatasync() in fsync.2 (this basically syncs that manual page with FreeBSD, with a few adjustments).
* Add a manual page for posix_fallocate() (from FreeBSD, with a few adjustments).
* Mention fdatasync() in the list of reentrant functions in sigaction.2.
* In pthread_testcancel.3, mention fdatasync() in the list of functions for which a cancellation point will occur.
* Mention VOP_FDATASYNC() in VOP_FSYNC.9 (partly taken from FreeBSD).
* Remove a compatibility define in the fsstress tool.
Thanks to tkusumi for reviewing.
show more ...
|