Date: Sat, 23 Mar 2013 20:17:32 +0000 (UTC) From: Martin Matuska <mm@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-vendor@freebsd.org Subject: svn commit: r248660 - in vendor-sys/illumos/dist/uts/common/fs/zfs: . sys Message-ID: <201303232017.r2NKHWfH068870@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: mm Date: Sat Mar 23 20:17:32 2013 New Revision: 248660 URL: http://svnweb.freebsd.org/changeset/base/248660 Log: Update vendor-sys/illumos/dist to illumos-gate 13990:b04b9a80047a Illumos ZFS issues: 3618 ::zio dcmd does not show timestamp data Modified: vendor-sys/illumos/dist/uts/common/fs/zfs/sys/vdev_impl.h vendor-sys/illumos/dist/uts/common/fs/zfs/sys/zio.h vendor-sys/illumos/dist/uts/common/fs/zfs/vdev.c vendor-sys/illumos/dist/uts/common/fs/zfs/vdev_queue.c Modified: vendor-sys/illumos/dist/uts/common/fs/zfs/sys/vdev_impl.h ============================================================================== --- vendor-sys/illumos/dist/uts/common/fs/zfs/sys/vdev_impl.h Sat Mar 23 20:01:45 2013 (r248659) +++ vendor-sys/illumos/dist/uts/common/fs/zfs/sys/vdev_impl.h Sat Mar 23 20:17:32 2013 (r248660) @@ -104,8 +104,7 @@ struct vdev_queue { avl_tree_t vq_read_tree; avl_tree_t vq_write_tree; avl_tree_t vq_pending_tree; - uint64_t vq_io_complete_ts; - uint64_t vq_io_delta_ts; + hrtime_t vq_io_complete_ts; kmutex_t vq_lock; }; Modified: vendor-sys/illumos/dist/uts/common/fs/zfs/sys/zio.h ============================================================================== --- vendor-sys/illumos/dist/uts/common/fs/zfs/sys/zio.h Sat Mar 23 20:01:45 2013 (r248659) +++ vendor-sys/illumos/dist/uts/common/fs/zfs/sys/zio.h Sat Mar 23 20:17:32 2013 (r248660) @@ -408,7 +408,7 @@ struct zio { uint64_t io_offset; uint64_t io_deadline; - uint64_t io_timestamp; + hrtime_t io_timestamp; avl_node_t io_offset_node; avl_node_t io_deadline_node; avl_tree_t *io_vdev_tree; Modified: vendor-sys/illumos/dist/uts/common/fs/zfs/vdev.c ============================================================================== --- vendor-sys/illumos/dist/uts/common/fs/zfs/vdev.c Sat Mar 23 20:01:45 2013 (r248659) +++ vendor-sys/illumos/dist/uts/common/fs/zfs/vdev.c Sat Mar 23 20:17:32 2013 (r248660) @@ -3180,10 +3180,10 @@ vdev_deadman(vdev_t *vd) * the spa_deadman_synctime we panic the system. */ fio = avl_first(&vq->vq_pending_tree); - delta = ddi_get_lbolt64() - fio->io_timestamp; - if (delta > NSEC_TO_TICK(spa_deadman_synctime(spa))) { - zfs_dbgmsg("SLOW IO: zio timestamp %llu, " - "delta %llu, last io %llu", + delta = gethrtime() - fio->io_timestamp; + if (delta > spa_deadman_synctime(spa)) { + zfs_dbgmsg("SLOW IO: zio timestamp %lluns, " + "delta %lluns, last io %lluns", fio->io_timestamp, delta, vq->vq_io_complete_ts); fm_panic("I/O to pool '%s' appears to be " Modified: vendor-sys/illumos/dist/uts/common/fs/zfs/vdev_queue.c ============================================================================== --- vendor-sys/illumos/dist/uts/common/fs/zfs/vdev_queue.c Sat Mar 23 20:01:45 2013 (r248659) +++ vendor-sys/illumos/dist/uts/common/fs/zfs/vdev_queue.c Sat Mar 23 20:17:32 2013 (r248660) @@ -45,8 +45,11 @@ int zfs_vdev_max_pending = 10; int zfs_vdev_min_pending = 4; -/* deadline = pri + ddi_get_lbolt64() >> time_shift) */ -int zfs_vdev_time_shift = 6; +/* + * The deadlines are grouped into buckets based on zfs_vdev_time_shift: + * deadline = pri + gethrtime() >> time_shift) + */ +int zfs_vdev_time_shift = 29; /* each bucket is 0.537 seconds */ /* exponential I/O issue ramp-up rate */ int zfs_vdev_ramp_rate = 2; @@ -412,7 +415,7 @@ vdev_queue_io(zio_t *zio) mutex_enter(&vq->vq_lock); - zio->io_timestamp = ddi_get_lbolt64(); + zio->io_timestamp = gethrtime(); zio->io_deadline = (zio->io_timestamp >> zfs_vdev_time_shift) + zio->io_priority; @@ -445,8 +448,7 @@ vdev_queue_io_done(zio_t *zio) vdev_queue_pending_remove(vq, zio); - vq->vq_io_complete_ts = ddi_get_lbolt64(); - vq->vq_io_delta_ts = vq->vq_io_complete_ts - zio->io_timestamp; + vq->vq_io_complete_ts = gethrtime(); for (int i = 0; i < zfs_vdev_ramp_rate; i++) { zio_t *nio = vdev_queue_io_to_issue(vq, zfs_vdev_max_pending);
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201303232017.r2NKHWfH068870>