summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorfche <fche>2007-04-23 21:07:58 +0000
committerfche <fche>2007-04-23 21:07:58 +0000
commit27a1a71a027977e61f73f61b41ad7e12eeb28b57 (patch)
treeb9301636c8a5f90888d6ef9edb2ae163daa2296d
parent7f4cce15d398c00b98ce8277216162f0cde17f6a (diff)
downloadsystemtap-steved-27a1a71a027977e61f73f61b41ad7e12eeb28b57.tar.gz
systemtap-steved-27a1a71a027977e61f73f61b41ad7e12eeb28b57.tar.xz
systemtap-steved-27a1a71a027977e61f73f61b41ad7e12eeb28b57.zip
2007-04-23 Frank Ch. Eigler <fche@elastic.org>
* scheduler.stp (scheduler.ctxswitch): Since it's marked __kprobes switch from __switch_to to context_switch on x86-64 in Ipswitch.
-rw-r--r--tapset/ChangeLog5
-rw-r--r--tapset/scheduler.stp16
2 files changed, 18 insertions, 3 deletions
diff --git a/tapset/ChangeLog b/tapset/ChangeLog
index 9a6cb1f3..e7116ca4 100644
--- a/tapset/ChangeLog
+++ b/tapset/ChangeLog
@@ -1,3 +1,8 @@
+2007-04-23 Frank Ch. Eigler <fche@elastic.org>
+
+ * scheduler.stp (scheduler.ctxswitch): Since it's marked __kprobes
+ switch from __switch_to to context_switch on x86-64 in Ipswitch.
+
2007-04-04 Sébastien Dugué <sebastien.dugue@bull.net>
* scsi.stp: Fix for when the scsi driver is built into the kernel.
diff --git a/tapset/scheduler.stp b/tapset/scheduler.stp
index 6c8d5d17..a17a8eac 100644
--- a/tapset/scheduler.stp
+++ b/tapset/scheduler.stp
@@ -120,8 +120,12 @@ probe scheduler.balance = kernel.function("idle_balance")? {}
* next_pid: The pid of the process to be switched in
* prevtsk_state: the state of the process to be switched out
*/
-probe scheduler.ctxswitch
- = kernel.function("__switch_to")
+probe scheduler.ctxswitch =
+%( arch == "x86_64" %?
+ kernel.function("context_switch")
+%:
+ kernel.function("__switch_to")
+%)
{
%( arch == "ppc64" %?
prev_pid = $prev->pid
@@ -129,11 +133,17 @@ probe scheduler.ctxswitch
prev_task = $prev
next_task = $new
prevtsk_state = $prev->state
+%: %( arch == "x86_64" %?
+ prev_pid = $prev->pid
+ next_pid = $new->pid
+ prev_task = $prev
+ next_task = $new
+ prevtsk_state = $prev->state
%:
prev_pid = $prev_p->pid
next_pid = $next_p->pid
prev_task = $prev_p
next_task = $next_p
prevtsk_state = $prev_p->state
-%)
+%) %)
}