diff options
author | André Fabian Silva Delgado <emulatorman@parabola.nu> | 2015-08-05 17:04:01 -0300 |
---|---|---|
committer | André Fabian Silva Delgado <emulatorman@parabola.nu> | 2015-08-05 17:04:01 -0300 |
commit | 57f0f512b273f60d52568b8c6b77e17f5636edc0 (patch) | |
tree | 5e910f0e82173f4ef4f51111366a3f1299037a7b /tools/perf/ui/progress.h |
Initial import
Diffstat (limited to 'tools/perf/ui/progress.h')
-rw-r--r-- | tools/perf/ui/progress.h | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/tools/perf/ui/progress.h b/tools/perf/ui/progress.h new file mode 100644 index 000000000..717d39d30 --- /dev/null +++ b/tools/perf/ui/progress.h @@ -0,0 +1,23 @@ +#ifndef _PERF_UI_PROGRESS_H_ +#define _PERF_UI_PROGRESS_H_ 1 + +#include <linux/types.h> + +void ui_progress__finish(void); + +struct ui_progress { + const char *title; + u64 curr, next, step, total; +}; + +void ui_progress__init(struct ui_progress *p, u64 total, const char *title); +void ui_progress__update(struct ui_progress *p, u64 adv); + +struct ui_progress_ops { + void (*update)(struct ui_progress *p); + void (*finish)(void); +}; + +extern struct ui_progress_ops *ui_progress__ops; + +#endif |