Blame SOURCES/0053-tests-qemu-boot-analysis-Display-all-times-in-ms.patch

e76f14
From 2e75e1584b4ad34df3999f9e0b270a0fdc246c67 Mon Sep 17 00:00:00 2001
e76f14
From: "Richard W.M. Jones" <rjones@redhat.com>
e76f14
Date: Sat, 2 Apr 2016 10:42:12 +0100
e76f14
Subject: [PATCH] tests/qemu: boot-analysis: Display all times in ms.
e76f14
e76f14
It was confusing to have a mix of seconds and milliseconds.  For all
e76f14
upstream testing (eg. with SeaBIOS) we are discussing everything in
e76f14
milliseconds, so use those exclusively.
e76f14
e76f14
(cherry picked from commit d470480b3564b45301a79047f919051b4e2e58b4)
e76f14
---
e76f14
 tests/qemu/boot-analysis.c | 8 ++++----
e76f14
 1 file changed, 4 insertions(+), 4 deletions(-)
e76f14
e76f14
diff --git a/tests/qemu/boot-analysis.c b/tests/qemu/boot-analysis.c
e76f14
index 022eaab..9ab228a 100644
e76f14
--- a/tests/qemu/boot-analysis.c
e76f14
+++ b/tests/qemu/boot-analysis.c
e76f14
@@ -860,8 +860,8 @@ print_activity (struct activity *activity)
e76f14
   if (activity->warning) ansi_red (); else ansi_green ();
e76f14
   print_escaped_string (activity->name);
e76f14
   ansi_restore ();
e76f14
-  printf (" %1.6fs ±%.1fms ",
e76f14
-          activity->mean / 1000000000, activity->sd / 1000000);
e76f14
+  printf (" %.1fms ±%.1fms ",
e76f14
+          activity->mean / 1000000, activity->sd / 1000000);
e76f14
   if (activity->warning) ansi_red (); else ansi_green ();
e76f14
   printf ("(%.1f%%) ", activity->percent);
e76f14
   ansi_restore ();
e76f14
@@ -906,7 +906,7 @@ print_analysis (void)
e76f14
 
e76f14
     /* Draw a spacer line, but only if last_t -> t is a large jump. */
e76f14
     if (t - last_t >= 1000000 /* ns */) {
e76f14
-      printf ("           ");
e76f14
+      printf ("          ");
e76f14
       ansi_magenta ();
e76f14
       for (j = 0; j < last_free_column; ++j) {
e76f14
         if (columns[j] >= 0 &&
e76f14
@@ -946,7 +946,7 @@ print_analysis (void)
e76f14
 
e76f14
     /* Draw the line. */
e76f14
     ansi_blue ();
e76f14
-    printf ("%1.6fs: ", t / 1000000000);
e76f14
+    printf ("%6.1fms: ", t / 1000000);
e76f14
 
e76f14
     ansi_magenta ();
e76f14
     for (j = 0; j < last_free_column; ++j) {
e76f14
-- 
aa0300
2.7.4
e76f14