Bug 1546563

Summary: systemtap breaks with kernel 4.15 due to apparent timer changes
Product: [Fedora] Fedora Reporter: Evan Klitzke <evan>
Component: systemtapAssignee: Frank Ch. Eigler <fche>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 27CC: brolley, dsmith, fche, jistone, lberk, mjw, scox, sergey.avseyev, wcohen
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: systemtap-3.2-3.fc27 systemtap-3.2-7.fc26 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2018-03-06 17:29:25 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Evan Klitzke 2018-02-18 19:00:38 UTC
This morning I upgraded my kernel package from kernel-4.14.18-300.fc27.x86_64 to kernel-4.15.3-300.fc27.x86_64. I am still using systemtap package version systemtap-3.2-2.fc27.x86_64. I am now getting script failures due to an apparent change in the kernel timer APIs. I believe this is related to upstream kernel git commit 919b250f8570618e84af544c3e18dad5210eb9b6

The exact error I am seeing:

In file included from /usr/share/systemtap/runtime/transport/transport.c:65:0,
                 from /usr/share/systemtap/runtime/linux/print.c:17,
                 from /usr/share/systemtap/runtime/print.c:17,
                 from /usr/share/systemtap/runtime/runtime_context.h:22,
                 from /tmp/stap8wQmrP/stap_cbb6564739d1b29e282cdd69510ea1fe_57058_src.c:3085:
/usr/share/systemtap/runtime/transport/relay_v2.c: In function ‘__stp_relay_timer_init’:
/usr/share/systemtap/runtime/transport/relay_v2.c:154:2: error: implicit declaration of function ‘init_timer’; did you mean ‘init_timers’? [-Werror=implicit-function-declaration]
  init_timer(&_stp_relay_data.timer);
  ^~~~~~~~~~
  init_timers
/usr/share/systemtap/runtime/transport/relay_v2.c:156:33: error: assignment from incompatible pointer type [-Werror=incompatible-pointer-types]
  _stp_relay_data.timer.function = __stp_relay_wakeup_timer;
                                 ^
/usr/share/systemtap/runtime/transport/relay_v2.c:157:23: error: ‘struct timer_list’ has no member named ‘data’
  _stp_relay_data.timer.data = 0;
                       ^
In file included from /usr/share/systemtap/runtime/linux/print.c:17:0,
                 from /usr/share/systemtap/runtime/print.c:17,
                 from /usr/share/systemtap/runtime/runtime_context.h:22,
                 from /tmp/stap8wQmrP/stap_cbb6564739d1b29e282cdd69510ea1fe_57058_src.c:3085:
/usr/share/systemtap/runtime/transport/transport.c: In function ‘_stp_attach’:
/usr/share/systemtap/runtime/transport/transport.c:328:31: error: assignment from incompatible pointer type [-Werror=incompatible-pointer-types]
  _stp_ctl_work_timer.function = _stp_ctl_work_callback;
                               ^
/usr/share/systemtap/runtime/transport/transport.c:329:21: error: ‘struct timer_list’ has no member named ‘data’
  _stp_ctl_work_timer.data= 0;
                     ^
In file included from /tmp/stap8wQmrP/stap_cbb6564739d1b29e282cdd69510ea1fe_57058_src.c:4269:0:
/usr/share/systemtap/runtime/time.c: In function ‘__stp_init_time’:
/usr/share/systemtap/runtime/time.c:205:26: error: assignment from incompatible pointer type [-Werror=incompatible-pointer-types]
     time->timer.function = __stp_time_timer_callback;
                          ^
cc1: all warnings being treated as errors
make[1]: *** [scripts/Makefile.build:316: /tmp/stap8wQmrP/stap_cbb6564739d1b29e282cdd69510ea1fe_57058_src.o] Error 1
make: *** [Makefile:1512: _module_/tmp/stap8wQmrP] Error 2
WARNING: kbuild exited with status: 2
Pass 4: compilation failed.  [man error::pass4]

Comment 1 David Smith 2018-02-20 17:58:08 UTC
I'm not seeing this error on 4.15.3-300.fc27.x86_64 with HEAD systemtap. Have you got a small reproducer?

I believe I fixed this in upstream commit 382a60e6a76ee and we just need to push a new version to f27 (but that reproducer would certainly confirm that).

Comment 2 Sergey Avseyev 2018-02-21 12:21:19 UTC
Is it possible to include patch from upstream?
https://sourceware.org/git/gitweb.cgi?p=systemtap.git;a=commitdiff;h=fbb26e17a

Also upstream ticket: https://sourceware.org/bugzilla/show_bug.cgi?id=22551

Comment 3 Sergey Avseyev 2018-02-22 10:16:59 UTC
I have applied that patch to f27 branch myself, and it works.

Here is PR: https://src.fedoraproject.org/rpms/systemtap/pull-request/2
Koji build: https://koji.fedoraproject.org/koji/taskinfo?taskID=25231331

Comment 4 Fedora Update System 2018-02-22 16:03:25 UTC
systemtap-3.2-7.fc26 has been submitted as an update to Fedora 26. https://bodhi.fedoraproject.org/updates/FEDORA-2018-abaa5db184

Comment 5 Fedora Update System 2018-02-23 16:27:07 UTC
systemtap-3.2-7.fc26 has been pushed to the Fedora 26 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2018-abaa5db184

Comment 6 Fedora Update System 2018-02-27 18:07:25 UTC
systemtap-3.2-3.fc27 has been submitted as an update to Fedora 27. https://bodhi.fedoraproject.org/updates/FEDORA-2018-8ef58b06d9

Comment 7 Fedora Update System 2018-02-28 18:09:06 UTC
systemtap-3.2-3.fc27 has been pushed to the Fedora 27 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2018-8ef58b06d9

Comment 8 Fedora Update System 2018-03-06 17:29:25 UTC
systemtap-3.2-3.fc27 has been pushed to the Fedora 27 stable repository. If problems still persist, please make note of it in this bug report.

Comment 9 Fedora Update System 2018-03-20 17:27:55 UTC
systemtap-3.2-7.fc26 has been pushed to the Fedora 26 stable repository. If problems still persist, please make note of it in this bug report.