usr/src/uts/common/fs/zfs/sys/vdev_impl.h
changeset 13700 2889e2596bd6
parent 13574 d0fde6cacaac
child 13869 921a99998bb4
equal deleted inserted replaced
13699:733714f4dc24 13700:2889e2596bd6
   200 
   200 
   201 	/*
   201 	/*
   202 	 * For DTrace to work in userland (libzpool) context, these fields must
   202 	 * For DTrace to work in userland (libzpool) context, these fields must
   203 	 * remain at the end of the structure.  DTrace will use the kernel's
   203 	 * remain at the end of the structure.  DTrace will use the kernel's
   204 	 * CTF definition for 'struct vdev', and since the size of a kmutex_t is
   204 	 * CTF definition for 'struct vdev', and since the size of a kmutex_t is
   205 	 * larger in userland, the offsets for the rest fields would be
   205 	 * larger in userland, the offsets for the rest of the fields would be
   206 	 * incorrect.
   206 	 * incorrect.
   207 	 */
   207 	 */
   208 	kmutex_t	vdev_dtl_lock;	/* vdev_dtl_{map,resilver}	*/
   208 	kmutex_t	vdev_dtl_lock;	/* vdev_dtl_{map,resilver}	*/
   209 	kmutex_t	vdev_stat_lock;	/* vdev_stat			*/
   209 	kmutex_t	vdev_stat_lock;	/* vdev_stat			*/
   210 	kmutex_t	vdev_probe_lock; /* protects vdev_probe_zio	*/
   210 	kmutex_t	vdev_probe_lock; /* protects vdev_probe_zio	*/
   255  * Size of label regions at the start and end of each leaf device.
   255  * Size of label regions at the start and end of each leaf device.
   256  */
   256  */
   257 #define	VDEV_LABEL_START_SIZE	(2 * sizeof (vdev_label_t) + VDEV_BOOT_SIZE)
   257 #define	VDEV_LABEL_START_SIZE	(2 * sizeof (vdev_label_t) + VDEV_BOOT_SIZE)
   258 #define	VDEV_LABEL_END_SIZE	(2 * sizeof (vdev_label_t))
   258 #define	VDEV_LABEL_END_SIZE	(2 * sizeof (vdev_label_t))
   259 #define	VDEV_LABELS		4
   259 #define	VDEV_LABELS		4
       
   260 #define	VDEV_BEST_LABEL		VDEV_LABELS
   260 
   261 
   261 #define	VDEV_ALLOC_LOAD		0
   262 #define	VDEV_ALLOC_LOAD		0
   262 #define	VDEV_ALLOC_ADD		1
   263 #define	VDEV_ALLOC_ADD		1
   263 #define	VDEV_ALLOC_SPARE	2
   264 #define	VDEV_ALLOC_SPARE	2
   264 #define	VDEV_ALLOC_L2CACHE	3
   265 #define	VDEV_ALLOC_L2CACHE	3