Re: [PATCH] btrfs: wait between incomplete batch allocations

From: David Sterba
Date: Thu Apr 07 2022 - 11:02:43 EST

On Wed, Apr 06, 2022 at 02:24:18PM -0400, Sweet Tea Dorminy wrote:
> When allocating memory in a loop, each iteration should call
> memalloc_retry_wait() in order to prevent starving memory-freeing
> processes (and to mark where allcoation loops are). ext4, f2fs, and xfs
> all use this function at present for their allocation loops; btrfs ought
> also.
> The bulk page allocation is the only place in btrfs with an allocation
> retry loop, so add an appropriate call to it.
> Suggested-by: David Sterba <dsterba@xxxxxxx>
> Signed-off-by: Sweet Tea Dorminy <sweettea-kernel@xxxxxxxxxx>

Added to misc-next, thanks.