@@ -111,6 +111,25 @@ namespace, so `STATMOUNT_MNT_POINT` and `STATMOUNT_MNT_NS_ID` are unset in
111111needing the mount ID, which is particularly useful for detached or unmounted
112112mounts.
113113
114+ ### ` AT_EMPTY_PATH ` support ` for unlinkat() `
115+
116+ ** Use-Case:** When dealing with files/directories, allow passing
117+ around only a file descriptor without having to keep the path around
118+ to be able to unlink the file/directory.
119+
120+ ### ` AT_EMPTY_PATH ` support for ` openat() ` and ` openat2() `
121+
122+ To get an operable version of an ` O_PATH ` file descriptors, it is
123+ possible to use ` openat(fd, ".", O_DIRECTORY) ` for directories, but
124+ other files currently require going through
125+ ` open("/proc/<pid>/fd/<nr>") ` which depends on a functioning ` procfs ` .
126+
127+ FreeBSD already has ` O_EMPTY_PATH ` for ` openat ` , while ` fstatat ` and
128+ similar functions have ` AT_EMPTY_PATH ` .
129+
130+ ** Use-Case:** When dealing with ` O_PATH ` file descriptors, allow
131+ re-opening an operable version without the need of ` procfs ` .
132+
114133---
115134
116135### TODO
@@ -500,12 +519,6 @@ An initial group internal RFC exists in
500519(https://github.com/quitschbo/linux/tree/devcg_guard_rfc ).
501520See commit message for more implementation specific details.
502521
503- ### ` AT_EMPTY_PATH ` support ` for unlinkat() `
504-
505- ** Use-Case:** When dealing with files/directories, allow passing
506- around only a file descriptor without having to keep the path around
507- to be able to unlink the file/directory.
508-
509522### Race-free mounting of block devices
510523
511524Introduce a new struct to ` fsconfig() ` as an alternative to the
@@ -697,19 +710,6 @@ tells userspace that there was an fd, but it was not allowed through.
697710
698711** Use-Case:** Any code that wants to use ` SCM_RIGHTS ` properly.
699712
700- ### ` AT_EMPTY_PATH ` support for ` openat() ` and ` openat2() `
701-
702- To get an operable version of an ` O_PATH ` file descriptors, it is
703- possible to use ` openat(fd, ".", O_DIRECTORY) ` for directories, but
704- other files currently require going through
705- ` open("/proc/<pid>/fd/<nr>") ` which depends on a functioning ` procfs ` .
706-
707- FreeBSD already has ` O_EMPTY_PATH ` for ` openat ` , while ` fstatat ` and
708- similar functions have ` AT_EMPTY_PATH ` .
709-
710- ** Use-Case:** When dealing with ` O_PATH ` file descriptors, allow
711- re-opening an operable version without the need of ` procfs ` .
712-
713713---
714714
715715## Finished Items
0 commit comments