From: Darrick J. Wong Date: Tue, 9 Jan 2024 17:39:27 +0000 (-0800) Subject: xfs: remove pointless unlocked assertion X-Git-Tag: xfs-zoned-old-2024-06-10~336 X-Git-Url: https://www.infradead.org/git/?a=commitdiff_plain;h=35562214b0bb1e936cd6f5cbd5bd5594788d3d74;p=users%2Fhch%2Fxfsprogs.git xfs: remove pointless unlocked assertion Remove this assertion about the inode not having an attr fork from xfs_bmap_add_attrfork because the function handles that case just fine. Weirder still, the function actually /requires/ the caller not to hold the ILOCK, which means that its accesses are not stabilized. Signed-off-by: Darrick J. Wong --- diff --git a/libxfs/xfs_bmap.c b/libxfs/xfs_bmap.c index 63feb20e2..7be0d7be8 100644 --- a/libxfs/xfs_bmap.c +++ b/libxfs/xfs_bmap.c @@ -1035,8 +1035,6 @@ xfs_bmap_add_attrfork( int logflags; /* logging flags */ int error; /* error return value */ - ASSERT(xfs_inode_has_attr_fork(ip) == 0); - mp = ip->i_mount; ASSERT(!XFS_NOT_DQATTACHED(mp, ip));