* Update with kernel 2.6.21
@ 2007-03-12 10:18 Pierre Peiffer
0 siblings, 0 replies; only message in thread
From: Pierre Peiffer @ 2007-03-12 10:18 UTC (permalink / raw)
To: systemtap; +Cc: Jean-Pierre Dion, Darren Hart
[-- Attachment #1: Type: text/plain, Size: 649 bytes --]
Hi,
Here is a proposal of update of systemtap to take into account some changes in
kernel 2.6.21.
Patch attached to the mail.
The main changes are:
* __rpc_execute returns now void. (LKET/rpc.stp and tapset/rpc.stp)
* struct svc_rqst has changed (rq_addr member) (tapset/rpc.stp,
tapset/nfsd.stp)
* update with new version of relayfs (runtime/transport/relayfs.c)
Otherwise, as far as I can see, my previous patch, sent two or three weeks ago,
has not (yet) been integrated. So does it fall into a black hole or is there a
reason or did I miss something ? (... just want to be sure it hasn't just been
forgotten ...)
Thanks,
--
Pierre
[-- Attachment #2: fix-kernel-2.6.21.patch --]
[-- Type: text/x-patch, Size: 4474 bytes --]
---
runtime/transport/ChangeLog | 5 +++++
runtime/transport/relayfs.c | 7 +++++--
tapset/ChangeLog | 9 +++++++++
tapset/LKET/Changelog | 5 +++++
tapset/LKET/rpc.stp | 4 ++++
tapset/nfsd.stp | 2 +-
tapset/rpc.stp | 13 ++++++++++++-
7 files changed, 41 insertions(+), 4 deletions(-)
Index: b/runtime/transport/relayfs.c
===================================================================
--- a/runtime/transport/relayfs.c
+++ b/runtime/transport/relayfs.c
@@ -241,13 +241,16 @@ struct rchan *_stp_relayfs_open(unsigned
return NULL;
}
-#if (RELAYFS_CHANNEL_VERSION >= 4)
+#if (RELAYFS_CHANNEL_VERSION >= 7)
+ chan = relay_open("cpu", dir, subbuf_size,
+ n_subbufs, &stp_rchan_callbacks, NULL);
+#elif (RELAYFS_CHANNEL_VERSION >= 4)
chan = relay_open("cpu", dir, subbuf_size,
n_subbufs, &stp_rchan_callbacks);
#else
chan = relay_open("cpu", dir, subbuf_size,
n_subbufs, 0, &stp_rchan_callbacks);
-#endif /* RELAYFS_CHANNEL_VERSION >= 4 */
+#endif /* RELAYFS_CHANNEL_VERSION */
if (!chan) {
printk("STP: couldn't create relay channel.\n");
Index: b/tapset/nfsd.stp
===================================================================
--- a/tapset/nfsd.stp
+++ b/tapset/nfsd.stp
@@ -131,7 +131,7 @@ function p_long:long(cnt:long) %{ /* pur
probe nfsd.dispatch = kernel.function("nfsd_dispatch")?,
module("nfsd").function("nfsd_dispatch") ?
{
- client_ip = $rqstp->rq_addr->sin_addr->s_addr
+ client_ip = addr_from_rqst($rqstp)
proto = $rqstp->rq_prot
version = $rqstp->rq_vers
Index: b/tapset/rpc.stp
===================================================================
--- a/tapset/rpc.stp
+++ b/tapset/rpc.stp
@@ -777,7 +777,12 @@ probe sunrpc.sched.execute.return = kern
module("sunrpc").function("__rpc_execute").return ?
{
name = "sunrpc.sched.execute"
+
+%( kernel_v <= "2.6.20" %?
retstr = returnstr($return)
+%:
+ retstr = "N/A"
+%)
}
/*
@@ -934,7 +939,13 @@ function vers_from_prog:long(program:lon
function addr_from_rqst:long(rqstp:long)
%{
struct svc_rqst *rqstp = (struct svc_rqst *)(long)THIS->rqstp;
- THIS->__retvalue = rqstp ? kread(&(rqstp->rq_addr.sin_addr.s_addr)) : 0;
+
+ if (rqstp) {
+ struct sockaddr_in *sin = (struct sockaddr_in *) &rqstp->rq_addr;
+
+ THIS->__retvalue = kread(&sin->sin_addr.s_addr);
+ } else
+ THIS->__retvalue = 0;
CATCH_DEREF_FAULT();
%}
Index: b/runtime/transport/ChangeLog
===================================================================
--- a/runtime/transport/ChangeLog
+++ b/runtime/transport/ChangeLog
@@ -1,3 +1,8 @@
+2007-03-09 Pierre Peiffer <pierre.peiffer@bull.net>
+
+ * relayfs.c (_stp_relayfs_open): Consolidate with new version
+ in kernel 2.6.21
+
2007-01-30 Martin Hunt <hunt@redhat.com>
* symbols.c: Comment out many debug lines.
Index: b/tapset/ChangeLog
===================================================================
--- a/tapset/ChangeLog
+++ b/tapset/ChangeLog
@@ -1,3 +1,12 @@
+2007-03-09 Pierre Peiffer <pierre.peiffer@bull.net>
+
+ * nfsd.stp (nfsd.dispatch): Change initialization of variable
+ client_ip with a call to addr_from_rqst
+ * rpc.stp (addr_from_rqst): - update with changes in
+ struct svc_rqst
+ - __rpc_execute returns void now.
+ All changes due to update with kernel 2.6.21.
+
2007-02-29 David Wilder <dwilder@us.ibm.com>
*conversions.stp (kernel_int) added goto success; (PR 4419)
Index: b/tapset/LKET/Changelog
===================================================================
--- a/tapset/LKET/Changelog
+++ b/tapset/LKET/Changelog
@@ -1,3 +1,8 @@
+2007-03-09 Pierre Peiffer <pierre.peiffer@bull.net>
+
+ * rpc.stp (_addevent.sunrpc.sched.execute.return):
+ update with __rpc_execute which returns void since kernel 2.6.21.
+
2007-02-06 Josh Stone <joshua.i.stone@intel.com>
* nfs.stp, nfs_proc.stp, nfsd.stp, process.stp, tskdispatch.stp:
Index: b/tapset/LKET/rpc.stp
===================================================================
--- a/tapset/LKET/rpc.stp
+++ b/tapset/LKET/rpc.stp
@@ -697,7 +697,11 @@ probe addevent.sunrpc.sched.execute.retu
probe _addevent.sunrpc.sched.execute.return
= sunrpc.sched.execute.return
{
+%( kernel_v <= "2.6.20" %?
log_sunrpc_return_int64(HOOKID_SUNRPC_SCHED_EXECUTE_RETURN, $return)
+%:
+ log_sunrpc_return_void(HOOKID_SUNRPC_SCHED_EXECUTE_RETURN)
+%)
}
function log_sunrpc_execute(hookid:long, xid:long, prog:long, vers:long,
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2007-03-12 10:18 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-03-12 10:18 Update with kernel 2.6.21 Pierre Peiffer
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).