On Thu, Apr 11, 2024 at 02:26:09PM -0400, cel@xxxxxxxxxx wrote: > From: Chuck Lever <chuck.lever@xxxxxxxxxx> > > The existing code in shmem_rename2() allocates a fresh directory > offset value when renaming over an existing destination entry. User > space does not expect this behavior. In particular, applications > that rename while walking a directory can loop indefinitely because > they never reach the end of the directory. > > The first patch in this series corrects that problem, which exists > in v6.6 - current. The second patch is a clean-up and can be deferred > until v6.10. > > Chuck Lever (2): > shmem: Fix shmem_rename2() > libfs: Clean up the simple_offset API > > fs/libfs.c | 89 ++++++++++++++++++++++++++++++++++------------ > include/linux/fs.h | 10 +++--- > mm/shmem.c | 17 +++++---- > 3 files changed, 81 insertions(+), 35 deletions(-) A cursory pass with fstests seemed to work fine, but a number of tests in the git regression suite are failing. Please feel free to send review comments, but do not merge this series yet. -- Chuck Lever