missing_syscall: mandate __NR_memfd_create

Follow-up for 6db5a6e799

For basic system functionality we require memfd nowadays,
so fail the build if syscall number not available.
This commit is contained in:
Mike Yuan
2025-01-02 20:32:51 +01:00
parent 04e2bd63b6
commit aad028e187

View File

@@ -80,12 +80,7 @@ static inline int missing_ioprio_set(int which, int who, int ioprio) {
#if !HAVE_MEMFD_CREATE
static inline int missing_memfd_create(const char *name, unsigned int flags) {
# ifdef __NR_memfd_create
return syscall(__NR_memfd_create, name, flags);
# else
errno = ENOSYS;
return -1;
# endif
}
# define memfd_create missing_memfd_create