Linux RAID subsystem development
 help / color / mirror / Atom feed
* [md PATCH 1/1] add display of hours remaining to finish resync
@ 2011-11-01 21:53 Krzysztof Adamski
  2011-11-01 23:32 ` NeilBrown
  2011-11-01 23:35 ` Paul Menzel
  0 siblings, 2 replies; 3+ messages in thread
From: Krzysztof Adamski @ 2011-11-01 21:53 UTC (permalink / raw)
  To: linux-raid

This is my first patch, so please be gentle.

This patch adds the display of the number of hours till the completion
of resync of an array in the /proc/mdstat display.

Example: [>....................]  resync =  3.3% (98633240/2928311808)
finish=1026.1min (17h) speed=45957K/sec

Signed-off-by: Krzysztof Adamski <k@adamski.org>

# diff -Naru drivers/md/md.c-orig  drivers/md/md.c
--- drivers/md/md.c-orig        2011-10-25 01:11:12.000000000 -0400
+++ drivers/md/md.c     2011-11-01 17:37:35.000000000 -0400
@@ -6351,8 +6351,8 @@
        rt *= dt;
        rt >>= 5;
 
-       seq_printf(seq, " finish=%lu.%lumin", (unsigned long)rt / 60,
-                  ((unsigned long)rt % 60)/6);
+       seq_printf(seq, " finish=%lu.%lumin (%luh)", (unsigned long)rt /
60,
+                  ((unsigned long)rt % 60)/6, (unsigned long)rt / 60 /
60);
 
        seq_printf(seq, " speed=%ldK/sec", db/2/dt);
 }




^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2011-11-01 23:35 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-11-01 21:53 [md PATCH 1/1] add display of hours remaining to finish resync Krzysztof Adamski
2011-11-01 23:32 ` NeilBrown
2011-11-01 23:35 ` Paul Menzel

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox