Author: kevans Date: Thu Sep 10 17:23:30 2020 New Revision: 365593 URL: https://svnweb.freebsd.org/changeset/base/365593
Log: Fix memfd_create tests after r365524 r365524 did accidentally invert this check that sets SHM_LARGEPAGE, leading non-hugetlb memfd as unconfigured largepage shm and thus test failures when we try to ftruncate or write to them. PR: 249236 Discussed with: kib Modified: head/lib/libc/sys/shm_open.c Modified: head/lib/libc/sys/shm_open.c ============================================================================== --- head/lib/libc/sys/shm_open.c Thu Sep 10 17:15:44 2020 (r365592) +++ head/lib/libc/sys/shm_open.c Thu Sep 10 17:23:30 2020 (r365593) @@ -136,7 +136,7 @@ memfd_create(const char *name, unsigned int flags) oflags |= O_CLOEXEC; if ((flags & MFD_ALLOW_SEALING) != 0) shmflags |= SHM_ALLOW_SEALING; - if ((flags & MFD_HUGETLB) == 0) + if ((flags & MFD_HUGETLB) != 0) shmflags |= SHM_LARGEPAGE; fd = __sys_shm_open2(SHM_ANON, oflags, 0, shmflags, memfd_name); if (fd == -1 || (flags & MFD_HUGETLB) == 0) _______________________________________________ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"