linux-nfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Anna Schumaker <Anna.Schumaker@netapp.com>
To: Chuck Lever <chuck.lever@oracle.com>,
	<linux-rdma@vger.kernel.org>, <linux-nfs@vger.kernel.org>
Subject: Re: [PATCH v1 02/18] xprtrdma: Bound the inline threshold values
Date: Tue, 12 Apr 2016 14:04:38 -0400	[thread overview]
Message-ID: <570D38B6.30005@Netapp.com> (raw)
In-Reply-To: <20160411201024.20531.77252.stgit@manet.1015granger.net>

On 04/11/2016 04:10 PM, Chuck Lever wrote:
> Currently the sysctls that allow setting the inline threshold allow
> any value to be set.
> 
> Small values only make the transport run slower. The default 1KB
> setting is as low as is reasonable. And the logic that decides how
> to divide a Send buffer buffer between RPC-over-RDMA header and RPC
                   ^^^^^^^^^^^^^
I'm guessing you don't mean a buffer of buffers? :)

> message assumes (but does not check) that the lower bound is not
> crazy (say, 57 bytes).
> 
> Send and receive buffers share a page with some control information.
> Values larger than about 3KB can't be supported, currently.
> 
> Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
> ---
>  include/linux/sunrpc/xprtrdma.h |    4 +++-
>  net/sunrpc/xprtrdma/transport.c |    6 ++++++
>  2 files changed, 9 insertions(+), 1 deletion(-)
> 
> diff --git a/include/linux/sunrpc/xprtrdma.h b/include/linux/sunrpc/xprtrdma.h
> index 767190b..39267dc 100644
> --- a/include/linux/sunrpc/xprtrdma.h
> +++ b/include/linux/sunrpc/xprtrdma.h
> @@ -52,7 +52,9 @@
>  #define RPCRDMA_DEF_SLOT_TABLE	(128U)
>  #define RPCRDMA_MAX_SLOT_TABLE	(256U)
>  
> -#define RPCRDMA_DEF_INLINE  (1024)	/* default inline max */
> +#define RPCRDMA_MIN_INLINE  (1024)	/* min inline thresh */
> +#define RPCRDMA_DEF_INLINE  (1024)	/* default inline thresh */
> +#define RPCRDMA_MAX_INLINE  (3068)	/* max inline thresh */

It looks like RPCRDMA_DEF_INLINE is used to set xprt_rdma_max_inline_{read,write}. Are we keeping DEF_INLINE around so we can set these values separately from the minimum and maximum amounts?

Thanks,
Anna

