xfs: add error injection for per-AG resv failure
authorGao Xiang <hsiangkao@redhat.com>
Wed, 24 Mar 2021 02:05:39 +0000 (19:05 -0700)
committerDarrick J. Wong <djwong@kernel.org>
Thu, 25 Mar 2021 23:47:53 +0000 (16:47 -0700)
commit2b92faed551173f065ee2a8cf087dc76cf40303b
tree4eb4799a6dfa0e6a8ff58e6288dc9d3344c7e617
parentfb2fc172018599a6564aab4ac0dce79bf94bd6bc
xfs: add error injection for per-AG resv failure

per-AG resv failure after fixing up freespace is hard to test in an
effective way, so directly add an error injection path to observe
such error handling path works as expected.

Signed-off-by: Gao Xiang <hsiangkao@redhat.com>
Reviewed-by: Darrick J. Wong <djwong@kernel.org>
Signed-off-by: Darrick J. Wong <djwong@kernel.org>
fs/xfs/libxfs/xfs_ag_resv.c
fs/xfs/libxfs/xfs_errortag.h
fs/xfs/xfs_error.c