Skip to content

Commit 14ed868

Browse files
evdenistorvalds
authored andcommitted
xfs: remove unlikely() from WARN_ON() condition
"unlikely(WARN_ON(x))" is excessive. WARN_ON() already uses unlikely() internally. Link: http://lkml.kernel.org/r/[email protected] Signed-off-by: Denis Efremov <[email protected]> Reviewed-by: Darrick J. Wong <[email protected]> Cc: Joe Perches <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
1 parent 77c0e74 commit 14ed868

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

fs/xfs/xfs_buf.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2097,7 +2097,7 @@ xfs_verify_magic(
20972097
int idx;
20982098

20992099
idx = xfs_sb_version_hascrc(&mp->m_sb);
2100-
if (unlikely(WARN_ON(!bp->b_ops || !bp->b_ops->magic[idx])))
2100+
if (WARN_ON(!bp->b_ops || !bp->b_ops->magic[idx]))
21012101
return false;
21022102
return dmagic == bp->b_ops->magic[idx];
21032103
}
@@ -2115,7 +2115,7 @@ xfs_verify_magic16(
21152115
int idx;
21162116

21172117
idx = xfs_sb_version_hascrc(&mp->m_sb);
2118-
if (unlikely(WARN_ON(!bp->b_ops || !bp->b_ops->magic16[idx])))
2118+
if (WARN_ON(!bp->b_ops || !bp->b_ops->magic16[idx]))
21192119
return false;
21202120
return dmagic == bp->b_ops->magic16[idx];
21212121
}

0 commit comments

Comments
 (0)