From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751197AbdAMTYr (ORCPT ); Fri, 13 Jan 2017 14:24:47 -0500 Received: from mail.kernel.org ([198.145.29.136]:41530 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750805AbdAMTYq (ORCPT ); Fri, 13 Jan 2017 14:24:46 -0500 Date: Fri, 13 Jan 2017 16:24:40 -0300 From: Arnaldo Carvalho de Melo To: Yannick Brosseau Cc: namhyung@kernel.org, linux-kernel@vger.kernel.org, kernel-team@fb.com, mbd@fb.com Subject: Re: [PATCH] perf script: Also allow forcing reading of non-root owned files by root Message-ID: <20170113192440.GC32549@kernel.org> References: <20170113182527.18625-1-scientist@fb.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20170113182527.18625-1-scientist@fb.com> X-Url: http://acmel.wordpress.com User-Agent: Mutt/1.7.1 (2016-10-04) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Em Fri, Jan 13, 2017 at 01:25:27PM -0500, Yannick Brosseau escreveu: > In 2059fc7a5a9e6677, perf report was added the option of forcing reading > of non-root owned symbol file. > > This add the same behavior for perf script. looks ok, applied. - Arnaldo > Reported-by: Mark Drayton > Signed-off-by: Yannick Brosseau > --- > tools/perf/builtin-script.c | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > > diff --git a/tools/perf/builtin-script.c b/tools/perf/builtin-script.c > index 2f3ff69fc4e7..c0783b4f7b6c 100644 > --- a/tools/perf/builtin-script.c > +++ b/tools/perf/builtin-script.c > @@ -2180,7 +2180,7 @@ int cmd_script(int argc, const char **argv, const char *prefix __maybe_unused) > "Show the mmap events"), > OPT_BOOLEAN('\0', "show-switch-events", &script.show_switch_events, > "Show context switch events (if recorded)"), > - OPT_BOOLEAN('f', "force", &file.force, "don't complain, do it"), > + OPT_BOOLEAN('f', "force", &symbol_conf.force, "don't complain, do it"), > OPT_BOOLEAN(0, "ns", &nanosecs, > "Use 9 decimal places when displaying time"), > OPT_CALLBACK_OPTARG(0, "itrace", &itrace_synth_opts, NULL, "opts", > @@ -2212,6 +2212,7 @@ int cmd_script(int argc, const char **argv, const char *prefix __maybe_unused) > PARSE_OPT_STOP_AT_NON_OPTION); > > file.path = input_name; > + file.force = symbol_conf.force; > > if (argc > 1 && !strncmp(argv[0], "rec", strlen("rec"))) { > rec_script_path = get_script_path(argv[1], RECORD_SUFFIX); > -- > 2.11.0