Whamcloud - gitweb
libext2fs: add the EXT2FS_LINK_APPEND flag to ext2fs_link()
authorTheodore Ts'o <tytso@mit.edu>
Tue, 20 May 2025 02:07:55 +0000 (22:07 -0400)
committerTheodore Ts'o <tytso@mit.edu>
Wed, 21 May 2025 14:47:15 +0000 (10:47 -0400)
commit53aa6c54224f545756da312e8756576dbaabe08a
tree624b2ebf4b6d01e8699a25d79bf7961acc2d80b4
parentb61f182b2de1ea75cff935037883ba1a8c7db623
libext2fs: add the EXT2FS_LINK_APPEND flag to ext2fs_link()

Add a flag which only tries to add the new directory entry to the last
block in the directory.  This is helpful avoids mke2fs -d offering
from an O(n**2) performance bottleneck when adding a large number of
files to a directory.

Signed-off-by: Theodore Ts'o <tytso@mit.edu>
lib/ext2fs/ext2fs.h
lib/ext2fs/link.c