summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFrank Ch. Eigler <fche@elastic.org>2009-12-20 22:28:50 -0500
committerFrank Ch. Eigler <fche@elastic.org>2009-12-20 22:28:50 -0500
commitf0da6b3c8ba5a26f983714ddfcfd559ea05af5e3 (patch)
treebb70d607a1b2d9617445b7f205a6d0d8a67b0132
parenta87e40ba65ede2a884e4bce31ba7a1d87e71f981 (diff)
downloadsystemtap-steved-f0da6b3c8ba5a26f983714ddfcfd559ea05af5e3.tar.gz
systemtap-steved-f0da6b3c8ba5a26f983714ddfcfd559ea05af5e3.tar.xz
systemtap-steved-f0da6b3c8ba5a26f983714ddfcfd559ea05af5e3.zip
runtime: more build fix for non-utrace kernels
* runtime/stack-i386.c (_stp_stack_print): Make call to uprobe_get_pc() conditional on CONFIG_UTRACE. * runtime/stack-x86_64.c: Ditto.
-rw-r--r--runtime/stack-i386.c2
-rw-r--r--runtime/stack-x86_64.c2
2 files changed, 3 insertions, 1 deletions
diff --git a/runtime/stack-i386.c b/runtime/stack-i386.c
index 66d892d3..d10aeb2f 100644
--- a/runtime/stack-i386.c
+++ b/runtime/stack-i386.c
@@ -63,7 +63,7 @@ static void __stp_stack_print (struct pt_regs *regs, int verbose, int levels,
while (levels && (tsk || !arch_unw_user_mode(&info))) {
int ret = unwind(&info, tsk);
-#if defined(UPROBES_API_VERSION) && UPROBES_API_VERSION > 1
+#ifdef CONFIG_UTRACE
unsigned long maybe_pc = 0;
if (ri) {
maybe_pc = uprobe_get_pc(ri, UNW_PC(&info),
diff --git a/runtime/stack-x86_64.c b/runtime/stack-x86_64.c
index 3fc203f7..6aebcb58 100644
--- a/runtime/stack-x86_64.c
+++ b/runtime/stack-x86_64.c
@@ -38,6 +38,7 @@ static void __stp_stack_print(struct pt_regs *regs, int verbose, int levels,
while (levels && (tsk || !arch_unw_user_mode(&info))) {
int ret = unwind(&info, tsk);
+#ifdef CONFIG_UTRACE
unsigned long maybe_pc = 0;
if (ri) {
maybe_pc = uprobe_get_pc(ri, UNW_PC(&info),
@@ -47,6 +48,7 @@ static void __stp_stack_print(struct pt_regs *regs, int verbose, int levels,
else
UNW_PC(&info) = maybe_pc;
}
+#undef
dbug_unwind(1, "ret=%d PC=%lx SP=%lx\n", ret, UNW_PC(&info), UNW_SP(&info));
if (ret == 0) {
_stp_func_print(UNW_PC(&info), verbose, 1, tsk);