lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:   Mon, 9 Sep 2019 09:50:18 +0100
From:   David Ahern <dsahern@...il.com>
To:     禹舟键 <ufo19890607@...il.com>,
        Peter Zijlstra <peterz@...radead.org>,
        Ingo Molnar <mingo@...hat.com>,
        Alexander Shishkin <alexander.shishkin@...ux.intel.com>,
        Jiri Olsa <jolsa@...nel.org>,
        Namhyung Kim <namhyung@...nel.org>,
        Milian Wolff <milian.wolff@...b.com>,
        Arnaldo Carvalho de Melo <arnaldo.melo@...il.com>,
        windyu@...cent.com, Adrian Hunter <adrian.hunter@...el.com>,
        Wang Nan <wangnan0@...wei.com>
Cc:     linux-perf-users@...r.kernel.org, linux-kernel@...r.kernel.org,
        acme@...hat.com
Subject: Re: [PATCH] Add input file_name support for perf sched
 {map|latency|replay|timehist}

On 9/9/19 4:49 AM, 禹舟键 wrote:
>> diff --git a/tools/perf/builtin-sched.c b/tools/perf/builtin-sched.c
>> index 025151dcb651..8e51fbb88549 100644
>> --- a/tools/perf/builtin-sched.c
>> +++ b/tools/perf/builtin-sched.c
>> @@ -3374,6 +3374,7 @@ int cmd_sched(int argc, const char **argv)
>>         const struct option latency_options[] = {
>>         OPT_STRING('s', "sort", &sched.sort_order, "key[,key2...]",
>>                    "sort by key(s): runtime, switch, avg, max"),
>> +       OPT_STRING('i', "input", &input_name, "file", "input file name"),
>>         OPT_INTEGER('C', "CPU", &sched.profile_cpu,
>>                     "CPU to profile on"),
>>         OPT_BOOLEAN('p', "pids", &sched.skip_merge,
>> @@ -3381,11 +3382,13 @@ int cmd_sched(int argc, const char **argv)
>>         OPT_PARENT(sched_options)
>>         };
>>         const struct option replay_options[] = {
>> +       OPT_STRING('i', "input", &input_name, "file", "input file name"),
>>         OPT_UINTEGER('r', "repeat", &sched.replay_repeat,
>>                      "repeat the workload replay N times (-1: infinite)"),
>>         OPT_PARENT(sched_options)
>>         };
>>         const struct option map_options[] = {
>> +       OPT_STRING('i', "input", &input_name, "file", "input file name"),
>>         OPT_BOOLEAN(0, "compact", &sched.map.comp,
>>                     "map output in compact mode"),
>>         OPT_STRING(0, "color-pids", &sched.map.color_pids_str, "pids",
>> @@ -3397,6 +3400,7 @@ int cmd_sched(int argc, const char **argv)
>>         OPT_PARENT(sched_options)
>>         };
>>         const struct option timehist_options[] = {
>> +       OPT_STRING('i', "input", &input_name, "file", "input file name"),
>>         OPT_STRING('k', "vmlinux", &symbol_conf.vmlinux_name,
>>                    "file", "vmlinux pathname"),
>>         OPT_STRING(0, "kallsyms", &symbol_conf.kallsyms_name,
>> --
>> 2.23.0.37.g745f681
>>

This is not needed; -i already works with timehist (and others as I
recall). I believe OPT_PARENT passes the option to the subcommand.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