perf event: Check ref_reloc_sym before using it
authorIgor Lubashev <ilubashe@akamai.com>
Tue, 27 Aug 2019 01:39:12 +0000 (21:39 -0400)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Wed, 28 Aug 2019 20:17:51 +0000 (17:17 -0300)
commite9a6882f267a8105461066e3ea6b4b6b9be1b807
treee25aaabf2f797b793bf048a52a2396d974d748bc
parent0a56e0603fa13af08816d673f6f71b68cda2fb2e
perf event: Check ref_reloc_sym before using it

Check for ref_reloc_sym before using it instead of checking
symbol_conf.kptr_restrict and relying solely on that check.

Reported-by: Mathieu Poirier <mathieu.poirier@linaro.org>
Signed-off-by: Igor Lubashev <ilubashe@akamai.com>
Tested-by: Mathieu Poirier <mathieu.poirier@linaro.org>
Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
Cc: Alexey Budankov <alexey.budankov@linux.intel.com>
Cc: James Morris <jmorris@namei.org>
Cc: Jiri Olsa <jolsa@kernel.org>
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
Link: http://lkml.kernel.org/r/1566869956-7154-2-git-send-email-ilubashe@akamai.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/perf/util/event.c