Re: [PATCH linux-next RESEND] exfat: check the emergency state in exfat_writeback_range()

From: Namjae Jeon

Date: Tue Nov 24 2026 - 18:10:05 EST


On Wed, Nov 25, 2026 at 2:47 AM Sasha Levin <sashal@xxxxxxxxxx> wrote:
>
> Since next-20261119 the merge of the vfs-brauner tree with the exfat
> tree drops an error check from exfat writeback.
>
> Commit 788f21d1f192 ("exfat: don't set SB_RDONLY after filesystem
> errors") in the vfs-brauner tree switches the write side shutdown checks
> to exfat_emergency_state(), which also fails after a filesystem error.
> One of them is in exfat_writepages(). Commit b900c61a3f21 ("exfat: drain
> dirty pages after forced shutdown") in the exfat tree moves that check
> from exfat_writepages() into exfat_writeback_range().
>
> The merge takes the exfat side of exfat_writepages() but keeps
> exfat_forced_shutdown() in exfat_writeback_range(). So after an error
> with errors=remount-ro, writeback keeps writing dirty data to the disk
> instead of dropping it as the vfs-brauner commit intends.
>
> Use exfat_emergency_state() in exfat_writeback_range(), as
> next-20261118 did.
>
> Fixes: ce0505a38004 ("Merge branch 'vfs.all' of https://git.kernel.org/pub/scm/linux/kernel/git/vfs/vfs.git";)
> Link: https://lore.kernel.org/all/20261120003508.2135492-1-sashal@xxxxxxxxxx/
> Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>
Looks good to me:)
Thanks!