Skip to content

Commit

Permalink
perf tests: Fix coresight perf test failure.
Browse files Browse the repository at this point in the history
Currently the `perf test` always fails the coresight test like:

  89: Check Arm CoreSight trace data recording and synthesized samples: FAILED!

That is because the test_arm_coresight.sh is attempting to SIGINT the
parent but is using $$ rather than $PPID and it sigint's itself when
run under the perf test framework.

Since this is done in a trap clause it ends up returning a non zero
return.

Since $PPID is a bash ism and not all distros are linking /bin/sh to
bash, the alternative parent pid lookups are uglier than just dropping
the kill, and its not strictly needed, lets pick the simple solution and
drop the sigint.

Fixes: 133fe2e ("perf tests: Improve temp file cleanup in test_arm_coresight.sh")
Reviewed-by: James Clark <[email protected]>
Signed-off-by: Jeremy Linton <[email protected]>
Cc: Alexander Shishkin <[email protected]>
Cc: Ian Rogers <[email protected]>
Cc: Ingo Molnar <[email protected]>
Cc: James Clark <[email protected]>
Cc: Jiri Olsa <[email protected]>
Cc: Leo Yan <[email protected]>
Cc: Mark Rutland <[email protected]>
Cc: Namhyung Kim <[email protected]>
Cc: Peter Zijlstra <[email protected]>
Jeremy Linton <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Arnaldo Carvalho de Melo <[email protected]>
  • Loading branch information
jlintonarm authored and acmel committed May 9, 2022
1 parent 183d4f2 commit 45fa7c3
Showing 1 changed file with 0 additions and 1 deletion.
1 change: 0 additions & 1 deletion tools/perf/tests/shell/test_arm_coresight.sh
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@ cleanup_files()
rm -f ${file}
rm -f "${perfdata}.old"
trap - exit term int
kill -2 $$
exit $glb_err
}

Expand Down

0 comments on commit 45fa7c3

Please sign in to comment.