summaryrefslogtreecommitdiff
path: root/tools/lib/python
diff options
context:
space:
mode:
authorWenjie Qi <qwjhust@gmail.com>2026-10-16 13:44:06 +0800
committerJaegeuk Kim <jaegeuk@kernel.org>2026-10-19 15:32:45 +0000
commite4df12e37300d4e181ae76746ae0fd7f7b92aa36 (patch)
tree3303483dda2aac237b2917ccb9a12b39baf3f8b9 /tools/lib/python
parenta6ede405455106bf42164ec96fd84008c5aabdd9 (diff)
f2fs: refresh pinned allocation boundary after resize
Online shrink updates MAIN_SECS() but leaves resizable_tail_secno and pinned_area_max_secno unchanged. The pinned allocation limit can exceed the new main area when shrinking beyond the reserved tail. Consume the reserved tail by the number of removed sections, clamping it to zero, before refreshing the shared pinned allocation boundary. This preserves the boundary while shrinking within the reservation and limits it to the new main area otherwise, retaining the zoned limit. Save the old tail count and restore it before rolling back the geometry if the final checkpoint fails. Also bound pinned section allocation by the current MAIN_SECS(). Range evacuation temporarily reduces it before moving cursegs, while the cached pinned boundary still describes the old geometry. Otherwise, a pinned curseg can be reallocated into the range being removed. Fixes: c966d29e01bb ("f2fs: support resizable tail section and unify pinned allocation") Suggested-by: Daeho Jeong <daehojeong@google.com> Signed-off-by: Wenjie Qi <qiwenjie@xiaomi.com> Reviewed-by: Daeho Jeong <daehojeong@google.com> Reviewed-by: Chao Yu <chao@kernel.org> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
Diffstat (limited to 'tools/lib/python')
0 files changed, 0 insertions, 0 deletions