xfs: Introduce error injection to reduce maximum inode fork extent count
authorChandan Babu R <chandanrlinux@gmail.com>
Sat, 23 Jan 2021 00:48:15 +0000 (16:48 -0800)
committerDarrick J. Wong <djwong@kernel.org>
Sat, 23 Jan 2021 00:54:48 +0000 (16:54 -0800)
commitf9fa87169d2bc1bf55ab42bb6085114378c53b86
tree3631687fa6a9f5eba0b7bffa4b65a857ff30127a
parentbcc561f21f115437a010307420fc43d91be91c66
xfs: Introduce error injection to reduce maximum inode fork extent count

This commit adds XFS_ERRTAG_REDUCE_MAX_IEXTENTS error tag which enables
userspace programs to test "Inode fork extent count overflow detection"
by reducing maximum possible inode fork extent count to 10.

Reviewed-by: Darrick J. Wong <darrick.wong@oracle.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Allison Henderson <allison.henderson@oracle.com>
Signed-off-by: Chandan Babu R <chandanrlinux@gmail.com>
Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
fs/xfs/libxfs/xfs_errortag.h
fs/xfs/libxfs/xfs_inode_fork.c
fs/xfs/xfs_error.c