All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Frank Ch. Eigler" <fche@redhat.com>
To: linux-sctp@vger.kernel.org
Subject: Re: Possible SCTP peer receive window bug
Date: Thu, 06 Dec 2012 21:39:35 +0000	[thread overview]
Message-ID: <20121206213935.GB15562@redhat.com> (raw)
In-Reply-To: <B1BF0D5B21C20F4D8AE9BB4366C9BFCA6D387197@ENFIRHMBX1.datcon.co.uk>

Hi -

Jamie.Parsons (@UNKNOWN_DOMAIN :-() wrote:

> [...] There is still a bug in the system tap script as the exit
> value of functions is always returned as the same as the entry value
> to functions.  [...]

This is an occasionally confusing aspect of systemtap .return probes.
As per the stapprobes man page and elsewhere, most $context variables
accessed from .return probes represent function *entry-time snapshots*.

Try instead use of the @entry() construct, which makes explicit
which values you wish to be entry-time evaluated, and which later.

probe module("sctp").function("sctp_process_init").return {
     printf("sctp_process_init updates assoc %p peer rwnd to %d\n", 
     @entry($asoc), 
     @cast(@entry($asoc),"sctp_association")->peer->rwnd);
     /* evaluated at .return time:          ^^^^^^^^^^^^ */
}

(http://sourceware.org/PR14437 should make the @cast unnecessary
eventually.)

- FChE

  parent reply	other threads:[~2012-12-06 21:39 UTC|newest]

Thread overview: 31+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-11-26 13:31 Possible SCTP peer receive window bug Jamie Parsons
2012-11-26 15:28 ` Neil Horman
2012-11-26 17:27 ` Jamie Parsons
2012-11-26 20:10 ` Neil Horman
2012-11-27 11:05 ` Jamie Parsons
2012-11-27 14:38 ` Neil Horman
2012-11-27 14:42 ` Jamie Parsons
2012-11-28 15:28 ` Neil Horman
2012-11-28 15:50 ` Vlad Yasevich
2012-11-28 20:55 ` Neil Horman
2012-11-28 21:25 ` Vlad Yasevich
2012-11-29  9:14 ` Jamie Parsons
2012-11-29  9:17 ` Jamie Parsons
2012-11-29 14:48 ` Neil Horman
2012-11-29 14:58 ` Neil Horman
2012-12-04 13:34 ` Jamie Parsons
2012-12-04 14:58 ` Neil Horman
2012-12-05 16:30 ` Neil Horman
2012-12-05 17:11 ` Vlad Yasevich
2012-12-06 14:03 ` Neil Horman
2012-12-06 15:42 ` Jamie Parsons
2012-12-06 19:14 ` Neil Horman
2012-12-06 21:39 ` Frank Ch. Eigler [this message]
2012-12-17 11:08 ` Jamie Parsons
2012-12-17 14:13 ` Neil Horman
2012-12-17 15:12 ` Vlad Yasevich
2012-12-20 12:17 ` Jamie Parsons
2013-01-16 16:58 ` Jamie Parsons
2013-01-16 21:11 ` Neil Horman
2013-01-17 16:45 ` Jamie Parsons
2013-01-17 17:43 ` Neil Horman

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20121206213935.GB15562@redhat.com \
    --to=fche@redhat.com \
    --cc=linux-sctp@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.