mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Jason Gunthorpe <jgg@ziepe.ca>
To: Rao Shoaib <rao.shoaib@oracle.com>
Cc: monis@mellanox.com, dledford@redhat.com, sean.hefty@intel.com,
	hal.rosenstock@gmail.com, linux-rdma@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH v1 1/1] rxe: calculate inline data size based on requested values
Date: Tue, 29 Oct 2019 16:44:38 -0300	[thread overview]
Message-ID: <20191029194437.GI6128@ziepe.ca> (raw)
In-Reply-To: <4c23244e-44bf-2927-6b9d-17c4d279ebe3@oracle.com>

On Tue, Oct 29, 2019 at 12:31:03PM -0700, Rao Shoaib wrote:

> > > @@ -81,6 +80,7 @@ enum rxe_device_param {
> > >   					| IB_DEVICE_MEM_MGT_EXTENSIONS,
> > >   	RXE_MAX_SGE			= 32,
> > >   	RXE_MAX_SGE_RD			= 32,
> > > +	RXE_MAX_INLINE_DATA		= RXE_MAX_SGE * sizeof(struct ib_sge),
> > >   	RXE_MAX_CQ			= 16384,
> > >   	RXE_MAX_LOG_CQE			= 15,
> > >   	RXE_MAX_MR			= 2 * 1024,
> > Increasing RXE_MAX_INLINE_DATA to match the WQE size limited the
> > MAX_SGE. IMHO this is done in a hacky way, instead we should define a
> > maximim WQE size and from there derive the MAX_INLINE_DATA and MAX_SGE
> > limitations.
> There was already RXE_MAX_SGE defined so I did not define MAX_WQE. If that
> is what is preference I can submit a patch with that. What is a good value
> for MAX_WQE?

I would arrange it so that RXE_MAX_SGE doesn't change

> > Also don't double initialize qp->sq.max_inline in the same function,
> > and there is no need for the temporary 'inline_size'
> 
> I used a separate variable as I would have to repeat the calculation twice.
> I do not understand your comment about double initialization, can you please
> clarify that for me.

Assign it to qp->sq.max_inline and then read it to get the init

Look above in the function, there is already an assignment to
qp->sq.max_inline

Jason

      reply	other threads:[~2019-10-29 19:44 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-10-23 17:32 [PATCH v1 0/1] rxe driver should dynamically caclculate inline data size rao Shoaib
2019-10-23 17:32 ` [PATCH v1 1/1] rxe: calculate inline data size based on requested values rao Shoaib
2019-10-29 19:11   ` Jason Gunthorpe
2019-10-29 19:31     ` Rao Shoaib
2019-10-29 19:44       ` Jason Gunthorpe [this message]

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=20191029194437.GI6128@ziepe.ca \
    --to=jgg@ziepe.ca \
    --cc=dledford@redhat.com \
    --cc=hal.rosenstock@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-rdma@vger.kernel.org \
    --cc=monis@mellanox.com \
    --cc=rao.shoaib@oracle.com \
    --cc=sean.hefty@intel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®