Re: [PATCH] ext4: add ext4_sb_bread_nofail() helper function for ext4_free_branches()

From: Theodore Ts'o

Date: Fri Sep 26 2025 - 17:48:30 EST



On Thu, 21 Aug 2025 21:38:57 +0800, libaokun@xxxxxxxxxxxxxxx wrote:
> The implicit __GFP_NOFAIL flag in ext4_sb_bread() was removed in commit
> 8a83ac54940d ("ext4: call bdev_getblk() from sb_getblk_gfp()"), meaning
> the function can now fail under memory pressure.
>
> Most callers of ext4_sb_bread() propagate the error to userspace and do not
> remount the filesystem read-only. However, ext4_free_branches() handles
> ext4_sb_bread() failure by remounting the filesystem read-only.
>
> [...]

Applied, thanks!

[1/1] ext4: add ext4_sb_bread_nofail() helper function for ext4_free_branches()
commit: d8b90e6387a74bcb1714c8d1e6a782ff709de9a9

Best regards,
--
Theodore Ts'o <tytso@xxxxxxx>