perf test: test_intel_pt.sh: Fix return checking

The use of set -e will cause a function that returns non-zero to terminate
the script unless the result is consumed by || for example. That is OK if
there is only 1 test function, but not if there are more. Prepare for more
by using ||.

Signed-off-by: Adrian Hunter <adrian.hunter@intel.com>
Acked-by: Namhyung Kim <namhyung@kernel.org>
Cc: Ian Rogers <irogers@google.com>
Cc: Jiri Olsa <jolsa@kernel.org>
Link: https://lore.kernel.org/r/20220912083412.7058-9-adrian.hunter@intel.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
This commit is contained in:
Adrian Hunter 2022-09-12 11:34:09 +03:00 committed by Arnaldo Carvalho de Melo
parent 5d7aac2bf8
commit fd9b45e39c
1 changed files with 3 additions and 3 deletions

View File

@ -72,11 +72,11 @@ count_result()
return
fi
err_cnt=$((err_cnt + 1))
ret=0
}
test_system_wide_side_band
count_result $?
ret=0
test_system_wide_side_band || ret=$? ; count_result $ret
cleanup