diff options
author | Arnaldo Carvalho de Melo <acme@redhat.com> | 2015-08-11 17:50:55 +0200 |
---|---|---|
committer | Arnaldo Carvalho de Melo <acme@redhat.com> | 2015-08-12 15:27:05 +0200 |
commit | 517dfdb315fa2da9b144f6fa494b4f54b490de7e (patch) | |
tree | b04dc0e38c17cfe923d62cb187020a02ce12d741 /tools/perf/ui/browsers/map.c | |
parent | perf ui browser: Introduce ui_browser__write_nstring() (diff) | |
download | linux-517dfdb315fa2da9b144f6fa494b4f54b490de7e.tar.xz linux-517dfdb315fa2da9b144f6fa494b4f54b490de7e.zip |
perf ui browser: Introduce ui_browser__printf()
To remove direct access to libslang functions, with the immediate goal
of implementing horizontal scrolling at the ui_browser level, but also
because we may at some point want to implement ui_browser with other UIs
in addition to the current libslang implementation.
Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: Borislav Petkov <bp@suse.de>
Cc: David Ahern <dsahern@gmail.com>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Stephane Eranian <eranian@google.com>
Link: http://lkml.kernel.org/n/tip-w0niblabqrkecs4o0eogfy6c@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'tools/perf/ui/browsers/map.c')
-rw-r--r-- | tools/perf/ui/browsers/map.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/tools/perf/ui/browsers/map.c b/tools/perf/ui/browsers/map.c index fb1ae241f0de..8c154c7d4669 100644 --- a/tools/perf/ui/browsers/map.c +++ b/tools/perf/ui/browsers/map.c @@ -1,4 +1,3 @@ -#include "../libslang.h" #include <elf.h> #include <inttypes.h> #include <sys/ttydefaults.h> @@ -26,10 +25,10 @@ static void map_browser__write(struct ui_browser *browser, void *nd, int row) int width; ui_browser__set_percent_color(browser, 0, current_entry); - slsmg_printf("%*" PRIx64 " %*" PRIx64 " %c ", - mb->addrlen, sym->start, mb->addrlen, sym->end, - sym->binding == STB_GLOBAL ? 'g' : - sym->binding == STB_LOCAL ? 'l' : 'w'); + ui_browser__printf(browser, "%*" PRIx64 " %*" PRIx64 " %c ", + mb->addrlen, sym->start, mb->addrlen, sym->end, + sym->binding == STB_GLOBAL ? 'g' : + sym->binding == STB_LOCAL ? 'l' : 'w'); width = browser->width - ((mb->addrlen * 2) + 4); if (width > 0) ui_browser__write_nstring(browser, sym->name, width); |