systemtap weirdness under 64-bit ubuntu 11.10
Robert P. J. Day
rpjday at crashcourse.ca
Tue Apr 10 02:21:46 UTC 2012
time for a quick observation before i pack it in for the evening but
i'm trying to test a basic systemtap example on my 64-bit ubuntu 11.10
system, running a hand-rolled 3.4.0-rc2 kernel and i just don't see
how this can work.
i'm running under the newly-built 3.4.0-rc2 kernel, and if i try to
run the first example suggested by the systemtap tutorial:
$ stap -v -e 'probe vfs.read {printf("read performed\n"); exit()}'
i get:
=== begin ===
In file included from /usr/share/systemtap/runtime/transport/transport.c:53:0,
from /usr/share/systemtap/runtime/print.c:18,
from /usr/share/systemtap/runtime/runtime.h:128,
from /tmp/stapKJMnAW/stap_2d68bb2917795f0a4634de4faf69cab9_869.c:55:
/usr/share/systemtap/runtime/transport/relay_v2.c:242:2: error: initialization from incompatible pointer type [-Werror]
/usr/share/systemtap/runtime/transport/relay_v2.c:242:2: error: (near initialization for ‘__stp_relay_callbacks.create_buf_file’) [-Werror]
In file included from /usr/share/systemtap/runtime/print.c:18:0,
from /usr/share/systemtap/runtime/runtime.h:128,
from /tmp/stapKJMnAW/stap_2d68bb2917795f0a4634de4faf69cab9_869.c:55:
/usr/share/systemtap/runtime/transport/transport.c: In function ‘_stp_get_root_dir’:
/usr/share/systemtap/runtime/transport/transport.c:380:8: error: ‘struct hlist_head’ has no member named ‘next’
In file included from /tmp/stapKJMnAW/stap_2d68bb2917795f0a4634de4faf69cab9_869.c:57:0:
/usr/share/systemtap/runtime/stat.c: In function ‘_stp_stat_get’:
/usr/share/systemtap/runtime/stat.c:213:2: error: ‘cpu_possible_map’ undeclared (first use in this function)
/usr/share/systemtap/runtime/stat.c:213:2: note: each undeclared identifier is reported only once for each function it appears in
/usr/share/systemtap/runtime/stat.c: In function ‘_stp_stat_clear’:
/usr/share/systemtap/runtime/stat.c:248:2: error: ‘cpu_possible_map’ undeclared (first use in this function)
cc1: all warnings being treated as errors
make[1]: *** [/tmp/stapKJMnAW/stap_2d68bb2917795f0a4634de4faf69cab9_869.o] Error 1
make: *** [_module_/tmp/stapKJMnAW] Error 2
Pass 4: compilation failed. Try again with another '--vp 0001' option.
=== end ===
among other things, this confuses me:
/usr/share/systemtap/runtime/transport/transport.c:380:8: error: ‘struct hlist_head’ has no member named ‘next’
that's exactly correct -- that line in transport.c is:
sb = list_entry(fs->fs_supers.next, struct super_block,
s_instances);
where "fs" is of type "struct file_system_type" and is defined in the
kernel source as:
struct file_system_type {
const char *name;
int fs_flags;
struct dentry *(*mount) (struct file_system_type *, int,
const char *, void *);
void (*kill_sb) (struct super_block *);
struct module *owner;
struct file_system_type * next;
struct hlist_head fs_supers; <--- there
... snip ...
and hlist_head is defined in types.h as:
struct hlist_head {
struct hlist_node *first;
};
so there really is no "next" member field to that structure. so how
does the source file transport.c make any sense? the error message
above is exactly correct.
so what am i missing here?
rday
--
========================================================================
Robert P. J. Day Ottawa, Ontario, CANADA
http://crashcourse.ca
Twitter: http://twitter.com/rpjday
LinkedIn: http://ca.linkedin.com/in/rpjday
========================================================================
More information about the ubuntu-users
mailing list