All of lore.kernel.org
 help / color / mirror / Atom feed
From: Greg Banks <gnb@sgi.com>
To: Tom Tucker <tom@opengridcomputing.com>
Cc: neilb@suse.de, bfields@fieldses.org, nfs@lists.sourceforge.net
Subject: Re: [RFC,PATCH] svc: Add xprt header len to svc_deferred_req
Date: Wed, 10 Oct 2007 12:39:56 +1000	[thread overview]
Message-ID: <20071010023956.GC20690@sgi.com> (raw)
In-Reply-To: <20071009225740.26067.25488.stgit@dell3.ogc.int>

On Tue, Oct 09, 2007 at 05:57:40PM -0500, Tom Tucker wrote:
> 
> A transport may have a header that precedes the RPC message. Save the
> size of this header in the svc_deferred_req so that when the RPC
> is revisited, the deferred recv function doesn't need to re-parse the 
> header to determine it's length.
> 
> In addition, a misleading comment related to the transport header 
> for TCP/UDP has been rewritten.
> 
> Signed-off-by: Tom Tucker <tom@opengridcomputing.com>
> ---
> 
>  include/linux/sunrpc/svc.h |    1 +
>  net/sunrpc/svc_xprt.c      |    1 +
>  net/sunrpc/svcsock.c       |    2 +-
>  3 files changed, 3 insertions(+), 1 deletions(-)
> 
> diff --git a/include/linux/sunrpc/svc.h b/include/linux/sunrpc/svc.h
> index ea07e3d..f2ada2a 100644
> --- a/include/linux/sunrpc/svc.h
> +++ b/include/linux/sunrpc/svc.h
> @@ -323,6 +323,7 @@ struct svc_deferred_req {
>  	size_t			addrlen;
>  	union svc_addr_u	daddr;	/* where reply must come from */
>  	struct cache_deferred_req handle;
> +	int			xprt_hlen;
>  	int			argslen;
>  	__be32			args[0];
>  };
> diff --git a/net/sunrpc/svc_xprt.c b/net/sunrpc/svc_xprt.c
> index 080ecf5..b580d4c 100644
> --- a/net/sunrpc/svc_xprt.c
> +++ b/net/sunrpc/svc_xprt.c
> @@ -884,6 +884,7 @@ static struct cache_deferred_req *svc_de
>  		dr->addrlen = rqstp->rq_addrlen;
>  		dr->daddr = rqstp->rq_daddr;
>  		dr->argslen = (rqstp->rq_arg.len + rqstp->rq_xprt_hlen) >> 2;
> +		dr->xprt_hlen = rqstp->rq_xprt_hlen;
>  
>  		/* back up head to the start of the buffer and copy */
>  		skip = (rqstp->rq_arg.len + rqstp->rq_xprt_hlen) -

Are you planning on restoring rqstp->rq_xprt_hlen from
dr->xprt_hlen in svc_deferred_recv() ?

Greg.
-- 
Greg Banks, R&D Software Engineer, SGI Australian Software Group.
Apparently, I'm Bedevere.  Which MPHG character are you?
I don't speak for SGI.

-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
_______________________________________________
NFS maillist  -  NFS@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nfs

  reply	other threads:[~2007-10-10  2:31 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-10-09 22:57 [RFC,PATCH] svc: Add xprt header len to svc_deferred_req Tom Tucker
2007-10-10  2:39 ` Greg Banks [this message]
2007-10-10  2:34   ` Tom Tucker
2007-10-10  2:47     ` Greg Banks

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=20071010023956.GC20690@sgi.com \
    --to=gnb@sgi.com \
    --cc=bfields@fieldses.org \
    --cc=neilb@suse.de \
    --cc=nfs@lists.sourceforge.net \
    --cc=tom@opengridcomputing.com \
    /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.