[lkml]   [2011]   [Aug]   [16]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
    Patch in this message
    Subject[PATCH 1/6] perf list: Fix exit value
    From: Stephane Eranian <>

    This patch fixes an issue with the exit value of perf list:

    $ perf list; echo $?

    perf list returns an error exit code even though there is no error.

    There was a stray exit(129) in print_events(). This patch removes this

    $ perf list; echo $?

    $ perf list hw sw
    cpu-cycles OR cycles [Hardware event]
    stalled-cycles-frontend OR idle-cycles-frontend [Hardware event]
    stalled-cycles-backend OR idle-cycles-backend [Hardware event]
    instructions [Hardware event]
    cache-references [Hardware event]
    cache-misses [Hardware event]
    branch-instructions OR branches [Hardware event]
    branch-misses [Hardware event]
    bus-cycles [Hardware event]

    cpu-clock [Software event]
    task-clock [Software event]
    page-faults OR faults [Software event]
    minor-faults [Software event]
    major-faults [Software event]
    context-switches OR cs [Software event]
    cpu-migrations OR migrations [Software event]
    alignment-faults [Software event]
    emulation-faults [Software event]
    $ echo $?

    Cc: Frederic Weisbecker <>
    Cc: Ingo Molnar <>
    Cc: Peter Zijlstra <>
    Signed-off-by: Stephane Eranian <>
    Signed-off-by: Arnaldo Carvalho de Melo <>
    tools/perf/util/parse-events.c | 2 --
    1 files changed, 0 insertions(+), 2 deletions(-)

    diff --git a/tools/perf/util/parse-events.c b/tools/perf/util/parse-events.c
    index 4ea7e19..d93f3ce 100644
    --- a/tools/perf/util/parse-events.c
    +++ b/tools/perf/util/parse-events.c
    @@ -1097,6 +1097,4 @@ void print_events(const char *event_glob)

    print_tracepoint_events(NULL, NULL);
    - exit(129);

     \ /
      Last update: 2011-08-16 16:45    [W:0.021 / U:37.692 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site