mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-08-24 01:41:39 +00:00
xfs: fix the check for COW extents in xfs_swap_extents
i_cnextents does not include delayed allocated extents, so switch to the inode fork size check that we already use in other places instead. Signed-off-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Darrick J. Wong <darrick.wong@oracle.com> Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
This commit is contained in:
parent
e6b9657056
commit
5bcffe300c
1 changed files with 2 additions and 2 deletions
|
@ -2014,11 +2014,11 @@ xfs_swap_extents(
|
|||
ip->i_cowfp = tip->i_cowfp;
|
||||
tip->i_cowfp = cowfp;
|
||||
|
||||
if (ip->i_cowfp && ip->i_cnextents)
|
||||
if (ip->i_cowfp && ip->i_cowfp->if_bytes)
|
||||
xfs_inode_set_cowblocks_tag(ip);
|
||||
else
|
||||
xfs_inode_clear_cowblocks_tag(ip);
|
||||
if (tip->i_cowfp && tip->i_cnextents)
|
||||
if (tip->i_cowfp && tip->i_cowfp->if_bytes)
|
||||
xfs_inode_set_cowblocks_tag(tip);
|
||||
else
|
||||
xfs_inode_clear_cowblocks_tag(tip);
|
||||
|
|
Loading…
Reference in a new issue