Re: [PATCH v2 0/3] btrfs: fix balance NULL derefs and chunk/bg mapping verification

From: ZhengYuan Huang

Date: Mon Mar 23 2026 - 22:56:50 EST


On Tue, Mar 24, 2026 at 1:33 AM David Sterba <dsterba@xxxxxxx> wrote:
> As I understand it you're using some advanced fuzzing tool (patch 1
> mentions runtime fuzzing), so the errors would not normally happen. With
> fuzzing it depends on the capabilities, at runtime it is possible to
> confuse the filesystem so much that sipmle checks can't detect it.
>
> Here checking if block group lookups are ok makes sense in general.
> There are existing checks that seem to be following the same logic like
> in unpin_extent_range().

Thanks for your review.

Yes, we are using an in-house runtime fuzzing tool.
However, after further investigation of this bug, we found that it is
not limited to fuzzing-only scenarios. The issue can be reliably
triggered by using a crafted filesystem image together with normal syscalls.

So this may not be purely a fuzzing artifact, but rather a potential
robustness issue that could be hit in practice.

> This is good, thanks. For simple fixes or cleanups it's fine to
> make a vague reference to the main patch or a "in the previous/followup
> patches".

Thanks for the guidance, I’ll continue to follow this convention for
changelogs.

Thanks,
ZhengYuan Huang