summaryrefslogtreecommitdiffstats
path: root/include/uapi/asm-generic/unistd.h
diff options
context:
space:
mode:
authorJan Kara <jack@suse.cz>2021-05-25 16:07:48 +0200
committerJan Kara <jack@suse.cz>2021-06-07 12:11:24 +0200
commit64c2c2c62f92339b176ea24403d8db16db36f9e6 (patch)
treedbe1ee81ca112e1b0f6e7c971fc29e6d0f217c0e /include/uapi/asm-generic/unistd.h
parent21e4e15a846f86643a43c291cbed5dca3639fc2b (diff)
downloadlinux-64c2c2c62f92339b176ea24403d8db16db36f9e6.tar.bz2
quota: Change quotactl_path() systcall to an fd-based one
Some users have pointed out that path-based syscalls are problematic in some environments and at least directory fd argument and possibly also resolve flags are desirable for such syscalls. Rather than reimplementing all details of pathname lookup and following where it may eventually evolve, let's go for full file descriptor based syscall similar to how ioctl(2) works since the beginning. Managing of quotas isn't performance sensitive so the extra overhead of open does not matter and we are able to consume O_PATH descriptors as well which makes open cheap anyway. Also for frequent operations (such as retrieving usage information for all users) we can reuse single fd and in fact get even better performance as well as avoiding races with possible remounts etc. Tested-by: Sascha Hauer <s.hauer@pengutronix.de> Acked-by: Christian Brauner <christian.brauner@ubuntu.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Jan Kara <jack@suse.cz>
Diffstat (limited to 'include/uapi/asm-generic/unistd.h')
-rw-r--r--include/uapi/asm-generic/unistd.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/include/uapi/asm-generic/unistd.h b/include/uapi/asm-generic/unistd.h
index 6de5a7fc066b..f211961ce1da 100644
--- a/include/uapi/asm-generic/unistd.h
+++ b/include/uapi/asm-generic/unistd.h
@@ -863,8 +863,8 @@ __SYSCALL(__NR_process_madvise, sys_process_madvise)
__SC_COMP(__NR_epoll_pwait2, sys_epoll_pwait2, compat_sys_epoll_pwait2)
#define __NR_mount_setattr 442
__SYSCALL(__NR_mount_setattr, sys_mount_setattr)
-#define __NR_quotactl_path 443
-__SYSCALL(__NR_quotactl_path, sys_quotactl_path)
+#define __NR_quotactl_fd 443
+__SYSCALL(__NR_quotactl_fd, sys_quotactl_fd)
#define __NR_landlock_create_ruleset 444
__SYSCALL(__NR_landlock_create_ruleset, sys_landlock_create_ruleset)