Re: [PATCH rdma-next 01/10] RDMA: Add access flags to ib_alloc_mr() and ib_mr_pool_init()

2021-04-07 Thread Jason Gunthorpe
On Tue, Apr 06, 2021 at 04:54:57PM +0200, Christoph Hellwig wrote: > On Tue, Apr 06, 2021 at 11:40:39AM -0300, Jason Gunthorpe wrote: > > Yes, but the complexity is how the drivers are constructed they are > > designed to reject flags they don't know about.. > > > > Hum, it looks like someone has

Re: [PATCH rdma-next 01/10] RDMA: Add access flags to ib_alloc_mr() and ib_mr_pool_init()

2021-04-06 Thread Christoph Hellwig
On Tue, Apr 06, 2021 at 04:54:57PM +0200, Christoph Hellwig wrote: > That is something everyone gets wrong at first (yourself included) The yourself here should have been a yours truly or "myself", sorry.

Re: [PATCH rdma-next 01/10] RDMA: Add access flags to ib_alloc_mr() and ib_mr_pool_init()

2021-04-06 Thread Christoph Hellwig
On Tue, Apr 06, 2021 at 11:40:39AM -0300, Jason Gunthorpe wrote: > Yes, but the complexity is how the drivers are constructed they are > designed to reject flags they don't know about.. > > Hum, it looks like someone has already been in here and we now have a > IB_ACCESS_OPTIONAL concept. > >

Re: [PATCH rdma-next 01/10] RDMA: Add access flags to ib_alloc_mr() and ib_mr_pool_init()

2021-04-06 Thread Jason Gunthorpe
On Tue, Apr 06, 2021 at 04:15:52PM +0200, Christoph Hellwig wrote: > On Tue, Apr 06, 2021 at 11:04:37AM -0300, Jason Gunthorpe wrote: > > It might be idiodic, but I have to keep the uverbs thing working > > too. > > > > There is a lot of assumption baked in to all the drivers that > > user/kernel

Re: [PATCH rdma-next 01/10] RDMA: Add access flags to ib_alloc_mr() and ib_mr_pool_init()

2021-04-06 Thread Christoph Hellwig
On Tue, Apr 06, 2021 at 11:04:37AM -0300, Jason Gunthorpe wrote: > It might be idiodic, but I have to keep the uverbs thing working > too. > > There is a lot of assumption baked in to all the drivers that > user/kernel is the same thing, we'd have to go in and break this. > > Essentially #2 ends

Re: [PATCH rdma-next 01/10] RDMA: Add access flags to ib_alloc_mr() and ib_mr_pool_init()

2021-04-06 Thread Jason Gunthorpe
On Tue, Apr 06, 2021 at 02:30:34PM +0200, Christoph Hellwig wrote: > On Tue, Apr 06, 2021 at 09:13:12AM -0300, Jason Gunthorpe wrote: > > So we broadly have two choice > > 1) Diverge the kernel and user interfaces and make the RDMA drivers > > special case all the kernel stuff to force > >

Re: [PATCH rdma-next 01/10] RDMA: Add access flags to ib_alloc_mr() and ib_mr_pool_init()

2021-04-06 Thread Christoph Hellwig
On Tue, Apr 06, 2021 at 09:13:12AM -0300, Jason Gunthorpe wrote: > So we broadly have two choice > 1) Diverge the kernel and user interfaces and make the RDMA drivers > special case all the kernel stuff to force > ACCESS_RELAXED_ORDERING when they are building MRs and processing > FMR

Re: [PATCH rdma-next 01/10] RDMA: Add access flags to ib_alloc_mr() and ib_mr_pool_init()

2021-04-06 Thread Jason Gunthorpe
On Tue, Apr 06, 2021 at 08:58:54AM +0300, Leon Romanovsky wrote: > On Tue, Apr 06, 2021 at 07:27:17AM +0200, Christoph Hellwig wrote: > > On Tue, Apr 06, 2021 at 08:23:28AM +0300, Leon Romanovsky wrote: > > > The same proposal (enable unconditionally) was raised during > > > submission

Re: [PATCH rdma-next 01/10] RDMA: Add access flags to ib_alloc_mr() and ib_mr_pool_init()

2021-04-05 Thread Leon Romanovsky
On Tue, Apr 06, 2021 at 07:27:17AM +0200, Christoph Hellwig wrote: > On Tue, Apr 06, 2021 at 08:23:28AM +0300, Leon Romanovsky wrote: > > The same proposal (enable unconditionally) was raised during > > submission preparations and we decided to follow same pattern > > as other verbs objects which

Re: [PATCH rdma-next 01/10] RDMA: Add access flags to ib_alloc_mr() and ib_mr_pool_init()

2021-04-05 Thread Christoph Hellwig
On Tue, Apr 06, 2021 at 08:23:28AM +0300, Leon Romanovsky wrote: > The same proposal (enable unconditionally) was raised during > submission preparations and we decided to follow same pattern > as other verbs objects which receive flag parameter. A flags argument can be added when it actually is

Re: [PATCH rdma-next 01/10] RDMA: Add access flags to ib_alloc_mr() and ib_mr_pool_init()

2021-04-05 Thread Leon Romanovsky
On Mon, Apr 05, 2021 at 03:46:18PM +0200, Christoph Hellwig wrote: > On Mon, Apr 05, 2021 at 08:23:55AM +0300, Leon Romanovsky wrote: > > From: Avihai Horon > > > > Add access flags parameter to ib_alloc_mr() and to ib_mr_pool_init(), > > and refactor relevant code. This parameter is used to

Re: [PATCH rdma-next 01/10] RDMA: Add access flags to ib_alloc_mr() and ib_mr_pool_init()

2021-04-05 Thread Leon Romanovsky
On Mon, Apr 05, 2021 at 08:27:16AM -0700, Bart Van Assche wrote: > On 4/4/21 10:23 PM, Leon Romanovsky wrote: > > diff --git a/include/rdma/ib_verbs.h b/include/rdma/ib_verbs.h > > index bed4cfe50554..59138174affa 100644 > > --- a/include/rdma/ib_verbs.h > > +++ b/include/rdma/ib_verbs.h > > @@

Re: [PATCH rdma-next 01/10] RDMA: Add access flags to ib_alloc_mr() and ib_mr_pool_init()

2021-04-05 Thread Bart Van Assche
On 4/4/21 10:23 PM, Leon Romanovsky wrote: > diff --git a/include/rdma/ib_verbs.h b/include/rdma/ib_verbs.h > index bed4cfe50554..59138174affa 100644 > --- a/include/rdma/ib_verbs.h > +++ b/include/rdma/ib_verbs.h > @@ -2444,10 +2444,10 @@ struct ib_device_ops { >

Re: [PATCH rdma-next 01/10] RDMA: Add access flags to ib_alloc_mr() and ib_mr_pool_init()

2021-04-05 Thread Christoph Hellwig
On Mon, Apr 05, 2021 at 08:23:55AM +0300, Leon Romanovsky wrote: > From: Avihai Horon > > Add access flags parameter to ib_alloc_mr() and to ib_mr_pool_init(), > and refactor relevant code. This parameter is used to pass MR access > flags during MR allocation. > > In the following patches, the

[PATCH rdma-next 01/10] RDMA: Add access flags to ib_alloc_mr() and ib_mr_pool_init()

2021-04-04 Thread Leon Romanovsky
From: Avihai Horon Add access flags parameter to ib_alloc_mr() and to ib_mr_pool_init(), and refactor relevant code. This parameter is used to pass MR access flags during MR allocation. In the following patches, the new access flags parameter will be used to enable Relaxed Ordering for