f2fs: refactor next blk selection
authorChristoph Hellwig <hch@lst.de>
Thu, 19 Jan 2023 06:36:24 +0000 (07:36 +0100)
committerJaegeuk Kim <jaegeuk@kernel.org>
Thu, 2 Feb 2023 21:37:16 +0000 (13:37 -0800)
commit4a2095887340e75dfb07575950fcdb7fbcbec64b
tree05ee0608be9a9d6aa2e498ae1f5f065f28e0207b
parentdede3525edbff6e6244668f81d66a48105d3e43b
f2fs: refactor next blk selection

Remove __refresh_next_blkoff by opencoding the SSR vs LFS segment check
in the only caller, and then add helpers for SSR block selection and
blkoff randomization instead.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Chao Yu <chao@kernel.org>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
fs/f2fs/segment.c