lkml.org 
[lkml]   [2018]   [Jun]   [7]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
Subject[tip:perf/urgent] perf test code-reading: Fix perf_env setup for PTI entry trampolines
Commit-ID:  f6c66d73bb8192d357bb5fb8cd5826920f811d8c
Gitweb: https://git.kernel.org/tip/f6c66d73bb8192d357bb5fb8cd5826920f811d8c
Author: Adrian Hunter <adrian.hunter@intel.com>
AuthorDate: Tue, 5 Jun 2018 10:30:00 +0300
Committer: Arnaldo Carvalho de Melo <acme@redhat.com>
CommitDate: Wed, 6 Jun 2018 12:52:05 -0300

perf test code-reading: Fix perf_env setup for PTI entry trampolines

The "Object code reading" test will not create maps for the PTI entry
trampolines unless the machine environment exists to show that the arch is
x86_64.

Signed-off-by: Adrian Hunter <adrian.hunter@intel.com>
Reported-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: Jiri Olsa <jolsa@redhat.com>
Link: http://lkml.kernel.org/r/1528183800-21577-1-git-send-email-adrian.hunter@intel.com
[ split from a larger patch ]
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/tests/code-reading.c | 1 +
1 file changed, 1 insertion(+)

diff --git a/tools/perf/tests/code-reading.c b/tools/perf/tests/code-reading.c
index afa4ce21ba7c..4892bd2dc33e 100644
--- a/tools/perf/tests/code-reading.c
+++ b/tools/perf/tests/code-reading.c
@@ -560,6 +560,7 @@ static int do_test_code_reading(bool try_kcore)
pid = getpid();

machine = machine__new_host();
+ machine->env = &perf_env;

ret = machine__create_kernel_maps(machine);
if (ret < 0) {
\
 
 \ /
  Last update: 2018-06-07 10:20    [W:0.052 / U:0.260 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site