mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-11-24 07:20:50 +07:00
xfs: fix unused variable warning in xfs_buf_set_ref()
Fix an unused variable warning on non-DEBUG builds introduced by
commit 7561d27e90
("xfs: buffer lru reference count error injection
tag").
Signed-off-by: Brian Foster <bfoster@redhat.com>
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
2fdbec5cbe
commit
4eadcf9a41
@ -2133,14 +2133,13 @@ xfs_buf_terminate(void)
|
||||
|
||||
void xfs_buf_set_ref(struct xfs_buf *bp, int lru_ref)
|
||||
{
|
||||
struct xfs_mount *mp = bp->b_target->bt_mount;
|
||||
|
||||
/*
|
||||
* Set the lru reference count to 0 based on the error injection tag.
|
||||
* This allows userspace to disrupt buffer caching for debug/testing
|
||||
* purposes.
|
||||
*/
|
||||
if (XFS_TEST_ERROR(false, mp, XFS_ERRTAG_BUF_LRU_REF))
|
||||
if (XFS_TEST_ERROR(false, bp->b_target->bt_mount,
|
||||
XFS_ERRTAG_BUF_LRU_REF))
|
||||
lru_ref = 0;
|
||||
|
||||
atomic_set(&bp->b_lru_ref, lru_ref);
|
||||
|
Loading…
Reference in New Issue
Block a user