This is the mail archive of the systemtap@sourceware.org mailing list for the systemtap project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug runtime/18944] New: the ioblock.stp tapset fails to compile on RHEL7


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

            Bug ID: 18944
           Summary: the ioblock.stp tapset fails to compile on RHEL7
           Product: systemtap
           Version: unspecified
            Status: NEW
          Severity: normal
          Priority: P2
         Component: runtime
          Assignee: systemtap at sourceware dot org
          Reporter: dsmith at redhat dot com
  Target Milestone: ---

On rhel7 (3.10.0-305.el7.x86_64), the buildok testsuite gets 3 failures from
the ioblock tapset:

FAIL: buildok/ioblock-all-probes.stp
FAIL: buildok/ioblock-detailed.stp
FAIL: buildok/ioblock-embedded.stp

The errors are all the same:

====
Running ../../src/testsuite/buildok/ioblock-all-probes.stp
starting ../../src/testsuite/buildok/ioblock-all-probes.stp
spawn1 stap -wp4 ../../src/testsuite/buildok/ioblock-all-probes.stp
spawn stap -wp4 ../../src/testsuite/buildok/ioblock-all-probes.stp^M
/tmp/stap5pFzCi/stap_1a6f9b48025b6d740d13db61b520d558_2603_src.c:38:0: error:
"REQ_WRITE" redefined [-Werror]^M
 #define REQ_WRITE               (1 << BIO_RW)^M
 ^^M
In file included from include/linux/fs.h:29:0,^M
                 from include/linux/ftrace.h:18,^M
                 from include/linux/kprobes.h:42,^M
                 from /usr/local/share/systemtap/runtime/linux/runtime.h:21,^M
                 from /usr/local/share/systemtap/runtime/runtime.h:24,^M
                 from
/tmp/stap5pFzCi/stap_1a6f9b48025b6d740d13db61b520d558_2603_src.c:25:^M
include/linux/blk_types.h:212:0: note: this is the location of the previous
definition^M
 #define REQ_WRITE  (1ULL << __REQ_WRITE)^M
 ^^M
cc1: all warnings being treated as errors^M
make[4]: *** [/tmp/stap5pFzCi/stap_1a6f9b48025b6d740d13db61b520d558_2603_src.o]
Error 1^M
make[3]: *** [_module_/tmp/stap5pFzCi] Error 2^M
WARNING: kbuild exited with status: 2^M
Pass 4: compilation failed.  [man error::pass4]^M
====

What's odd here is that the ioblock tapset has code to deal with this:

====
%{
#include <linux/bio.h>
#include <linux/genhd.h>
#ifdef STAPCONF_BLK_TYPES
#include <linux/blk_types.h>
#else
#define REQ_WRITE               (1 << BIO_RW)
#endif
%}
====

STAPCONF_BLK_TYPES is supposed to get defined by one of our "autoconf" like
tests when linux/blk_types.h is present and usable in the kernel source.

However, when this autoconf test is run, we get this error:

====
In file included from
/usr/local/share/systemtap/runtime/linux/autoconf-blk-types.c:1:0:
include/linux/blk_types.h:113:2: error: expected specifier-qualifier-list
before âRH_KABI_REPLACEâ
  RH_KABI_REPLACE(void *rh_reserved1, struct bio_aux *bio_aux)
  ^
====

So, blk_types.h is present, but uses a Red Hat-only macro that comes from
/usr/src/kernel/KVER/include/linux/rh_kabi.h. In a more perfect work
blk_types.h would have included this file itself.

We'll need to rework the runtime/linux/autoconf-blk-types.c file to handle
this.

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

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]