Move internal-to-'vfs_default.c' get_next_dirent() to 'vfs_vnops.c' and export
it for use by other parts of the VFS. This is a preparatory change for using it
in vfs_emptydir().
No functional change.
Differential D39755
vfs: Export get_next_dirent() as vn_dir_next_dirent() olce on Apr 21 2023, 9:14 PM. Authored by Tags None Referenced Files
Subscribers
Details
Move internal-to-'vfs_default.c' get_next_dirent() to 'vfs_vnops.c' and export No functional change.
Diff Detail
Event TimelineComment Actions The patch definitely needs a split into several. An immediate candidate is the code refactoring without a change in behavior, then introduce the fixes on top of it.
Comment Actions
To raise awareness: https://lists.freebsd.org/archives/freebsd-fs/2023-April/002153.html Comment Actions Keep just the get_next_dirent() => vfs_next_dirent() refactoring And update according to feedback. Comment Actions I've also changed a bit the initial diff so as to minimize differences (order of declarations). (@kib You said that uint_fast16_t is not fast. While I understand the requested change from an aesthetic point of view, I don't think uint_fast16_t is not fast, it is in fact as fast as int, since it expands to __uint32_t. But yes, it's not faster than an int, which you probably meant?) Comment Actions Can we split it even more? The move of vfs_next_dirent() and its rename, then the changes you do over the moved code.
|