Add support for configuration of congestion control algorithms in QP granularity with direct verbs hnsdv_create_qp(). Reference: https://github.com/linux-rdma/rdma-core/pull/1426/commits Signed-off-by: Ran Zhou <zhouran10@h-partners.com> (cherry picked from commit f4a8396bcf41ea12bf3e7b73793e60bfba097377)
58 lines
1.6 KiB
Diff
58 lines
1.6 KiB
Diff
From 75fdc5c9a0cce5cc6859189eeb91ce1846edc4b9 Mon Sep 17 00:00:00 2001
|
|
From: Junxian Huang <huangjunxian6@hisilicon.com>
|
|
Date: Tue, 5 Mar 2024 13:57:20 +0800
|
|
Subject: [PATCH 3/7] Update kernel headers
|
|
|
|
To commit: 6ec429d5887a ("RDMA/hns: Support userspace configuring
|
|
congestion control algorithm with QP granularity").
|
|
|
|
Signed-off-by: Junxian Huang <huangjunxian6@hisilicon.com>
|
|
---
|
|
kernel-headers/rdma/hns-abi.h | 16 ++++++++++++++++
|
|
1 file changed, 16 insertions(+)
|
|
|
|
diff --git a/kernel-headers/rdma/hns-abi.h b/kernel-headers/rdma/hns-abi.h
|
|
index f77697c..39ed8a4 100644
|
|
--- a/kernel-headers/rdma/hns-abi.h
|
|
+++ b/kernel-headers/rdma/hns-abi.h
|
|
@@ -73,6 +73,17 @@ struct hns_roce_ib_create_srq_resp {
|
|
__u32 cap_flags; /* Use enum hns_roce_srq_cap_flags */
|
|
};
|
|
|
|
+enum hns_roce_congest_type_flags {
|
|
+ HNS_ROCE_CREATE_QP_FLAGS_DCQCN,
|
|
+ HNS_ROCE_CREATE_QP_FLAGS_LDCP,
|
|
+ HNS_ROCE_CREATE_QP_FLAGS_HC3,
|
|
+ HNS_ROCE_CREATE_QP_FLAGS_DIP,
|
|
+};
|
|
+
|
|
+enum hns_roce_create_qp_comp_mask {
|
|
+ HNS_ROCE_CREATE_QP_MASK_CONGEST_TYPE = 1 << 0,
|
|
+};
|
|
+
|
|
struct hns_roce_ib_create_qp {
|
|
__aligned_u64 buf_addr;
|
|
__aligned_u64 db_addr;
|
|
@@ -81,6 +92,9 @@ struct hns_roce_ib_create_qp {
|
|
__u8 sq_no_prefetch;
|
|
__u8 reserved[5];
|
|
__aligned_u64 sdb_addr;
|
|
+ __aligned_u64 comp_mask; /* Use enum hns_roce_create_qp_comp_mask */
|
|
+ __aligned_u64 create_flags;
|
|
+ __aligned_u64 cong_type_flags;
|
|
};
|
|
|
|
enum hns_roce_qp_cap_flags {
|
|
@@ -120,6 +134,8 @@ struct hns_roce_ib_alloc_ucontext_resp {
|
|
__u32 reserved;
|
|
__u32 config;
|
|
__u32 max_inline_data;
|
|
+ __u8 congest_type;
|
|
+ __u8 reserved0[7];
|
|
};
|
|
|
|
struct hns_roce_ib_alloc_ucontext {
|
|
--
|
|
2.33.0
|
|
|