freebsd-src/tests/sys/posixshm
Brooks Davis a9174861ea posixshm largepage_mmap: fix a racy test
You can't ever safely map a single page and then map a superpage sized
mapping over it with MAP_FIXED.  Even in a single-threaded program, ASLR
might mean you land too close to another mapping and on CheriBSD we
don't allow the initial reservation to grow because doing so requires
program changes that are hard to automate.

To avoid this, map the entire region we want to use upfront.

Reviewed by:	markj
Obtained from:	CheriBSD
Sponsored by:	DARPA
Differential Revision:	https://reviews.freebsd.org/D43282
2024-01-03 16:39:53 +00:00
..
Makefile Remove $FreeBSD$: one-line sh pattern 2023-08-16 11:55:03 -06:00
Makefile.depend Remove $FreeBSD$: one-line sh pattern 2023-08-16 11:55:03 -06:00
memfd_test.c Remove $FreeBSD$: one-line .c pattern 2023-08-16 11:54:42 -06:00
posixshm_test.c posixshm largepage_mmap: fix a racy test 2024-01-03 16:39:53 +00:00