]> www.infradead.org Git - users/jedix/linux-maple.git/commit
bcachefs: Fix sysfs rebalance duration waited formatting
authorFeiko Nanninga <feiko.nanninga@fnanninga.de>
Sun, 1 Sep 2024 17:08:05 +0000 (19:08 +0200)
committerKent Overstreet <kent.overstreet@linux.dev>
Mon, 9 Sep 2024 13:41:47 +0000 (09:41 -0400)
commit36f0af4f44a4e465b0af4bf188d780511c1ca189
tree05798ba370de96debd2b0324b71cef4a5977f4d6
parenta3ed1cc4136df01e74a8b6df8c562db69e752bad
bcachefs: Fix sysfs rebalance duration waited formatting

cat /sys/fs/bcachefs/*/internal/rebalance_status
waiting
  io wait duration:  13.5 GiB
  io wait remaining: 627 MiB
  duration waited:   1392 m

duration waited was increasing at a rate of about 14 times the expected
rate.

div_u64 takes a u32 divisor, but u->nsecs (from time_units[]) can be
bigger than u32.

Signed-off-by: Feiko Nanninga <feiko.nanninga@fnanninga.de>
Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
fs/bcachefs/util.c