]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
xfs: don't validate error tags in the I/O path
authorChristoph Hellwig <hch@lst.de>
Fri, 30 Jan 2026 05:19:18 +0000 (06:19 +0100)
committerCarlos Maiolino <cem@kernel.org>
Fri, 30 Jan 2026 09:41:42 +0000 (10:41 +0100)
commitb8862a09d8256a9037293f1da3b4617b21de26f1
tree514c13763caa9d3723da49f109045acdea5d3e66
parent394969e2f9d11427ce493e171949958122dc11ee
xfs: don't validate error tags in the I/O path

We can trust XFS developers enough to not pass random stuff to
XFS_ERROR_TEST/DELAY.  Open code the validity check in xfs_errortag_add,
which is the only place that receives unvalidated error tag values from
user space, and drop the now pointless xfs_errortag_enabled helper.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Hans Holmberg <hans.holmberg@wdc.com>
Reviewed-by: Carlos Maiolino <cmaiolino@redhat.com>
Reviewed-by: Darrick J. Wong <djwong@kernel.org>
Signed-off-by: Carlos Maiolino <cem@kernel.org>
fs/xfs/libxfs/xfs_errortag.h
fs/xfs/xfs_error.c
fs/xfs/xfs_error.h