[PATCH 0/2] add columns for zoned parameters

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Several parameters for zoned devices are missing from lsblk's columns. This
series introduces them as following.

 Column Name      Description             Sysfs path
 ---------------------------------------------------------------------
 ZONE-SIZE        zone size               queue/chunk_sectors
 ZONE-WGRAN       zone write granularity  queue/zone_write_granularity
 ZONE-APPEND      zone append max bytes   queue/zone_append_max_bytes
 ZONES-NR         number of zones         queue/nr_zones
 ZONES-OMAX       max open zones          queue/max_open_zones
 ZONES-AMAX       max active zones        queue/max_active_zones

Sample output:

$ lsblk -o NAME,ZONED,ZONE-SIZE,ZONE-WGRAN,ZONE-APPEND,ZONES-NR,ZONES-OMAX,ZONES-AMAX -i
NAME        ZONED        ZONE-SIZE ZONE-WGRAN ZONE-APPEND ZONES-NR ZONES-OMAX ZONES-AMAX
sda         host-managed      256M         4K        672K    55880        128          0
sdb         host-managed      256M         4K        672K    55880        128          0
zram0       none                0B         0B          0B        0          0          0
nvme2n1     none                0B         0B          0B        0          0          0
|-nvme2n1p1 none                0B         0B          0B        0          0          0
|-nvme2n1p2 none                0B         0B          0B        0          0          0
`-nvme2n1p3 none                0B         0B          0B        0          0          0
nvme0n1     none                0B         0B          0B        0          0          0
nvme1n1     none                0B         0B          0B        0          0          0
nvme0n2     host-managed        2G         4K          4M     1844         14         14
nvme1n2     host-managed        2G         4K          4M     1844         14         14

$ lsblk --help|grep -i zone
 -z, --zoned          print zone model
        ZONED  zone model
    ZONE-SIZE  zone size
   ZONE-WGRAN  zone write granularity
  ZONE-APPEND  zone append max bytes
     ZONES-NR  number of zones
   ZONES-OMAX  max open zones
   ZONES-AMAX  max active zones


Naohiro Aota (2):
  lsblk: factor out function to read sysfs param as bytes
  lsblk: add columns of zoned parameters

 misc-utils/lsblk.c | 95 ++++++++++++++++++++++++++++++++++------------
 1 file changed, 71 insertions(+), 24 deletions(-)

-- 
2.33.0




[Index of Archives]     [Netdev]     [Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux