diff options
author | Jim Harris <jimharris@FreeBSD.org> | 2014-01-06 23:48:47 +0000 |
---|---|---|
committer | Jim Harris <jimharris@FreeBSD.org> | 2014-01-06 23:48:47 +0000 |
commit | efa2980530d54b1336ddefc5fba963ef1bd9e020 (patch) | |
tree | ca97774804728ab25684b1961a4d90e93d87a2da /sbin/nvmecontrol | |
parent | c847a5062ce5e0aa2ed05d22ce7f8356c049b6fb (diff) | |
download | src-efa2980530d54b1336ddefc5fba963ef1bd9e020.tar.gz src-efa2980530d54b1336ddefc5fba963ef1bd9e020.zip |
For "nvmecontrol devlist", show namespace sizes in terms of MB instead of
GB to improve granularity of the reporting - especially for namespaces
that are on the order of 1 or 2 GB.
Submitted by: Tony Beltran <anthony.beltran@emc.com>
MFC after: 3 days
Notes
Notes:
svn path=/head/; revision=260381
Diffstat (limited to 'sbin/nvmecontrol')
-rw-r--r-- | sbin/nvmecontrol/devlist.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sbin/nvmecontrol/devlist.c b/sbin/nvmecontrol/devlist.c index f73d643e93d2..35a46c187a7f 100644 --- a/sbin/nvmecontrol/devlist.c +++ b/sbin/nvmecontrol/devlist.c @@ -99,11 +99,11 @@ devlist(int argc, char *argv[]) sprintf(name, "%s%d%s%d", NVME_CTRLR_PREFIX, ctrlr, NVME_NS_PREFIX, i+1); read_namespace_data(fd, i+1, &nsdata); - printf(" %10s (%lldGB)\n", + printf(" %10s (%lldMB)\n", name, nsdata.nsze * (long long)ns_get_sector_size(&nsdata) / - 1024 / 1024 / 1024); + 1024 / 1024); } close(fd); |