Print this page
4334 Improve ZFS N-way mirror read performance

@@ -19,10 +19,11 @@
  * CDDL HEADER END
  */
 /*
  * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved.
  * Copyright (c) 2013 by Delphix. All rights reserved.
+ * Copyright (c) 2013 Steven Hartland. All rights reserved.
  */
 
 #ifndef _SYS_VDEV_IMPL_H
 #define _SYS_VDEV_IMPL_H
 

@@ -114,10 +115,11 @@
         vdev_queue_class_t vq_class[ZIO_PRIORITY_NUM_QUEUEABLE];
         avl_tree_t      vq_active_tree;
         uint64_t        vq_last_offset;
         hrtime_t        vq_io_complete_ts; /* time last i/o completed */
         kmutex_t        vq_lock;
+        uint64_t        vq_last_queued_offset;
 };
 
 /*
  * Virtual device descriptor
  */

@@ -206,10 +208,13 @@
         vdev_queue_t    vdev_queue;     /* I/O deadline schedule queue  */
         vdev_cache_t    vdev_cache;     /* physical block cache         */
         spa_aux_vdev_t  *vdev_aux;      /* for l2cache vdevs            */
         zio_t           *vdev_probe_zio; /* root of current probe       */
         vdev_aux_t      vdev_label_aux; /* on-disk aux state            */
+        uint16_t        vdev_rotation_rate; /* rotational rate of the media */
+#define VDEV_RATE_UNKNOWN       0
+#define VDEV_RATE_NON_ROTATING  1
 
         /*
          * For DTrace to work in userland (libzpool) context, these fields must
          * remain at the end of the structure.  DTrace will use the kernel's
          * CTF definition for 'struct vdev', and since the size of a kmutex_t is