diff options
author | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2012-01-09 02:38:23 -0500 |
---|---|---|
committer | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2012-01-09 02:38:23 -0500 |
commit | da733563be5a9da26fe81d9f007262d00b846e22 (patch) | |
tree | db28291df94a2043af2123911984c5c173da4e6f /tools/perf/util/debug.c | |
parent | 6ccbcf2cb41131f8d56ef0723bf3f7c1f8486076 (diff) | |
parent | dab78d7924598ea4031663dd10db814e2e324928 (diff) |
Merge branch 'next' into for-linus
Diffstat (limited to 'tools/perf/util/debug.c')
-rw-r--r-- | tools/perf/util/debug.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/tools/perf/util/debug.c b/tools/perf/util/debug.c index 155749d74350..26817daa2961 100644 --- a/tools/perf/util/debug.c +++ b/tools/perf/util/debug.c | |||
@@ -47,19 +47,20 @@ int dump_printf(const char *fmt, ...) | |||
47 | } | 47 | } |
48 | 48 | ||
49 | #ifdef NO_NEWT_SUPPORT | 49 | #ifdef NO_NEWT_SUPPORT |
50 | void ui__warning(const char *format, ...) | 50 | int ui__warning(const char *format, ...) |
51 | { | 51 | { |
52 | va_list args; | 52 | va_list args; |
53 | 53 | ||
54 | va_start(args, format); | 54 | va_start(args, format); |
55 | vfprintf(stderr, format, args); | 55 | vfprintf(stderr, format, args); |
56 | va_end(args); | 56 | va_end(args); |
57 | return 0; | ||
57 | } | 58 | } |
58 | #endif | 59 | #endif |
59 | 60 | ||
60 | void ui__warning_paranoid(void) | 61 | int ui__error_paranoid(void) |
61 | { | 62 | { |
62 | ui__warning("Permission error - are you root?\n" | 63 | return ui__error("Permission error - are you root?\n" |
63 | "Consider tweaking /proc/sys/kernel/perf_event_paranoid:\n" | 64 | "Consider tweaking /proc/sys/kernel/perf_event_paranoid:\n" |
64 | " -1 - Not paranoid at all\n" | 65 | " -1 - Not paranoid at all\n" |
65 | " 0 - Disallow raw tracepoint access for unpriv\n" | 66 | " 0 - Disallow raw tracepoint access for unpriv\n" |