btrfs-progs/cmds
David Sterba 083d226355 btrfs-progs: scrub status: fix rate units
There's a special case when scrub rate is printed, the device sizes and
rate use different units. The size can be in terabytes while the rate
can be in hundreds of megabytes (contemporary 10-20T disks, 250MB/s).

The sizes use what is set on command line (or human readable by
default), while the rate is always human readable with exception to
the option --raw to provide a way to print the exact numbers without any
conversions.

This got broken in commit ec3c842859 ("btrfs-progs: scrub status:
with --si, show rate in metric units") that forced the command line mode
to the rate as well.

Instead of that we need to detect the SI/IEC mode and set it to the
human readable format of rate.

Signed-off-by: David Sterba <dsterba@suse.com>
2025-02-12 00:09:07 +01:00
..
balance.c
commands.h
device.c btrfs-progs: device add: update --nodiscard spec to take no argument 2025-02-11 20:43:28 +01:00
filesystem-du.c
filesystem-usage.c btrfs-progs: reorder key initializations 2024-04-30 21:49:15 +02:00
filesystem-usage.h btrfs-progs: clean up includes 2025-01-16 19:13:26 +01:00
filesystem.c btrfs-progs: fi resize: warn if new size is < 256M 2024-09-17 16:19:03 +02:00
inspect-dump-super.c
inspect-dump-tree.c btrfs-progs: reorder key initializations 2024-04-30 21:49:15 +02:00
inspect-tree-stats.c btrfs-progs: tree-stats: unify setting raw/bytes options 2024-07-30 19:53:33 +02:00
inspect.c btrfs-progs: use proper path buffer in __ino_to_path_fd() 2024-07-30 20:04:38 +02:00
property.c
props.h btrfs-progs: clean up includes 2025-01-16 19:13:26 +01:00
qgroup.c btrfs-progs: qgroup clear-stale: check if qgroup enabled first 2025-02-11 20:43:28 +01:00
qgroup.h btrfs-progs: remove unused qgroup functions 2024-09-17 17:00:03 +02:00
quota.c
receive-dump.c btrfs-progs: factor string escaping helpers from receive dump 2024-07-30 19:53:33 +02:00
receive-dump.h
receive.c btrfs-progs: receive: make option quiet work for chroot 2024-11-26 21:05:34 +01:00
reflink.c btrfs-progs: clean up includes 2025-01-16 19:13:26 +01:00
replace.c btrfs-progs: use strncpy_null everywhere 2024-06-24 19:18:48 +02:00
rescue-chunk-recover.c btrfs-progs: reorder key initializations 2024-04-30 21:49:15 +02:00
rescue-super-recover.c
rescue.c btrfs-progs: fix a false failure for inode cache cleanup 2024-09-17 14:33:22 +02:00
rescue.h
restore.c btrfs-progs: use strncpy_null everywhere 2024-06-24 19:18:48 +02:00
scrub.c btrfs-progs: scrub status: fix rate units 2025-02-12 00:09:07 +01:00
send.c
subvolume-list.c btrfs-progs: subvol list: fix accidental trimming of subvolume name 2024-06-25 17:42:12 +02:00
subvolume.c btrfs-progs: subvolume snapshot: use libbtrfsutil for snapshot 2024-09-17 17:00:03 +02:00
subvolume.h