1 Star 0 Fork 23

cxh/perftest

forked from src-openEuler/perftest 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
0013-Perftest-Fix-TD-lock-free-mode-not-working-for-QP.patch 1.16 KB
一键复制 编辑 原始数据 按行查看 历史
From f8f97b189e9af6cff8559b10c749ff289219b754 Mon Sep 17 00:00:00 2001
From: Xinghai Cen <cenxinghai@h-partners.com>
Date: Wed, 21 Aug 2024 20:06:50 +0800
Subject: [PATCH] Perftest: Fix TD lock-free mode not working for QP
Fix TD lock-free mode not working for QP When
creating QP in TD lock-free mode, set attr_ex.pd with ctx->pad instead of
ctx->pd, otherwise the lock-free won't work.
Fixes: "Perftest: Add support for TD lock-free mode"
Signed-off-by: Guofeng Yue <yueguofeng@h-partners.com>
---
src/perftest_resources.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/src/perftest_resources.c b/src/perftest_resources.c
index 0e2b9a3..1bdf34e 100755
--- a/src/perftest_resources.c
+++ b/src/perftest_resources.c
@@ -2309,7 +2309,11 @@ struct ibv_qp* ctx_qp_create(struct pingpong_context *ctx,
else if (opcode == IBV_WR_RDMA_READ)
attr_ex.send_ops_flags |= IBV_QP_EX_WITH_RDMA_READ;
}
+ #ifdef HAVE_TD_API
+ attr_ex.pd = user_param->no_lock ? ctx->pad : ctx->pd;
+ #else
attr_ex.pd = ctx->pd;
+ #endif
attr_ex.comp_mask |= IBV_QP_INIT_ATTR_SEND_OPS_FLAGS | IBV_QP_INIT_ATTR_PD;
attr_ex.send_cq = attr.send_cq;
attr_ex.recv_cq = attr.recv_cq;
--
2.25.1
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/cxh269/perftest.git
git@gitee.com:cxh269/perftest.git
cxh269
perftest
perftest
master

搜索帮助