[PATCH 0/5] Backport statx(..., NULL, AT_EMPTY_PATH, ...)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Commit 0ef625bba6fb ("vfs: support statx(..., NULL, AT_EMPTY_PATH,
...)") added support for passing in NULL when AT_EMPTY_PATH is given,
improving performance when statx is used for fetching stat informantion
from a given fd, which is especially important for 32-bit platforms.
This commit also improved the performance when an empty string is given
by short-circuiting the handling of such paths.

This series is based on the commits in the Linus’ tree. Modifications
are applied to vfs_statx_path(). In the original patch, vfs_statx_path()
was created to warp around the call to vfs_getattr() after
filename_lookup() in vfs_statx(). Since the coresponding code is
different in 6.1, the content of vfs_statx_path() is modified to match
this. The original patch also moved path_mounted() from namespace.c to
internal.h, which is not applicable for 6.1 since it has not been
introduced before 6.5.

Tested-by: Xi Ruoyao <xry111@xxxxxxxxxxx>
Signed-off-by: Miao Wang <shankerwangmiao@xxxxxxxxx>
---
Christian Brauner (3):
      file: add fd_raw cleanup class
      fs: new helper vfs_empty_path()
      stat: use vfs_empty_path() helper

Linus Torvalds (1):
      vfs: mostly undo glibc turning 'fstat()' into 'fstatat(AT_EMPTY_PATH)'

Mateusz Guzik (1):
      vfs: support statx(..., NULL, AT_EMPTY_PATH, ...)

 fs/internal.h        |   2 +
 fs/stat.c            | 101 ++++++++++++++++++++++++++++++++++++++++-----------
 include/linux/file.h |   1 +
 include/linux/fs.h   |  17 +++++++++
 4 files changed, 99 insertions(+), 22 deletions(-)
---
base-commit: 5f55cad62cc9d8d29dd3556e0243b14355725ffb
change-id: 20240918-statx-stable-linux-6-1-y-37e6ca691c9b

Best regards,
-- 
Miao Wang <shankerwangmiao@xxxxxxxxx>






[Index of Archives]     [Linux Kernel]     [Kernel Development Newbies]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite Hiking]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux