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, 17 Jun 2024 17:48:50 -0300
From: Arnaldo Carvalho de Melo <acme@...nel.org>
To: Howard Chu <howardchu95@...il.com>, Namhyung Kim <namhyung@...nel.org>
Cc: peterz@...radead.org, mingo@...hat.com, mark.rutland@....com,
	alexander.shishkin@...ux.intel.com, jolsa@...nel.org,
	irogers@...gle.com, adrian.hunter@...el.com,
	kan.liang@...ux.intel.com, linux-perf-users@...r.kernel.org,
	linux-kernel@...r.kernel.org
Subject: Re: [PATCH v1] perf trace: Filter enum arguments with enum names

On Mon, Jun 17, 2024 at 05:29:17PM -0300, Arnaldo Carvalho de Melo wrote:
> On Sat, Jun 15, 2024 at 02:29:58PM +0800, Howard Chu wrote:
> > Before:
> > 
> > perf $ ./perf trace -e timer:hrtimer_start --filter='mode!=HRTIMER_MODE_ABS_PINNED_HARD' --max-events=1
> > No resolver (strtoul) for "mode" in "timer:hrtimer_start", can't set filter "(mode!=HRTIMER_MODE_ABS_PINNED_HARD) && (common_pid != 281988)"
> > 
> > After:
> > 
> > perf $ ./perf trace -e timer:hrtimer_start --filter='mode!=HRTIMER_MODE_ABS_PINNED_HARD' --max-events=1
> >      0.000 :0/0 timer:hrtimer_start(hrtimer: 0xffff9498a6ca5f18, function: 0xffffffffa77a5be0, expires: 12351248764875, softexpires: 12351248764875, mode: HRTIMER_MODE_ABS)
> 
> This one I had to apply manually after applying the other two patches:
> 
> ⬢[acme@...lbox perf-tools-next]$        git am ./20240615_howardchu95_perf_trace_filter_enum_arguments_with_enum_names.mbx
> Applying: perf trace: Filter enum arguments with enum names
> error: patch failed: tools/perf/builtin-trace.c:904
> error: tools/perf/builtin-trace.c: patch does not apply
> Patch failed at 0001 perf trace: Filter enum arguments with enum names
> hint: Use 'git am --show-current-patch=diff' to see the failed patch
> When you have resolved this problem, run "git am --continue".
> If you prefer to skip this patch, run "git am --skip" instead.
> To restore the original branch and stop patching, run "git am --abort".
> ⬢[acme@...lbox perf-tools-next]$ git am --abort
> ⬢[acme@...lbox perf-tools-next]$ patch -p1 <  ./20240615_howardchu95_perf_trace_filter_enum_arguments_with_enum_names.mbx
> patching file tools/perf/builtin-trace.c
> Hunk #1 succeeded at 894 with fuzz 2 (offset -10 lines).
> Hunk #2 succeeded at 932 (offset -10 lines).
> Hunk #3 succeeded at 1905 (offset 3 lines).
> Hunk #4 succeeded at 3832 (offset 3 lines).
> Hunk #5 succeeded at 3842 (offset 3 lines).
> Hunk #6 succeeded at 3883 (offset 3 lines).
> Hunk #7 succeeded at 3902 (offset 3 lines).
> ⬢[acme@...lbox perf-tools-next]$ 
> 
> 
> I'll push what I have to that tmp.perf-tools-next on my git repo at:
> 
> https://git.kernel.org/pub/scm/linux/kernel/git/acme/linux.git

I've put it also in the perf_trace-btf_enum branch:

https://git.kernel.org/pub/scm/linux/kernel/git/acme/linux.git/log/?h=perf_trace-btf_enum

Maybe we can then ask Namhyung to merge from that branch into
perf-tools-next/perf-tools-next.

Namhyung, wdyt? I'll do some more tests and review the code one more
time early tomorrow, but all seems to be work as expected.

The way it was submitted was a bit convoluted, I was expecting for
Howard to have the patches the way I put it in the perf_trace-btf_enum
branch, then use:

⬢[acme@...lbox perf-tools-next]$ rm -f 0*.patch
⬢[acme@...lbox perf-tools-next]$ git format-patch -n HEAD~4
0000-cover-letter.patch
0001-perf-trace-Fix-iteration-of-syscall-ids-in-syscalltb.patch
0002-perf-trace-BTF-based-enum-pretty-printing-for-syscal.patch
0003-perf-trace-Augment-non-syscall-tracepoints-with-enum.patch
0004-perf-trace-Filter-enum-arguments-with-enum-names.patch
⬢[acme@...lbox perf-tools-next]$

And then use:

git send-email --from "Howard Chu <howardchu95@...il.com>" \
                --to "Arnaldo Carvalho de Melo <acme@...nel.org>"
                --cc "Jiri Olsa <jolsa@...nel.org>" \
                --cc "Namhyung Kim <namhyung@...nel.org>" \
                --cc "Ian Rogers <irogers@...gle.com>" \
                --cc "Adrian Hunter <adrian.hunter@...el.com>" \
                --cc "Kan Liang <kan.liang@...ux.intel.com>" \
                --cc linux-kernel@...r.kernel.org \
                --cc linux-perf-users@...r.kernel.org \
                --no-validate \
                --smtp-debug=1 \
                --no-chain-reply-to 0*.patch

After editing 0000-cover-letter.patch to add an explanation about the
series. The version of the series would be in the Subject line for the
cover letter, etc.

Lets try to use this in the next series, concentrating now in reviewing
if what I have at:

https://git.kernel.org/pub/scm/linux/kernel/git/acme/linux.git/log/?h=perf_trace-btf_enum

Can already be merged by Namhyung on perf-tools-next/perf-tools-next.

Thanks a lot!

- Arnaldo

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