Move ru_inblock increment into arc_read_nolock() so we don't account for

cached reads.

Discussed with:		gibbs
No objections from:	avg
Tested by:		Marcus Reid <marcus@blazingdot.com>
MFC after:		1 week
This commit is contained in:
Pawel Jakub Dawidek 2011-12-10 13:02:52 +00:00
parent 972478a4c0
commit 75c0e29ff3
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=228392
2 changed files with 3 additions and 4 deletions

View File

@ -3105,6 +3105,9 @@ arc_read_nolock(zio_t *pio, spa_t *spa, const blkptr_t *bp,
ARCSTAT_CONDSTAT(!(hdr->b_flags & ARC_PREFETCH),
demand, prefetch, hdr->b_type != ARC_BUFC_METADATA,
data, metadata, misses);
#ifdef _KERNEL
curthread->td_ru.ru_inblock++;
#endif
if (vd != NULL && l2arc_ndev != 0 && !(l2arc_norw && devw)) {
/*

View File

@ -627,10 +627,6 @@ dbuf_read(dmu_buf_impl_t *db, zio_t *zio, uint32_t flags)
} else if (db->db_state == DB_UNCACHED) {
spa_t *spa = dn->dn_objset->os_spa;
#ifdef _KERNEL
curthread->td_ru.ru_inblock++;
#endif
if (zio == NULL)
zio = zio_root(spa, NULL, NULL, ZIO_FLAG_CANFAIL);
dbuf_read_impl(db, zio, &flags);