mbox series

[for-next,0/3] RDMA/erdma: Add atomic operations support

Message ID 20221027095741.48044-1-chengyou@linux.alibaba.com (mailing list archive)
Headers show
Series RDMA/erdma: Add atomic operations support | expand

Message

Cheng Xu Oct. 27, 2022, 9:57 a.m. UTC
Hi,

This series introcuces atomic operations support for erdma driver:
- #1 extends access rights field in FRMR and REG MR commands to support
  IB_ACCESS_REMOTE_ATOMIC.
- #2 gets atomic capacity from hardware, and reports the cap to core.
- #3 implements the IO-path of atomic WR processing.

Thanks,
Cheng Xu

Cheng Xu (3):
  RDMA/erdma: Extend access right field of FRMR and REG MR to support
    atomic
  RDMA/erdma: Report atomic capacity when hardware supports atomic
    feature
  RDMA/erdma: Implement atomic operations support

 drivers/infiniband/hw/erdma/erdma.h       |  1 +
 drivers/infiniband/hw/erdma/erdma_cq.c    |  2 ++
 drivers/infiniband/hw/erdma/erdma_hw.h    | 29 +++++++++++++----
 drivers/infiniband/hw/erdma/erdma_main.c  |  1 +
 drivers/infiniband/hw/erdma/erdma_qp.c    | 39 ++++++++++++++++++++---
 drivers/infiniband/hw/erdma/erdma_verbs.c |  7 ++--
 drivers/infiniband/hw/erdma/erdma_verbs.h | 12 ++++---
 7 files changed, 72 insertions(+), 19 deletions(-)

Comments

Leon Romanovsky Nov. 6, 2022, 1:24 p.m. UTC | #1
On Thu, Oct 27, 2022 at 05:57:38PM +0800, Cheng Xu wrote:
> Hi,
> 
> This series introcuces atomic operations support for erdma driver:
> - #1 extends access rights field in FRMR and REG MR commands to support
>   IB_ACCESS_REMOTE_ATOMIC.
> - #2 gets atomic capacity from hardware, and reports the cap to core.
> - #3 implements the IO-path of atomic WR processing.
> 
> Thanks,
> Cheng Xu
> 
> Cheng Xu (3):
>   RDMA/erdma: Extend access right field of FRMR and REG MR to support
>     atomic
>   RDMA/erdma: Report atomic capacity when hardware supports atomic
>     feature
>   RDMA/erdma: Implement atomic operations support

It doesn't pass my static analyzer checks.

➜  kernel git:(wip/leon-for-next) mkt ci
3f69c46621e3 (HEAD -> build) RDMA/erdma: Implement atomic operations support
drivers/infiniband/hw/erdma/erdma_qp.c:365:26: warning: incorrect type in assignment (different base types)
drivers/infiniband/hw/erdma/erdma_qp.c:365:26:    expected restricted __le32 [usertype] key
drivers/infiniband/hw/erdma/erdma_qp.c:365:26:    got unsigned int [usertype] rkey

Thanks
Cheng Xu Nov. 7, 2022, 2:02 a.m. UTC | #2
On 11/6/22 9:24 PM, Leon Romanovsky wrote:
> On Thu, Oct 27, 2022 at 05:57:38PM +0800, Cheng Xu wrote:
>> Hi,
>>
>> This series introcuces atomic operations support for erdma driver:
>> - #1 extends access rights field in FRMR and REG MR commands to support
>>   IB_ACCESS_REMOTE_ATOMIC.
>> - #2 gets atomic capacity from hardware, and reports the cap to core.
>> - #3 implements the IO-path of atomic WR processing.
>>
>> Thanks,
>> Cheng Xu
>>
>> Cheng Xu (3):
>>   RDMA/erdma: Extend access right field of FRMR and REG MR to support
>>     atomic
>>   RDMA/erdma: Report atomic capacity when hardware supports atomic
>>     feature
>>   RDMA/erdma: Implement atomic operations support
> 
> It doesn't pass my static analyzer checks.
> 
> ➜  kernel git:(wip/leon-for-next) mkt ci
> 3f69c46621e3 (HEAD -> build) RDMA/erdma: Implement atomic operations support
> drivers/infiniband/hw/erdma/erdma_qp.c:365:26: warning: incorrect type in assignment (different base types)
> drivers/infiniband/hw/erdma/erdma_qp.c:365:26:    expected restricted __le32 [usertype] key
> drivers/infiniband/hw/erdma/erdma_qp.c:365:26:    got unsigned int [usertype] rkey
> 

I'm sorry for forgetting to run sparse for the code. 
I will send v2.

Thanks,
Cheng Xu