public inbox for systemtap@sourceware.org
 help / color / mirror / Atom feed
From: "wcohen at redhat dot com" <sourceware-bugzilla@sourceware.org>
To: systemtap@sourceware.org
Subject: [Bug runtime/30831] Systemtap scripts fail to compile on newest  linux 6.6 kernels
Date: Thu, 07 Sep 2023 19:23:40 +0000	[thread overview]
Message-ID: <bug-30831-6586-Xv87FNSKgD@http.sourceware.org/bugzilla/> (raw)
In-Reply-To: <bug-30831-6586@http.sourceware.org/bugzilla/>

https://sourceware.org/bugzilla/show_bug.cgi?id=30831

William Cohen <wcohen at redhat dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Summary|The do_each_thread macro    |Systemtap scripts fail to
                   |has been removed from       |compile on newest  linux
                   |newest  linux 6.6 kernels   |6.6 kernels

--- Comment #1 from William Cohen <wcohen at redhat dot com> ---
With minor tweaks in the runtime to use the for_each_process_thread macro. Get
a new set of errors when the generated C code is compiled:

$ sudo  ../install/bin/stap  -e 'probe begin {printf("hi!\n");exit()}'
In file included from
/home/wcohen/systemtap_write/install/share/systemtap/runtime/runtime.h:26,
                 from
/tmp/stapGSFULg/stap_9dfacd1f722045d5e3bceb982809b15d_1345_src.c:21:
/home/wcohen/systemtap_write/install/share/systemtap/runtime/stp_task_work.c:
In function ‘stp_task_work_add’:
/home/wcohen/systemtap_write/install/share/systemtap/runtime/stp_task_work.c:9:102:
error: implicit conversion from ‘enum <anonymous>’ to ‘enum
task_work_notify_mode’ [-Werror=enum-conversion]
    9 | apper(int, (* (task_work_add_fn)kallsyms_task_work_add)((a), (b), (c)))
      |                                                                   ^~~

/home/wcohen/systemtap_write/install/share/systemtap/runtime/linux/runtime.h:298:21:
note: in definition of macro ‘ibt_wrapper’
  298 |   rettype retval = (function);                  \
      |                     ^~~~~~~~
/home/wcohen/systemtap_write/install/share/systemtap/runtime/stp_task_work.c:92:14:
note: in expansion of macro ‘task_work_add’
   92 |         rc = task_work_add(task, twork, true);
      |              ^~~~~~~~~~~~~
In file included from ./include/linux/srcu.h:21,
                 from ./include/linux/notifier.h:16,
                 from ./arch/x86/include/asm/uprobes.h:13,
                 from ./include/linux/uprobes.h:49,
                 from ./include/linux/mm_types.h:16,
                 from ./include/linux/mmzone.h:22,
                 from ./include/linux/gfp.h:7,
                 from
/home/wcohen/systemtap_write/install/share/systemtap/runtime/linux/runtime_defines.h:20,
                 from
/home/wcohen/systemtap_write/install/share/systemtap/runtime/runtime_defines.h:8,
                 from
/tmp/stapGSFULg/stap_9dfacd1f722045d5e3bceb982809b15d_1345_src.c:12:
In function ‘stp_synchronize_sched’,
    inlined from ‘_stp_cleanup_and_exit.part.0’ at
/home/wcohen/systemtap_write/install/share/systemtap/runtime/transport/transport.c:412:25:
./include/linux/workqueue.h:631:9: error: call to
‘__warn_flushing_systemwide_wq’ declared with attribute warning: Please avoid
flushing system-wide workqueues. [-Werror=attribute-warning]
  631 |         __warn_flushing_systemwide_wq();                               
\
      |         ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/home/wcohen/systemtap_write/install/share/systemtap/runtime/linux/runtime.h:407:3:
note: in expansion of macro ‘flush_scheduled_work’
  407 |   flush_scheduled_work();
      |   ^~~~~~~~~~~~~~~~~~~~
In function ‘stp_synchronize_sched’,
    inlined from ‘systemtap_module_exit’ at
/tmp/stapGSFULg/stap_9dfacd1f722045d5e3bceb982809b15d_1345_src.c:472:3,
    inlined from ‘_stp_cleanup_and_exit.part.0’ at
/home/wcohen/systemtap_write/install/share/systemtap/runtime/transport/transport.c:420:4:
./include/linux/workqueue.h:631:9: error: call to
‘__warn_flushing_systemwide_wq’ declared with attribute warning: Please avoid
flushing system-wide workqueues. [-Werror=attribute-warning]
  631 |         __warn_flushing_systemwide_wq();                               
