[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20201201132517.GC49333@kernel.org>
Date: Tue, 1 Dec 2020 10:25:17 -0300
From: Arnaldo Carvalho de Melo <acme@...nel.org>
To: Masami Hiramatsu <mhiramat@...nel.org>
Cc: Jiri Olsa <jolsa@...nel.org>, Namhyung Kim <namhyung@...nel.org>,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
Clark Williams <williams@...hat.com>,
linux-perf-users@...r.kernel.org
Subject: perf probe can't remove probes
Hi Masami,
Any idea why listing the source code doesn't work while simply
adding the probe works?
[root@...enth ~]# perf probe verify_pkcs7_signature
Added new event:
probe:verify_pkcs7_signature (on verify_pkcs7_signature)
You can now use it in all perf tools, such as:
perf record -e probe:verify_pkcs7_signature -aR sleep 1
[root@...enth ~]#
[root@...enth ~]# readelf -wi /lib/modules/5.10.0-rc3.bpfsign+/build/vmlinux | grep DW_AT_producer -m2
<1c> DW_AT_producer : (indirect string, offset: 0x50): GNU AS 2.35
<2f> DW_AT_producer : (indirect string, offset: 0x2daf): GNU C89 10.2.1 20201016 (Red Hat 10.2.1-6) -mno-sse -mno-mmx -mno-sse2 -mno-3dnow -mno-avx -m64 -mno-80387 -mno-fp-ret-in-387 -mpreferred-stack-boundary=3 -mskip-rax-setup -mtune=generic -mno-red-zone -mcmodel=kernel -mindirect-branch=thunk-extern -mindirect-branch-register -mrecord-mcount -mfentry -march=x86-64 -g -O2 -std=gnu90 -fno-strict-aliasing -fno-common -fshort-wchar -fno-PIE -falign-jumps=1 -falign-loops=1 -fno-asynchronous-unwind-tables -fno-jump-tables -fno-delete-null-pointer-checks -fno-allow-store-data-races -fstack-protector-strong -fno-strict-overflow -fstack-check=no -fconserve-stack -fcf-protection=none -fno-stack-protector
[root@...enth ~]#
[root@...enth ~]# perf probe -L verify_pkcs7_signature
Specified source line is not found.
Error: Failed to show lines.
[root@...enth ~]# grep verify_pkcs7_signature /proc/kallsyms
ffffffff9f2617b0 T verify_pkcs7_signature
ffffffffa047ac30 r __ksymtab_verify_pkcs7_signature
ffffffffa0482e38 r __kstrtabns_verify_pkcs7_signature
ffffffffa0483b3b r __kstrtab_verify_pkcs7_signature
[root@...enth ~]# perf probe -L verify_pkcs7_signature
Specified source line is not found.
Error: Failed to show lines.
[root@...enth ~]# perf probe -v -L verify_pkcs7_signature
Looking at the vmlinux_path (8 entries long)
Using /lib/modules/5.10.0-rc3.bpfsign+/build/vmlinux for symbols
Open Debuginfo file: /lib/modules/5.10.0-rc3.bpfsign+/build/vmlinux
fname: /home/acme/git/bpf/include/linux/verification.h, lineno:38
New line range: 38 to 2147483647
path: (null)
Specified source line is not found.
Error: Failed to show lines. Reason: No such file or directory (Code: -2)
[root@...enth ~]# readelf -wi /lib/modules/5.10.0-rc3.bpfsign+/build/vmlinux | grep -B2 -A8 verify_pkcs7_signature
<1><1a362a2>: Abbrev Number: 64 (DW_TAG_subprogram)
<1a362a3> DW_AT_external : 1
<1a362a3> DW_AT_name : (indirect string, offset: 0xc2d22): verify_pkcs7_signature
<1a362a7> DW_AT_decl_file : 52
<1a362a8> DW_AT_decl_line : 38
<1a362a9> DW_AT_decl_column : 12
<1a362aa> DW_AT_prototyped : 1
<1a362aa> DW_AT_type : <0x1a3333f>
<1a362ae> DW_AT_sibling : <0x1a36313>
<2><1a362b2>: Abbrev Number: 65 (DW_TAG_formal_parameter)
<1a362b3> DW_AT_name : (indirect string, offset: 0x19ee3d): data
--
<1><24fa79d>: Abbrev Number: 83 (DW_TAG_subprogram)
<24fa79e> DW_AT_external : 1
<24fa79e> DW_AT_name : (indirect string, offset: 0xc2d22): verify_pkcs7_signature
<24fa7a2> DW_AT_decl_file : 218
<24fa7a3> DW_AT_decl_line : 38
<24fa7a4> DW_AT_decl_column : 12
<24fa7a5> DW_AT_prototyped : 1
<24fa7a5> DW_AT_type : <0x24e1e05>
<24fa7a9> DW_AT_sibling : <0x24fa80e>
<2><24fa7ad>: Abbrev Number: 41 (DW_TAG_formal_parameter)
<24fa7ae> DW_AT_name : (indirect string, offset: 0x19ee3d): data
--
<26258b8> DW_AT_location : 9 byte block: 3 0 0 0 0 0 0 0 0 (DW_OP_addr: 0)
<1><26258c2>: Abbrev Number: 116 (DW_TAG_variable)
<26258c3> DW_AT_name : (indirect string, offset: 0x10523f): __UNIQUE_ID___addressable_verify_pkcs7_signature164
<26258c7> DW_AT_decl_file : 1
<26258c8> DW_AT_decl_line : 305
<26258ca> DW_AT_decl_column : 1
<26258cb> DW_AT_type : <0x2620ca6>
<26258cf> DW_AT_location : 9 byte block: 3 0 0 0 0 0 0 0 0 (DW_OP_addr: 0)
<1><26258d9>: Abbrev Number: 117 (DW_TAG_subprogram)
<26258da> DW_AT_external : 1
<26258da> DW_AT_name : (indirect string, offset: 0x1050d9): pkcs7_free_message
--
<1><2625c2e>: Abbrev Number: 120 (DW_TAG_subprogram)
<2625c2f> DW_AT_external : 1
<2625c2f> DW_AT_name : (indirect string, offset: 0xc2d22): verify_pkcs7_signature
<2625c33> DW_AT_decl_file : 1
<2625c34> DW_AT_decl_line : 282
<2625c36> DW_AT_decl_column : 5
<2625c37> DW_AT_prototyped : 1
<2625c37> DW_AT_type : <0x26209e9>
<2625c3b> DW_AT_low_pc : 0xffffffff812617b0
<2625c43> DW_AT_high_pc : 0x73
<2625c4b> DW_AT_frame_base : 1 byte block: 9c (DW_OP_call_frame_cfa)
--
<1><495560e>: Abbrev Number: 68 (DW_TAG_subprogram)
<495560f> DW_AT_external : 1
<495560f> DW_AT_name : (indirect string, offset: 0xc2d22): verify_pkcs7_signature
<4955613> DW_AT_decl_file : 61
<4955614> DW_AT_decl_line : 38
<4955615> DW_AT_decl_column : 12
<4955616> DW_AT_prototyped : 1
<4955616> DW_AT_type : <0x49519fd>
<495561a> DW_AT_sibling : <0x495567f>
<2><495561e>: Abbrev Number: 74 (DW_TAG_formal_parameter)
<495561f> DW_AT_name : (indirect string, offset: 0x19ee3d): data
Powered by blists - more mailing lists