xfs: always use iget in bulkstat
The non-coherent bulkstat versionsthat look directly at the inode buffers causes various problems with performance optimizations that make increased use of just logging inodes. This patch makes bulkstat always use iget, which should be fast enough for normal use with the radix-tree based inode cache introduced a while ago. Signed-off-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Dave Chinner <dchinner@redhat.com>
This commit is contained in:

committed by
Dave Chinner

parent
1817176a86
commit
7dce11dbac
@@ -1632,10 +1632,8 @@ xfs_qm_dqusage_adjust(
|
||||
xfs_ino_t ino, /* inode number to get data for */
|
||||
void __user *buffer, /* not used */
|
||||
int ubsize, /* not used */
|
||||
void *private_data, /* not used */
|
||||
xfs_daddr_t bno, /* starting block of inode cluster */
|
||||
int *ubused, /* not used */
|
||||
void *dip, /* on-disk inode pointer (not used) */
|
||||
int *res) /* result code value */
|
||||
{
|
||||
xfs_inode_t *ip;
|
||||
@@ -1796,12 +1794,13 @@ xfs_qm_quotacheck(
|
||||
* Iterate thru all the inodes in the file system,
|
||||
* adjusting the corresponding dquot counters in core.
|
||||
*/
|
||||
if ((error = xfs_bulkstat(mp, &lastino, &count,
|
||||
xfs_qm_dqusage_adjust, NULL,
|
||||
structsz, NULL, BULKSTAT_FG_IGET, &done)))
|
||||
error = xfs_bulkstat(mp, &lastino, &count,
|
||||
xfs_qm_dqusage_adjust,
|
||||
structsz, NULL, &done);
|
||||
if (error)
|
||||
break;
|
||||
|
||||
} while (! done);
|
||||
} while (!done);
|
||||
|
||||
/*
|
||||
* We've made all the changes that we need to make incore.
|
||||
|
@@ -1109,10 +1109,8 @@ xfs_qm_internalqcheck_adjust(
|
||||
xfs_ino_t ino, /* inode number to get data for */
|
||||
void __user *buffer, /* not used */
|
||||
int ubsize, /* not used */
|
||||
void *private_data, /* not used */
|
||||
xfs_daddr_t bno, /* starting block of inode cluster */
|
||||
int *ubused, /* not used */
|
||||
void *dip, /* not used */
|
||||
int *res) /* bulkstat result code */
|
||||
{
|
||||
xfs_inode_t *ip;
|
||||
@@ -1205,15 +1203,15 @@ xfs_qm_internalqcheck(
|
||||
* Iterate thru all the inodes in the file system,
|
||||
* adjusting the corresponding dquot counters
|
||||
*/
|
||||
if ((error = xfs_bulkstat(mp, &lastino, &count,
|
||||
xfs_qm_internalqcheck_adjust, NULL,
|
||||
0, NULL, BULKSTAT_FG_IGET, &done))) {
|
||||
error = xfs_bulkstat(mp, &lastino, &count,
|
||||
xfs_qm_internalqcheck_adjust,
|
||||
0, NULL, &done);
|
||||
if (error) {
|
||||
cmn_err(CE_DEBUG, "Bulkstat returned error 0x%x", error);
|
||||
break;
|
||||
}
|
||||
} while (! done);
|
||||
if (error) {
|
||||
cmn_err(CE_DEBUG, "Bulkstat returned error 0x%x", error);
|
||||
}
|
||||
} while (!done);
|
||||
|
||||
cmn_err(CE_DEBUG, "Checking results against system dquots");
|
||||
for (i = 0; i < qmtest_hashmask; i++) {
|
||||
xfs_dqtest_t *d, *n;
|
||||
|
Reference in New Issue
Block a user