OSDN Git Service

perf tests: Improve temp file cleanup in test_arm_coresight.sh
authorJames Clark <james.clark@arm.com>
Tue, 21 Sep 2021 13:10:09 +0000 (14:10 +0100)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Tue, 26 Oct 2021 14:17:46 +0000 (11:17 -0300)
commit133fe2e617e48ca0948983329f43877064ffda3e
treea8342a9af22c04a915b3a4e35c9b46822e3ce0e1
parent39c534889e8c988867693ed8407ee0284c936941
perf tests: Improve temp file cleanup in test_arm_coresight.sh

Cleanup perf.data.old files which are also dropped by perf, handle
sigint and propagate it to the parent in case the test is run in a bash
while loop and don't create the temp files if the test will be skipped.

Reviewed-by: Leo Yan <leo.yan@linaro.org>
Signed-off-by: James Clark <james.clark@arm.com>
Acked-by: Ian Rogers <irogers@google.com>
Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: Mark Rutland <mark.rutland@arm.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Link: https://lore.kernel.org/r/20210921131009.390810-3-james.clark@arm.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/perf/tests/shell/test_arm_coresight.sh