* [Bug translator/31404] New: Systemtap unable to find kernel.trace("*") probe points on Fedora rawhide Linux 6.8 kernels
@ 2024-02-21 14:47 wcohen at redhat dot com
2024-02-28 14:49 ` [Bug translator/31404] " wcohen at redhat dot com
2024-02-28 15:52 ` wcohen at redhat dot com
0 siblings, 2 replies; 3+ messages in thread
From: wcohen at redhat dot com @ 2024-02-21 14:47 UTC (permalink / raw)
To: systemtap
https://sourceware.org/bugzilla/show_bug.cgi?id=31404
Bug ID: 31404
Summary: Systemtap unable to find kernel.trace("*") probe
points on Fedora rawhide Linux 6.8 kernels
Product: systemtap
Version: unspecified
Status: NEW
Severity: normal
Priority: P2
Component: translator
Assignee: systemtap at sourceware dot org
Reporter: wcohen at redhat dot com
Target Milestone: ---
When reviewing the "make installcheck" results on Fedora rawhide. I found that
a number of the tests using the tracepoint probe points were failing. For
example:
Running
/home/wcohen/systemtap_write/systemtap/testsuite/systemtap.base/bz1027459.exp
...
spawn stap -wP
/home/wcohen/systemtap_write/systemtap/testsuite/systemtap.base/bz1027459.stp
semantic error: while resolving probe point: identifier 'kernel' at
/home/wcohen/systemtap_write/install/share/systemtap/tapset/linux/sysc_clone.stp:131:26
source: probe tp_syscall.clone = kernel.trace("sys_enter")
^
semantic error: no match
Pass 2: analysis failed. [man error::pass2]
Number of similar error messages suppressed: 2.
Rerun with -v to see them.
FAIL: bz1027459 -p5 (0)
The probe point can be seen with "perf list tracepoint", but doesn't show up
with systemtap:
[wcohen@rawhide systemtap]$ uname -a
Linux rawhide 6.8.0-0.rc5.41.fc41.x86_64 #1 SMP PREEMPT_DYNAMIC Mon Feb 19
14:05:40 UTC 2024 x86_64 GNU/Linux
[wcohen@rawhide systemtap]$ sudo perf list tracepoint |grep raw
[sudo] password for wcohen:
raw_syscalls:sys_enter [Tracepoint event]
raw_syscalls:sys_exit [Tracepoint event]
[wcohen@rawhide systemtap]$ ../install/bin/stap -L 'kernel.trace("sys_enter")'
[wcohen@rawhide systemtap]$
On Fedora 39 systemtap can find the tracepoints:
wcohen@fedora39:~/systemtap_write/systemtap$ uname -a
Linux fedora39 6.7.5-200.fc39.x86_64 #1 SMP PREEMPT_DYNAMIC Sat Feb 17 17:20:08
UTC 2024 x86_64 GNU/Linux
wcohen@fedora39:~/systemtap_write/systemtap$ sudo perf list tracepoint |grep
raw
raw_syscalls:sys_enter [Tracepoint event]
raw_syscalls:sys_exit [Tracepoint event]
wcohen@fedora39:~/systemtap_write/systemtap$ ../install/bin/stap -L
'kernel.trace("sys_enter")'
kernel.trace("raw_syscalls:sys_enter") $regs:struct pt_regs* $id:long int
--
You are receiving this mail because:
You are the assignee for the bug.
^ permalink raw reply [flat|nested] 3+ messages in thread
* [Bug translator/31404] Systemtap unable to find kernel.trace("*") probe points on Fedora rawhide Linux 6.8 kernels
2024-02-21 14:47 [Bug translator/31404] New: Systemtap unable to find kernel.trace("*") probe points on Fedora rawhide Linux 6.8 kernels wcohen at redhat dot com
@ 2024-02-28 14:49 ` wcohen at redhat dot com
2024-02-28 15:52 ` wcohen at redhat dot com
1 sibling, 0 replies; 3+ messages in thread
From: wcohen at redhat dot com @ 2024-02-28 14:49 UTC (permalink / raw)
To: systemtap
https://sourceware.org/bugzilla/show_bug.cgi?id=31404
William Cohen <wcohen at redhat dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |ASSIGNED
--- Comment #1 from William Cohen <wcohen at redhat dot com> ---
Was able to compare the tracequery_kmod_1 builds between fedora 39 and rawhide.
The problem on rawhide is that the additional -Werror-missing-prototypes
option is being passed into rawhide build which causes:
$ ../install/bin/stap --disable-cache -k -vvvvv -L
'kernel.trace("sys_enter")' >& rawhide_log
have /tmp/stapypAUhu
make -C /lib/modules/$(uname -r)/build M=/tmp/stapypAUhu/tracequery_kmod_1
modules
make -C /lib/modules/$(uname -r)/build M=/tmp/stapypAUhu/tracequery_kmod_1
modules
make: Entering directory
'/usr/src/kernels/6.8.0-0.rc5.20240222git39133352cbed.44.fc41.x86_64'
CC [M] /tmp/stapypAUhu/tracequery_kmod_1/tracequery_kmod_1_2.o
/tmp/stapypAUhu/tracequery_kmod_1/tracequery_kmod_1_2.c:51:8: error: no
previous prototype for ‘stapprobe_read_msr’ [-Werror=missing-prototypes]
51 | void stapprobe_##name(proto) {}
| ^~~~~~~~~~
./include/linux/tracepoint.h:555:9: note: in expansion of macro ‘DECLARE_TRACE’
555 | DECLARE_TRACE(name, PARAMS(proto), PARAMS(args))
| ^~~~~~~~~~~~~
./arch/x86/include/asm/msr-trace.h:40:1: note: in expansion of macro
‘DEFINE_EVENT’
40 | DEFINE_EVENT(msr_trace_class, read_msr,
| ^~~~~~~~~~~~
/tmp/stapypAUhu/tracequery_kmod_1/tracequery_kmod_1_2.c:51:8: error: no
previous prototype for ‘stapprobe_write_msr’ [-Werror=missing-prototypes]
51 | void stapprobe_##name(proto) {}
| ^~~~~~~~~~
./include/linux/tracepoint.h:555:9: note: in expansion of macro ‘DECLARE_TRACE’
555 | DECLARE_TRACE(name, PARAMS(proto), PARAMS(args))
| ^~~~~~~~~~~~~
./arch/x86/include/asm/msr-trace.h:45:1: note: in expansion of macro
‘DEFINE_EVENT’
45 | DEFINE_EVENT(msr_trace_class, write_msr,
| ^~~~~~~~~~~~
/tmp/stapypAUhu/tracequery_kmod_1/tracequery_kmod_1_2.c:51:8: error: no
previous prototype for ‘stapprobe_rdpmc’ [-Werror=missing-prototypes]
51 | void stapprobe_##name(proto) {}
| ^~~~~~~~~~
./include/linux/tracepoint.h:555:9: note: in expansion of macro ‘DECLARE_TRACE’
555 | DECLARE_TRACE(name, PARAMS(proto), PARAMS(args))
| ^~~~~~~~~~~~~
./arch/x86/include/asm/msr-trace.h:50:1: note: in expansion of macro
‘DEFINE_EVENT’
50 | DEFINE_EVENT(msr_trace_class, rdpmc,
| ^~~~~~~~~~~~
cc1: all warnings being treated as errors
make[2]: *** [scripts/Makefile.build:243:
/tmp/stapypAUhu/tracequery_kmod_1/tracequery_kmod_1_2.o] Error 1
make[1]: ***
[/usr/src/kernels/6.8.0-0.rc5.20240222git39133352cbed.44.fc41.x86_64/Makefile:1939:
/tmp/stapypAUhu/tracequery_kmod_1] Error 2
make: *** [Makefile:252: __sub-make] Error 2
make: Leaving directory
'/usr/src/kernels/6.8.0-0.rc5.20240222git39133352cbed.44.fc41.x86_64'
There looks to be a couple ways to fix this.
1) kernel git commit 1c57b9f63ab34f01b8c73731cc0efacb5a9a2f16 adds a "static"
before the function definition.
2) kernel git commit c97dac57c804b53eab492ca0230d86356729d633 adds following
line to Kbuild to remove the -Wmissing-prototypes:
+KBUILD_CFLAGS := $(filter-out -Wmissing-prototypes -Wmissing-declarations,
$(KBUILD_CFLAGS))
+
--
You are receiving this mail because:
You are the assignee for the bug.
^ permalink raw reply [flat|nested] 3+ messages in thread
* [Bug translator/31404] Systemtap unable to find kernel.trace("*") probe points on Fedora rawhide Linux 6.8 kernels
2024-02-21 14:47 [Bug translator/31404] New: Systemtap unable to find kernel.trace("*") probe points on Fedora rawhide Linux 6.8 kernels wcohen at redhat dot com
2024-02-28 14:49 ` [Bug translator/31404] " wcohen at redhat dot com
@ 2024-02-28 15:52 ` wcohen at redhat dot com
1 sibling, 0 replies; 3+ messages in thread
From: wcohen at redhat dot com @ 2024-02-28 15:52 UTC (permalink / raw)
To: systemtap
https://sourceware.org/bugzilla/show_bug.cgi?id=31404
William Cohen <wcohen at redhat dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Resolution|--- |FIXED
Status|ASSIGNED |RESOLVED
--- Comment #2 from William Cohen <wcohen at redhat dot com> ---
This issue has been fixed with the following commit:
commit 7765366ae09859cf68d55782185ec3ceb9a04ed5 (HEAD -> master, origin/master,
origin/HEAD)
Author: William Cohen <wcohen@redhat.com>
Date: Wed Feb 28 10:43:51 2024 -0500
PR31404: Make tracepoint queries work with gcc14
The Fedora rawhide Linux 6.8 kernels are built with gcc14 and include
-Wmissing-prototypes in the CFLAGS options. When building the
kernel modules to query the available tracepoints errors occur
resulting in kernel tracepoints being found. The fix is to
include a function declaration before the function definition
in the DECLARE_TRACE macro.
--
You are receiving this mail because:
You are the assignee for the bug.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2024-02-28 15:52 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-02-21 14:47 [Bug translator/31404] New: Systemtap unable to find kernel.trace("*") probe points on Fedora rawhide Linux 6.8 kernels wcohen at redhat dot com
2024-02-28 14:49 ` [Bug translator/31404] " wcohen at redhat dot com
2024-02-28 15:52 ` wcohen at redhat dot com
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).