]> sourceware.org Git - systemtap.git/commitdiff
The rpc buildok test suite probe breaks with new kernels
authorSteve Dickson <steved@redhat.com>
Tue, 16 Mar 2010 12:23:14 +0000 (08:23 -0400)
committerSteve Dickson <steved@redhat.com>
Tue, 16 Mar 2010 15:11:25 +0000 (11:11 -0400)
With newer kernels the rpc_release_task() routine is not defined
because it becomes inline since its only called once. Plus the
task allocation routines have changed so the arguments no longer
match up with previous routines. So this patch uses the kernel_v
clauses to allow the original functionality with older kernels
and not to break on new kernels.

Signed-off-by: Steve Dickson <steved@redhat.com>
tapset/rpc.stp

index d8f2fadc91edd4668fa0536188a04fd26cb81829..336cfcf232893464d7e3dbf9975717298845bbd8 100644 (file)
@@ -121,14 +121,27 @@ probe _sunrpc.clnt.create_client.return.part1 =
 {
        name = "sunrpc.clnt.create_client.return"
 }
-%)
-
 probe _sunrpc.clnt.create_client.return.part2 =
        kernel.function("rpc_new_client").return !,
        module("sunrpc").function("rpc_new_client").return
 {
        name = "sunrpc.clnt.new_client.return"
 }
+%:
+probe _sunrpc.clnt.create_client.return.part1 = 
+       kernel.function("rpc_create").return !,
+       module("sunrpc").function("rpc_create").return
+{
+       name = "sunrpc.clnt.create_client.return"
+}
+probe _sunrpc.clnt.create_client.return.part2 = 
+       kernel.function("rpc_create").return !,
+       module("sunrpc").function("rpc_create").return
+{
+       name = "sunrpc.clnt.create_client.return"
+}
+%)
+
 
 /*
  * Fires when the RPC client structure is to be cloned
@@ -722,14 +735,18 @@ probe sunrpc.svc.drop.return = kernel.function("svc_drop").return !,
  ******************************************************************/
 probe sunrpc.sched.entry =
        sunrpc.sched.new_task,
+%( kernel_v <= "2.6.18" %?
        sunrpc.sched.release_task,
+%)
        sunrpc.sched.execute,
        sunrpc.sched.delay
 {}
 
 probe sunrpc.sched.return =
        sunrpc.sched.new_task.return,
+%( kernel_v <= "2.6.18" %?
        sunrpc.sched.release_task.return,
+%)
        sunrpc.sched.execute.return,
        sunrpc.sched.delay.return
 {}
@@ -777,6 +794,7 @@ probe sunrpc.sched.new_task.return = kernel.function("rpc_new_task").return !,
  * @prot:        the IP protocol in the RPC call
  * @tk_flags:    the flags of the task
  */
+%( kernel_v <= "2.6.18" %?
 probe sunrpc.sched.release_task = kernel.function("rpc_release_task") !,
        module("sunrpc").function("rpc_release_task")
 {
@@ -796,6 +814,7 @@ probe sunrpc.sched.release_task.return =
 {
        name = "sunrpc.sched.release_task.return"
 }
+%)
 
 /*
  * Fires when the RPC `scheduler'(or rather, the finite state machine) 
This page took 0.029934 seconds and 5 git commands to generate.