[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH 1/2] Add documentation for qemu_progres_print()
From: |
Jes . Sorensen |
Subject: |
[Qemu-devel] [PATCH 1/2] Add documentation for qemu_progres_print() |
Date: |
Fri, 6 May 2011 11:39:10 +0200 |
From: Jes Sorensen <address@hidden>
Signed-off-by: Jes Sorensen <address@hidden>
---
qemu-progress.c | 8 ++++++++
1 files changed, 8 insertions(+), 0 deletions(-)
diff --git a/qemu-progress.c b/qemu-progress.c
index a4894c0..70928d6 100644
--- a/qemu-progress.c
+++ b/qemu-progress.c
@@ -111,6 +111,14 @@ void qemu_progress_end(void)
state.end();
}
+/*
+ * Add delta to current state, and print the output if the current
+ * state has progressed more than min_skip since the last value was
+ * printed. 'max' specifies the relative percentage, ie. a function
+ * can count for 30% of the total work, and still count from 0-100, by
+ * setting max to 30. If max is set to zero, the percent argument
+ * becomes an absolute value for current state.
+ */
void qemu_progress_print(float percent, int max)
{
float current;
--
1.7.4.4
[Qemu-devel] [PATCH 2/2] qemu-img.c: Remove superfluous parenthesis, Jes . Sorensen, 2011/05/06
Re: [Qemu-devel] [PATCH qemu-block 0/2] cleanup progress code, Markus Armbruster, 2011/05/06