\
      |         ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/home/wcohen/systemtap_write/install/share/systemtap/runtime/linux/runtime.h:407:3:
note: in expansion of macro ‘flush_scheduled_work’
  407 |   flush_scheduled_work();
      |   ^~~~~~~~~~~~~~~~~~~~
In function ‘stp_synchronize_sched’,
    inlined from ‘systemtap_module_exit’ at
/tmp/stapGSFULg/stap_9dfacd1f722045d5e3bceb982809b15d_1345_src.c:485:3,
    inlined from ‘_stp_cleanup_and_exit.part.0’ at
/home/wcohen/systemtap_write/install/share/systemtap/runtime/transport/transport.c:420:4:
./include/linux/workqueue.h:631:9: error: call to
‘__warn_flushing_systemwide_wq’ declared with attribute warning: Please avoid
flushing system-wide workqueues. [-Werror=attribute-warning]
  631 |         __warn_flushing_systemwide_wq();                               
\
      |         ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/home/wcohen/systemtap_write/install/share/systemtap/runtime/linux/runtime.h:407:3:
note: in expansion of macro ‘flush_scheduled_work’
  407 |   flush_scheduled_work();
      |   ^~~~~~~~~~~~~~~~~~~~
In function ‘stp_synchronize_sched’,
    inlined from ‘systemtap_module_exit’ at
/tmp/stapGSFULg/stap_9dfacd1f722045d5e3bceb982809b15d_1345_src.c:488:3,
    inlined from ‘_stp_cleanup_and_exit.part.0’ at
/home/wcohen/systemtap_write/install/share/systemtap/runtime/transport/transport.c:420:4:
./include/linux/workqueue.h:631:9: error: call to
‘__warn_flushing_systemwide_wq’ declared with attribute warning: Please avoid
flushing system-wide workqueues. [-Werror=attribute-warning]
  631 |         __warn_flushing_systemwide_wq();                               
\
      |         ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/home/wcohen/systemtap_write/install/share/systemtap/runtime/linux/runtime.h:407:3:
note: in expansion of macro ‘flush_scheduled_work’
  407 |   flush_scheduled_work();
      |   ^~~~~~~~~~~~~~~~~~~~
In function ‘stp_synchronize_sched’,
    inlined from ‘systemtap_module_init’ at
/tmp/stapGSFULg/stap_9dfacd1f722045d5e3bceb982809b15d_1345_src.c:420:3,
    inlined from ‘_stp_handle_start’ at
/home/wcohen/systemtap_write/install/share/systemtap/runtime/transport/transport.c:264:13,
    inlined from ‘_stp_ctl_write_cmd’ at
/home/wcohen/systemtap_write/install/share/systemtap/runtime/transport/control.c:82:17:
./include/linux/workqueue.h:631:9: error: call to
‘__warn_flushing_systemwide_wq’ declared with attribute warning: Please avoid
flushing system-wide workqueues. [-Werror=attribute-warning]
  631 |         __warn_flushing_systemwide_wq();                               
\
      |         ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/home/wcohen/systemtap_write/install/share/systemtap/runtime/linux/runtime.h:407:3:
note: in expansion of macro ‘flush_scheduled_work’
  407 |   flush_scheduled_work();
      |   ^~~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
make[1]: *** [scripts/Makefile.build:243:
/tmp/stapGSFULg/stap_9dfacd1f722045d5e3bceb982809b15d_1345_src.o] Error 1
make: *** [Makefile:1931: /tmp/stapGSFULg] Error 2
WARNING: kbuild exited with status: 2
Pass 4: compilation failed.  [man error::pass4]

-- 
You are receiving this mail because:
You are the assignee for the bug.

  reply	other threads:[~2023-09-07 19:23 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-09-07 17:46 [Bug runtime/30831] New: The do_each_thread macro has been removed from " wcohen at redhat dot com
2023-09-07 19:23 ` wcohen at redhat dot com [this message]
2023-09-08  2:49 ` [Bug runtime/30831] Systemtap scripts fail to compile on " wcohen at redhat dot com
2023-09-18 13:46 ` wcohen at redhat dot com
2023-09-18 13:51 ` wcohen at redhat dot com
2023-09-27 14:24 ` wcohen at redhat dot com
2023-09-27 20:03 ` wcohen at redhat dot com
2023-11-23 15:16   ` Tetsuo Handa
2023-12-13 14:47     ` William Cohen
2023-12-17 10:41       ` Tetsuo Handa

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=bug-30831-6586-Xv87FNSKgD@http.sourceware.org/bugzilla/ \
    --to=sourceware-bugzilla@sourceware.org \
    --cc=systemtap@sourceware.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).