aboutsummaryrefslogtreecommitdiffstats
path: root/module
diff options
context:
space:
mode:
authorAkash B <[email protected]>2022-03-09 05:50:41 +0530
committerGitHub <[email protected]>2022-03-08 16:20:41 -0800
commit1282274f3355bcd11bdae911d9279ef1892f7061 (patch)
treeb8130671b30f95ffa88f0539a9895ab4db86493e /module
parentce7a5dbf4b37a0ba28dd6911e1a17f039fdd4f4e (diff)
Add physical device size to SIZE column in 'zpool list -v'
Add physical device size/capacity only for physical devices in 'zpool list -v' instead of displaying "-" in the SIZE column. This would make it easier to see the individual device capacity and to determine which spares are large enough to replace which devices. Reviewed-by: Brian Behlendorf <[email protected]> Reviewed-by: Tony Hutter <[email protected]> Reviewed-by: Dipak Ghosh <[email protected]> Signed-off-by: Akash B <[email protected]> Closes #12561 Closes #13106
Diffstat (limited to 'module')
-rw-r--r--module/zfs/vdev.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/module/zfs/vdev.c b/module/zfs/vdev.c
index a844ee2a7..7bc79a225 100644
--- a/module/zfs/vdev.c
+++ b/module/zfs/vdev.c
@@ -4424,6 +4424,7 @@ vdev_get_stats_ex(vdev_t *vd, vdev_stat_t *vs, vdev_stat_ex_t *vsx)
vs->vs_rsize = vdev_get_min_asize(vd);
if (vd->vdev_ops->vdev_op_leaf) {
+ vs->vs_pspace = vd->vdev_psize;
vs->vs_rsize += VDEV_LABEL_START_SIZE +
VDEV_LABEL_END_SIZE;
/*