Skip to contentSkip to conversation

RDMA/mana_ib: ignore optional access flags for MRs

PATCH Superseded Konstantin Taranov 2 participants 2 messages Jun 4, 2024

Subsystems (2)

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 RDMA/mana_ib: ignore optional access flags for MRs

From: Konstantin Taranov <[email protected]>

Ignore optional ib_access_flags when an MR is created.

---
 drivers/infiniband/hw/mana/mr.c | 1 +
 1 file changed, 1 insertion(+)
drivers/infiniband/hw/mana/mr.c +1 -0
index 4f13423..887b09d 100644
@@ -112,6 +112,7 @@ struct ib_mr *mana_ib_reg_user_mr(struct ib_pd *ibpd, u64 start, u64 length,
 		  "start 0x%llx, iova 0x%llx length 0x%llx access_flags 0x%x",
 		  start, iova, length, access_flags);
 
+	access_flags &= ~IB_ACCESS_OPTIONAL;
 	if (access_flags & ~VALID_MR_FLAGS)
 		return ERR_PTR(-EINVAL);
 
Signature · 1 line
2.43.0
#1 lore raw
Quoted 8 lines · Konstantin Taranov

From: Konstantin Taranov <[email protected]>

Ignore optional ib_access_flags when an MR is created.

---
 drivers/infiniband/hw/mana/mr.c | 1 +
 1 file changed, 1 insertion(+)

Please add Fixes line.

Thanks

Quoted 16 lines
drivers/infiniband/hw/mana/mr.c +1 -0
index 4f13423..887b09d 100644
@@ -112,6 +112,7 @@ struct ib_mr *mana_ib_reg_user_mr(struct ib_pd *ibpd, u64 start, u64 length,
 		  "start 0x%llx, iova 0x%llx length 0x%llx access_flags 0x%x",
 		  start, iova, length, access_flags);
 
+	access_flags &= ~IB_ACCESS_OPTIONAL;
 	if (access_flags & ~VALID_MR_FLAGS)
 		return ERR_PTR(-EINVAL);
 
Signature · 1 line
2.43.0