Yes, I don't like that either, but it is for fstat(1) support. timerfd and eventfd were not added to fstat... An alternative is to put it in a separate header file or copy it. christos > On Jul 10, 2023, at 8:14 AM, Jason Thorpe <thorpej%me.com@localhost> wrote: > > It’s great to see this land, but “struct memfd” does not appear to be needed in <sys/mman.h>. I would suggest moving it to sys_memfd.c. > >> On Jul 9, 2023, at 7:31 PM, Christos Zoulas <christos%netbsd.org@localhost> wrote: >> >> Module Name: src >> Committed By: christos >> Date: Mon Jul 10 02:31:55 UTC 2023 >> >> Modified Files: >> src/distrib/sets/lists/comp: mi >> src/lib/libc/sys: Makefile.inc fcntl.2 >> src/sys/compat/linux/arch/amd64: syscalls.master >> src/sys/compat/linux/common: linux_fcntl.h linux_file.c linux_misc.c >> linux_sysctl.c >> src/sys/kern: sys_descrip.c vfs_syscalls.c vfs_vnops.c >> src/sys/sys: fcntl.h file.h mman.h >> src/usr.bin/fstat: fstat.c misc.c >> Added Files: >> src/lib/libc/sys: memfd_create.2 >> src/sys/kern: sys_memfd.c >> >> Log Message: >> Add memfd_create(2) from GSoC 2023 by Theodore Preduta >> >> >> To generate a diff of this commit: >> cvs rdiff -u -r1.2436 -r1.2437 src/distrib/sets/lists/comp/mi >> cvs rdiff -u -r1.250 -r1.251 src/lib/libc/sys/Makefile.inc >> cvs rdiff -u -r1.49 -r1.50 src/lib/libc/sys/fcntl.2 >> cvs rdiff -u -r0 -r1.1 src/lib/libc/sys/memfd_create.2 >> cvs rdiff -u -r1.67 -r1.68 src/sys/compat/linux/arch/amd64/syscalls.master >> cvs rdiff -u -r1.20 -r1.21 src/sys/compat/linux/common/linux_fcntl.h >> cvs rdiff -u -r1.122 -r1.123 src/sys/compat/linux/common/linux_file.c >> cvs rdiff -u -r1.256 -r1.257 src/sys/compat/linux/common/linux_misc.c >> cvs rdiff -u -r1.47 -r1.48 src/sys/compat/linux/common/linux_sysctl.c >> cvs rdiff -u -r1.47 -r1.48 src/sys/kern/sys_descrip.c >> cvs rdiff -u -r0 -r1.1 src/sys/kern/sys_memfd.c >> cvs rdiff -u -r1.559 -r1.560 src/sys/kern/vfs_syscalls.c >> cvs rdiff -u -r1.241 -r1.242 src/sys/kern/vfs_vnops.c >> cvs rdiff -u -r1.54 -r1.55 src/sys/sys/fcntl.h >> cvs rdiff -u -r1.92 -r1.93 src/sys/sys/file.h >> cvs rdiff -u -r1.62 -r1.63 src/sys/sys/mman.h >> cvs rdiff -u -r1.117 -r1.118 src/usr.bin/fstat/fstat.c >> cvs rdiff -u -r1.24 -r1.25 src/usr.bin/fstat/misc.c >> >> Please note that diffs are not public domain; they are subject to the >> copyright notices on the relevant files. >> > > -- thorpej
Attachment:
signature.asc
Description: Message signed with OpenPGP