summaryrefslogtreecommitdiff
path: root/tools/perf/ui/tui/progress.c
diff options
context:
space:
mode:
Diffstat (limited to 'tools/perf/ui/tui/progress.c')
-rw-r--r--tools/perf/ui/tui/progress.c12
1 files changed, 11 insertions, 1 deletions
diff --git a/tools/perf/ui/tui/progress.c b/tools/perf/ui/tui/progress.c
index f8dc986e427d..6c2184d53cbf 100644
--- a/tools/perf/ui/tui/progress.c
+++ b/tools/perf/ui/tui/progress.c
@@ -4,7 +4,7 @@
#include "../ui.h"
#include "../browser.h"
-void ui_progress__update(u64 curr, u64 total, const char *title)
+static void tui_progress__update(u64 curr, u64 total, const char *title)
{
int bar, y;
/*
@@ -30,3 +30,13 @@ void ui_progress__update(u64 curr, u64 total, const char *title)
SLsmg_refresh();
pthread_mutex_unlock(&ui__lock);
}
+
+static struct ui_progress tui_progress_fns =
+{
+ .update = tui_progress__update,
+};
+
+void ui_progress__init(void)
+{
+ progress_fns = &tui_progress_fns;
+}