On Mon, Dec 19, 2022 at 04:05:03PM -0800, Darrick J. Wong wrote: > From: Darrick J. Wong <djwong@xxxxxxxxxx> > > In xfs_reflink_fill_cow_hole, there's a debugging assertion that trips > if (after cycling the ILOCK to get a transaction) the requeried cow > mapping overlaps the start of the area being written. IOWs, it trips if > the hole in the cow fork that it's supposed to fill has been filled. > > This is trivially possible since we cycled ILOCK_EXCL. If we trip the > assertion, then we know that cmap is a delalloc extent because @found is > false. Fortunately, the bmapi_write call below will convert the > delalloc extent to a real unwritten cow fork extent, so all we need to > do here is remove the assertion. > > It turns out that generic/095 trips this pretty regularly with alwayscow > mode enabled. > > Signed-off-by: Darrick J. Wong <djwong@xxxxxxxxxx> > --- > fs/xfs/xfs_reflink.c | 2 -- > 1 file changed, 2 deletions(-) Looks fine. Reviewed-by: Dave Chinner <dchinner@xxxxxxxxxx> -- Dave Chinner david@xxxxxxxxxxxxx