btrfs: fixes for defrag_check_next_extent()
Get series with b4
b4 am [email protected]Versions newest first · linked by author and title
- v4 Latest3 patches 9 repliesIn review
- v31 of 3 patches 4 repliesSuperseded
- v21 patch 1 replySuperseded
Earlier versions · 1
| Version | Posted | Patches | Replies | Status |
|---|---|---|---|---|
| v1 | 1 patch | 2 replies | Superseded |
Changes in v4 from the cover letter
- Fix the @em usage which should be @next.
As it will fail the submitted test case.
Patches in v4 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/3 | btrfs: defrag: don't try to merge regular extents with preallocated extentsfs/ | +12 | 1 reply | |
| 2/3 | btrfs: defrag: don't defrag extents which is already at its max capacityfs/ | +20 | 2 replies | |
| 3/3 | btrfs: defrag: remove an ambiguous condition for rejectionfs/ | +0 | 0 replies |
Reviews trailers per patch
All 3 patches have a Reviewed-by or Acked-by.
| Patch | Filipe Manana |
|---|---|
| 1/3 | R-b |
| 2/3 | R-b |
| 3/3 | R-b |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [PATCH v4 0/3] btrfs: fixes for defrag_check_next_extent()
That function is reused between older kernels (v5.15) and the refactored defrag code (v5.16+).
However that function has one long existing bugs affecting defrag to handle preallocated range.
And it can not handle compressed extent well neither.
Finally there is an ambiguous check which doesn't make much sense by itself, and can be related by enhanced extent capacity check.
This series will fix all the 3 problem mentioned above.
Changelog:
v2:
- Use @extent_thresh from caller to replace the harded coded threshold Now caller has full control over the extent threshold value.
- Remove the old ambiguous check based on physical address The original check is too specific, only reject extents which are physically adjacent, AND too large.
Since we have correct size check now, and the physically adjacent check is not always a win.
So remove the old check completely.
v3:
- Split the @extent_thresh and physicall adjacent check into other patches
- Simplify the comment
v4:
- Fix the @em usage which should be @next.
As it will fail the submitted test case.
Qu Wenruo (3):
btrfs: defrag: don't try to merge regular extents with preallocated
extents
btrfs: defrag: don't defrag extents which is already at its max
capacity
btrfs: defrag: remove an ambiguous condition for rejection
fs/btrfs/ioctl.c | 35 ++++++++++++++++++++++++++++------- 1 file changed, 28 insertions(+), 7 deletions(-)
Signature · 1 line
2.34.1