mirror of
https://github.com/freebsd/freebsd-src.git
synced 2026-10-28 11:25:21 +01:00
Linux returns EFAULT when the range to be remapped is not mapped at all, and ENOMEM only when it is mapped but cannot be grown in place. Callers depend on that distinction: musl's pthread_getattr_np() measures the main thread stack by growing a one page mapping and retries while errno is ENOMEM. Returning ENOMEM for every growth request makes that loop spin forever. PR: 299835 MFC after: 1 week