Re: [PATCH] xfs: fix slab-use-after-free in xrep_newbt_free()
From: Zheng Shuhao
Date: Fri Oct 16 2026 - 10:21:42 EST
Hi Carlos,
Thank you for the pointer, and my apologies for the confusion. This is
my first patch submission to the Linux kernel, and I was not aware of the
known-identity requirement for patch authorship and Signed-off-by.
Understood now; I will use my real name for all future submissions:
Zheng Shuhao <viennaoffh@xxxxxxxxx>
(vienna-0FFH was my GitHub handle only.)
For reference, this is the testing I did on the patch before posting:
* Built the patched tree with KASAN + XFS_DEBUG enabled; checkpatch.pl
--strict reports 0 errors and 0 warnings.
* Reproduced the use-after-free deterministically in QEMU on an
unpatched kernel; the KASAN splat matches the syzbot report exactly
(xfs_defer_item_unpause <- xrep_newbt_free <- xrep_bmap_build_new_fork,
and the xfs_defer_pending object is freed by xfs_defer_finish_noroll).
* With the patch applied, the same trigger produces no KASAN report: the
scrub ioctl just returns -EIO and the shutdown path unwinds cleanly.
* Regression runs on the patched kernel: all metadata scrub types,
invalid scrub inputs (bad flags/generation/agno/type), and forced bmap
btree rebuilds from 5 up to 1500 extents (covering both extents- and
btree-format forks), with read-back verification of the files. No
regressions; normal scrub/repair paths still succeed.
I can share the reproducer and test scripts if that is useful.
Would you prefer that I resend this as v2 with the correct
From:/Signed-off-by: lines, or can you fix up the authorship when
applying? Either way works for me.
Thanks,
Zheng Shuhao