Skip to content

Commit

Permalink
perf cs-etm: Remove errnoeous ERR_PTR() usage in cs_etm__process_auxt…
Browse files Browse the repository at this point in the history
…race_info

intlist__findnew() doesn't uses ERR_PTR() as a return mechanism
so its callers shouldn't try to extract the error using PTR_ERR(
ret) from intlist__findnew(), make cs_etm__process_auxtrace_info
return -ENOMEM instead.

Signed-off-by: YueHaibing <yuehaibing@huawei.com>
Reviewed-by: Mathieu Poirier <mathieu.poirier@linaro.org>
Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Suzuki Poulouse <suzuki.poulose@arm.com>
Cc: linux-arm-kernel@lists.infradead.org
Fixes: cd8bfd8 ("perf tools: Add processing of coresight metadata")
Link: http://lkml.kernel.org/r/20190321023122.21332-2-yuehaibing@huawei.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
  • Loading branch information
YueHaibing authored and Arnaldo Carvalho de Melo committed Jul 11, 2019
1 parent 56789f3 commit edc82a9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tools/perf/util/cs-etm.c
Original file line number Diff line number Diff line change
Expand Up @@ -2460,7 +2460,7 @@ int cs_etm__process_auxtrace_info(union perf_event *event,

/* Something went wrong, no need to continue */
if (!inode) {
err = PTR_ERR(inode);
err = -ENOMEM;
goto err_free_metadata;
}

Expand Down

0 comments on commit edc82a9

Please sign in to comment.