在 2026/8/2 19:05, Cole Munz 写道:
As agreed on the v1 thread, the fix and the cleanups are now separate
patches:

- patch 1 is the fix in the v1 shape
- patch 2 makes btrfs_search_slot() release the path on error like
   the kernel version does. That is where the btrfs_size() leak came
   from. Suggested by Qu.
- patch 3 is the dedup Alexey asked about. One helper shared by
   btrfs_readdir() and btrfs_size().

The pending btrfs test suite still passes on top of the readdir
series: 5 passed.

Changes in v3: split the fix from the cleanups. The release moved
into btrfs_search_slot() itself.
Changes in v2: helper shared with btrfs_size() plus the leak fix in
one patch.


Reviewed-by: Qu Wenruo <[email protected]>

Thanks,
Qu

Cole Munz (3):
   fs: btrfs: report file sizes from readdir
   fs: btrfs: release the path when btrfs_search_slot() fails
   fs: btrfs: deduplicate the inode size lookup

  fs/btrfs/btrfs.c    | 77 +++++++++++++++++++++++++++++++--------------
  fs/btrfs/ctree.c    | 16 +++++++---
  fs/btrfs/ctree.h    |  3 +-
  fs/btrfs/dir-item.c |  7 ++++-
  4 files changed, 74 insertions(+), 29 deletions(-)


Reply via email to