On Thu, Feb 24, 2022 at 02:15:58AM +0000, Naohiro Aota wrote: > On Wed, Feb 23, 2022 at 11:31:07AM +0100, David Sterba wrote: > > On Fri, Feb 18, 2022 at 01:14:19PM +0900, Naohiro Aota wrote: > It looks like this occurs when the balance is resumed. We also need > sb_{start,end}_write around btrfs_balance() in balance_kthred(). > > I guess we can cause a hang if we resume the balance and freeze the FS > at the same time. We need to fix the missing write protection before the asserts can be added, so I'll delete them from this patch and will submit the helpers patch once after we have fixed all.