Skip to content

Commit 79d330f

Browse files
kadesai16rleon
authored andcommitted
RDMA/bnxt_re: Fix max SGEs for the Work Request
Gen P7 supports up to 13 SGEs for now. WQE software structure can hold only 6 now. Since the max send sge is reported as 13, the stack can give requests up to 13 SGEs. This is causing traffic failures and system crashes. Use the define for max SGE supported for variable size. This will work for both static and variable WQEs. Fixes: 227f517 ("RDMA/bnxt_re: Fix the max WQE size for static WQE support") Signed-off-by: Kashyap Desai <[email protected]> Signed-off-by: Selvin Xavier <[email protected]> Link: https://patch.msgid.link/[email protected] Signed-off-by: Leon Romanovsky <[email protected]>
1 parent e05feab commit 79d330f

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

drivers/infiniband/hw/bnxt_re/qplib_fp.h

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,6 @@ struct bnxt_qplib_sge {
114114
u32 size;
115115
};
116116

117-
#define BNXT_QPLIB_QP_MAX_SGL 6
118117
struct bnxt_qplib_swq {
119118
u64 wr_id;
120119
int next_idx;
@@ -154,7 +153,7 @@ struct bnxt_qplib_swqe {
154153
#define BNXT_QPLIB_SWQE_FLAGS_UC_FENCE BIT(2)
155154
#define BNXT_QPLIB_SWQE_FLAGS_SOLICIT_EVENT BIT(3)
156155
#define BNXT_QPLIB_SWQE_FLAGS_INLINE BIT(4)
157-
struct bnxt_qplib_sge sg_list[BNXT_QPLIB_QP_MAX_SGL];
156+
struct bnxt_qplib_sge sg_list[BNXT_VAR_MAX_SGE];
158157
int num_sge;
159158
/* Max inline data is 96 bytes */
160159
u32 inline_len;

0 commit comments

Comments
 (0)