mirror of https://github.com/torvalds/linux.git
btrfs: use super write guard in relocating_repair_kthread()
Link: https://patch.msgid.link/20251104-work-guards-v1-6-5108ac78a171@kernel.org Signed-off-by: Christian Brauner <brauner@kernel.org>
This commit is contained in:
parent
2774bac21f
commit
b7b8aca68e
|
|
@ -8177,12 +8177,12 @@ static int relocating_repair_kthread(void *data)
|
|||
target = cache->start;
|
||||
btrfs_put_block_group(cache);
|
||||
|
||||
sb_start_write(fs_info->sb);
|
||||
guard(super_write)(fs_info->sb);
|
||||
|
||||
if (!btrfs_exclop_start(fs_info, BTRFS_EXCLOP_BALANCE)) {
|
||||
btrfs_info(fs_info,
|
||||
"zoned: skip relocating block group %llu to repair: EBUSY",
|
||||
target);
|
||||
sb_end_write(fs_info->sb);
|
||||
return -EBUSY;
|
||||
}
|
||||
|
||||
|
|
@ -8210,7 +8210,6 @@ static int relocating_repair_kthread(void *data)
|
|||
btrfs_put_block_group(cache);
|
||||
mutex_unlock(&fs_info->reclaim_bgs_lock);
|
||||
btrfs_exclop_finish(fs_info);
|
||||
sb_end_write(fs_info->sb);
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue