1
0
mirror of https://git.FreeBSD.org/src.git synced 2024-12-20 11:11:24 +00:00

Do not fetch precise time of request start when stats collection disabled.

Reviewed by:	pjd, phk
This commit is contained in:
Alexander Motin 2010-03-24 18:04:25 +00:00
parent 438be77d54
commit a5be8eb530
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=205619

View File

@ -443,7 +443,10 @@ g_io_request(struct bio *bp, struct g_consumer *cp)
("Bio already on queue bp=%p", bp));
bp->bio_flags |= BIO_ONQUEUE;
binuptime(&bp->bio_t0);
if (g_collectstats)
binuptime(&bp->bio_t0);
else
getbinuptime(&bp->bio_t0);
/*
* The statistics collection is lockless, as such, but we