summaryrefslogtreecommitdiffstats
path: root/sys/kern/vfs_bio.c
diff options
context:
space:
mode:
Diffstat (limited to 'sys/kern/vfs_bio.c')
-rw-r--r--sys/kern/vfs_bio.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/sys/kern/vfs_bio.c b/sys/kern/vfs_bio.c
index e66a93e..39e09b3 100644
--- a/sys/kern/vfs_bio.c
+++ b/sys/kern/vfs_bio.c
@@ -594,8 +594,8 @@ breadn(struct vnode * vp, daddr_t blkno, int size,
/* if not found in cache, do some I/O */
if ((bp->b_flags & B_CACHE) == 0) {
- if (curproc != PCPU_GET(idleproc))
- curproc->p_stats->p_ru.ru_inblock++;
+ if (curthread != PCPU_GET(idlethread))
+ curthread->td_proc->p_stats->p_ru.ru_inblock++;
bp->b_iocmd = BIO_READ;
bp->b_flags &= ~B_INVAL;
bp->b_ioflags &= ~BIO_ERROR;
@@ -615,8 +615,8 @@ breadn(struct vnode * vp, daddr_t blkno, int size,
rabp = getblk(vp, *rablkno, *rabsize, 0, 0);
if ((rabp->b_flags & B_CACHE) == 0) {
- if (curproc != PCPU_GET(idleproc))
- curproc->p_stats->p_ru.ru_inblock++;
+ if (curthread != PCPU_GET(idlethread))
+ curthread->td_proc->p_stats->p_ru.ru_inblock++;
rabp->b_flags |= B_ASYNC;
rabp->b_flags &= ~B_INVAL;
rabp->b_ioflags &= ~BIO_ERROR;
@@ -753,8 +753,8 @@ bwrite(struct buf * bp)
bp->b_runningbufspace = bp->b_bufsize;
runningbufspace += bp->b_runningbufspace;
- if (curproc != PCPU_GET(idleproc))
- curproc->p_stats->p_ru.ru_oublock++;
+ if (curthread != PCPU_GET(idlethread))
+ curthread->td_proc->p_stats->p_ru.ru_oublock++;
splx(s);
if (oldflags & B_ASYNC)
BUF_KERNPROC(bp);
@@ -2183,7 +2183,7 @@ loop:
* XXX remove if 0 sections (clean this up after its proven)
*/
if (numfreebuffers == 0) {
- if (curproc == PCPU_GET(idleproc))
+ if (curthread == PCPU_GET(idlethread))
return NULL;
needsbuffer |= VFS_BIO_NEED_ANY;
}
OpenPOWER on IntegriCloud