>  
>  /* Memory registration strategies, by number.
>   * This is part of a kernel / user space API. Do not remove. */
> diff --git a/net/sunrpc/xprtrdma/transport.c b/net/sunrpc/xprtrdma/transport.c
> index 9954342..16595ff 100644
> --- a/net/sunrpc/xprtrdma/transport.c
> +++ b/net/sunrpc/xprtrdma/transport.c
> @@ -73,6 +73,8 @@ static unsigned int xprt_rdma_memreg_strategy = RPCRDMA_FRMR;
>  
>  static unsigned int min_slot_table_size = RPCRDMA_MIN_SLOT_TABLE;
>  static unsigned int max_slot_table_size = RPCRDMA_MAX_SLOT_TABLE;
> +static unsigned int min_inline_size = RPCRDMA_MIN_INLINE;
> +static unsigned int max_inline_size = RPCRDMA_MAX_INLINE;
>  static unsigned int zero;
>  static unsigned int max_padding = PAGE_SIZE;
>  static unsigned int min_memreg = RPCRDMA_BOUNCEBUFFERS;
> @@ -96,6 +98,8 @@ static struct ctl_table xr_tunables_table[] = {
>  		.maxlen		= sizeof(unsigned int),
>  		.mode		= 0644,
>  		.proc_handler	= proc_dointvec,
> +		.extra1		= &min_inline_size,
> +		.extra2		= &max_inline_size,
>  	},
>  	{
>  		.procname	= "rdma_max_inline_write",
> @@ -103,6 +107,8 @@ static struct ctl_table xr_tunables_table[] = {
>  		.maxlen		= sizeof(unsigned int),
>  		.mode		= 0644,
>  		.proc_handler	= proc_dointvec,
> +		.extra1		= &min_inline_size,
> +		.extra2		= &max_inline_size,
>  	},
>  	{
>  		.procname	= "rdma_inline_write_padding",
> 
> --
> To unsubscribe from this list: send the line "unsubscribe linux-nfs" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> 


  reply	other threads:[~2016-04-12 18:05 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-04-11 20:10 [PATCH v1 00/18] NFS/RDMA client patches for 4.7 Chuck Lever
2016-04-11 20:10 ` [PATCH v1 01/18] sunrpc: Advertise maximum backchannel payload size Chuck Lever
2016-04-11 20:10 ` [PATCH v1 02/18] xprtrdma: Bound the inline threshold values Chuck Lever
2016-04-12 18:04   ` Anna Schumaker [this message]
2016-04-12 19:12     ` Chuck Lever
2016-04-11 20:10 ` [PATCH v1 03/18] xprtrdma: Limit number of RDMA segments in RPC-over-RDMA headers Chuck Lever
2016-04-11 20:10 ` [PATCH v1 04/18] xprtrdma: Prevent inline overflow Chuck Lever
2016-04-11 20:10 ` [PATCH v1 05/18] xprtrdma: Avoid using Write list for small NFS READ requests Chuck Lever
2016-04-11 20:35   ` Steve Wise
2016-04-11 20:38     ` Chuck Lever
2016-04-12 14:15       ` Christoph Hellwig
2016-04-12 14:49         ` Chuck Lever
2016-04-12 17:01           ` Christoph Hellwig
2016-04-12 18:08             ` Chuck Lever
2016-04-11 20:10 ` [PATCH v1 06/18] xprtrdma: Update comments in rpcrdma_marshal_req() Chuck Lever
2016-04-11 20:11 ` [PATCH v1 07/18] xprtrdma: Allow Read list and Reply chunk simultaneously Chuck Lever
2016-04-11 20:11 ` [PATCH v1 08/18] xprtrdma: Remove rpcrdma_create_chunks() Chuck Lever
2016-04-11 20:11 ` [PATCH v1 09/18] xprtrdma: Use core ib_drain_qp() API Chuck Lever
2016-04-12  4:49   ` Leon Romanovsky
2016-04-11 20:11 ` [PATCH v1 10/18] xprtrdma: Rename rpcrdma_frwr::sg and sg_nents Chuck Lever
2016-04-11 20:11 ` [PATCH v1 11/18] xprtrdma: Save I/O direction in struct rpcrdma_frwr Chuck Lever
2016-04-11 20:11 ` [PATCH v1 00/18] NFS/RDMA client patches for 4.7 Chuck Lever
2016-04-11 20:11 ` [PATCH v1 12/18] xprtrdma: Reset MRs in frwr_op_unmap_sync() Chuck Lever
2016-04-11 20:11 ` [PATCH v1 13/18] xprtrdma: Refactor the FRWR recovery worker Chuck Lever
2016-04-11 20:12 ` [PATCH v1 14/18] xprtrdma: Move fr_xprt and fr_worker to struct rpcrdma_mw Chuck Lever
2016-04-11 20:12 ` [PATCH v1 15/18] xprtrdma: Refactor __fmr_dma_unmap() Chuck Lever
2016-04-11 20:12 ` [PATCH v1 16/18] xprtrdma: Add ro_unmap_safe memreg method Chuck Lever
2016-04-11 20:12 ` [PATCH v1 17/18] xprtrdma: Remove ro_unmap() from all registration modes Chuck Lever
2016-04-11 20:12 ` [PATCH v1 18/18] xprtrdma: Faster server reboot recovery Chuck Lever

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=570D38B6.30005@Netapp.com \
    --to=anna.schumaker@netapp.com \
    --cc=chuck.lever@oracle.com \
    --cc=linux-nfs@vger.kernel.org \
    --cc=linux-rdma@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 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 NNTP newsgroup(s).