[PATCH for-next v2 0/2] Fix memory ordering errors in queues

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



These two patches optimize the memory ordering in rxe_queue.h so
that user space and not kernel space indices are protected for loads
with smp_load_acquire() and stores with smp_store_release(). The
original implementation of this did not apply to all index references
which has recently caused test case errors traced to stale memory loads.
These patches fix those errors.

Reported-by: Zhu Yanjun <zyjzyj2000@xxxxxxxxx>
Fixes: d21a1240f516 ("RDMA/rxe: Use acquire/release for memory ordering")
Signed-off-by: Bob Pearson <rpearsonhpe@xxxxxxxxx>
---
v2:
  Added a way to distinguish between user and kernel indices.
---
Bob Pearson (2):
  RDMA/rxe: Add a type flag to rxe_queue structs
  RDMA/rxe: Protect user space index loads/stores

 drivers/infiniband/sw/rxe/rxe_cq.c    |   4 +-
 drivers/infiniband/sw/rxe/rxe_qp.c    |  12 +-
 drivers/infiniband/sw/rxe/rxe_queue.c |   8 +-
 drivers/infiniband/sw/rxe/rxe_queue.h | 181 ++++++++++++++++++--------
 drivers/infiniband/sw/rxe/rxe_srq.c   |   4 +-
 5 files changed, 145 insertions(+), 64 deletions(-)

-- 
2.30.2




[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Photo]     [Yosemite News]     [Yosemite Photos]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux