summaryrefslogtreecommitdiffstats
path: root/runtime/transport/symbols.c
diff options
context:
space:
mode:
authorSrikar Dronamraju <srikar@linux.vnet.ibm.com>2008-05-23 13:14:30 +0530
committerwenji <wjhuang@dhcp-beijing-cdc-10-182-120-233.cn.oracle.com>2008-05-25 21:33:34 -0400
commit956a6c27f13cc4b90d674ddafb5b08f7921b9121 (patch)
treec236ea41bd3e42ee2956b99faac3c42380c6226c /runtime/transport/symbols.c
parent11e837b73f6533df0977609bea1952fa8ae56718 (diff)
downloadsystemtap-steved-956a6c27f13cc4b90d674ddafb5b08f7921b9121.tar.gz
systemtap-steved-956a6c27f13cc4b90d674ddafb5b08f7921b9121.tar.xz
systemtap-steved-956a6c27f13cc4b90d674ddafb5b08f7921b9121.zip
Srinivasa DS <srinivasa@in.ibm.com>,PR6429 Inerim fix to avoid compilation error of systemtap module
Diffstat (limited to 'runtime/transport/symbols.c')
-rw-r--r--runtime/transport/symbols.c20
1 files changed, 20 insertions, 0 deletions
diff --git a/runtime/transport/symbols.c b/runtime/transport/symbols.c
index 087bf893..ec047922 100644
--- a/runtime/transport/symbols.c
+++ b/runtime/transport/symbols.c
@@ -196,7 +196,11 @@ static int _stp_init_kernel_symbols(void)
_stp_num_modules = 1;
/* Note: this mapping is used by kernel/_stext pseudo-relocations. */
+ #ifdef __powerpc__
+ _stp_modules[0]->text = _stp_kallsyms_lookup_name(".__start");
+ #else
_stp_modules[0]->text = _stp_kallsyms_lookup_name("_stext");
+ #endif
if (_stp_modules[0]->text == 0) {
_dbug("Lookup of _stext failed. Exiting.\n");
return -1;
@@ -399,6 +403,22 @@ static int _stp_section_is_interesting(const char *name)
return ret;
}
+#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,25)
+struct module_sect_attr
+{
+ struct module_attribute mattr;
+ char *name;
+ unsigned long address;
+};
+
+struct module_sect_attrs
+{
+ struct attribute_group grp;
+ unsigned int nsections;
+ struct module_sect_attr attrs[0];
+};
+#endif
+
/* Create a new _stp_module and load the symbols */
static struct _stp_module *_stp_load_module_symbols(struct module *mod)
{