summaryrefslogtreecommitdiffstats
path: root/tools/perf/util/symbol.h
diff options
context:
space:
mode:
authorArnaldo Carvalho de Melo <acme@redhat.com>2015-11-12 16:50:13 -0300
committerArnaldo Carvalho de Melo <acme@redhat.com>2015-11-12 18:58:18 -0300
commit2059fc7a5a9e667797b8ec503bfb4685afee48d8 (patch)
tree04b96518a95e0e43df054a7b81806e52ec2407e2 /tools/perf/util/symbol.h
parentb7f294b58adb02d928dccb04bd39cb789db09e1f (diff)
downloadlinux-stable-2059fc7a5a9e667797b8ec503bfb4685afee48d8.tar.gz
linux-stable-2059fc7a5a9e667797b8ec503bfb4685afee48d8.tar.bz2
linux-stable-2059fc7a5a9e667797b8ec503bfb4685afee48d8.zip
perf symbols: Allow forcing reading of non-root owned files by root
When the root user tries to read a file owned by some other user we get: # ls -la perf.data -rw-------. 1 acme acme 20032 Nov 12 15:50 perf.data # perf report File perf.data not owned by current user or root (use -f to override) # perf report -f | grep -v ^# | head -2 30.96% ls [kernel.vmlinux] [k] do_set_pte 28.24% ls libc-2.20.so [.] intel_check_word # That wasn't happening when the symbol code tried to read a JIT map, where the same check was done but no forcing was possible, fix it. Reported-by: Brendan Gregg <brendan.d.gregg@gmail.com> Tested-by: Brendan Gregg <brendan.d.gregg@gmail.com> Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://permalink.gmane.org/gmane.linux.kernel.perf.user/2380 Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'tools/perf/util/symbol.h')
-rw-r--r--tools/perf/util/symbol.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/tools/perf/util/symbol.h b/tools/perf/util/symbol.h
index 40073c60b83d..dcd786e364f2 100644
--- a/tools/perf/util/symbol.h
+++ b/tools/perf/util/symbol.h
@@ -84,6 +84,7 @@ struct symbol_conf {
unsigned short priv_size;
unsigned short nr_events;
bool try_vmlinux_path,
+ force,
ignore_vmlinux,
ignore_vmlinux_buildid,
show_kernel_path,