1 /* SPDX-License-Identifier: GPL-2.0 OR Linux-OpenIB */
2 /* Copyright (c) 2016 - 2021 Intel Corporation */
6 #define IRDMA_UDA_MAX_FSI_MGS 4096
7 #define IRDMA_UDA_MAX_PFS 16
8 #define IRDMA_UDA_MAX_VFS 128
12 struct irdma_ah_info
{
13 struct irdma_sc_vsi
*vsi
;
24 u8 mac_addr
[ETH_ALEN
];
31 struct irdma_sc_dev
*dev
;
32 struct irdma_ah_info ah_info
;
35 int irdma_sc_add_mcast_grp(struct irdma_mcast_grp_info
*ctx
,
36 struct irdma_mcast_grp_ctx_entry_info
*mg
);
37 int irdma_sc_del_mcast_grp(struct irdma_mcast_grp_info
*ctx
,
38 struct irdma_mcast_grp_ctx_entry_info
*mg
);
39 int irdma_sc_access_ah(struct irdma_sc_cqp
*cqp
, struct irdma_ah_info
*info
,
41 int irdma_access_mcast_grp(struct irdma_sc_cqp
*cqp
,
42 struct irdma_mcast_grp_info
*info
, u32 op
,
45 static inline void irdma_sc_init_ah(struct irdma_sc_dev
*dev
, struct irdma_sc_ah
*ah
)
50 static inline int irdma_sc_create_ah(struct irdma_sc_cqp
*cqp
,
51 struct irdma_ah_info
*info
, u64 scratch
)
53 return irdma_sc_access_ah(cqp
, info
, IRDMA_CQP_OP_CREATE_ADDR_HANDLE
,
57 static inline int irdma_sc_destroy_ah(struct irdma_sc_cqp
*cqp
,
58 struct irdma_ah_info
*info
, u64 scratch
)
60 return irdma_sc_access_ah(cqp
, info
, IRDMA_CQP_OP_DESTROY_ADDR_HANDLE
,
64 static inline int irdma_sc_create_mcast_grp(struct irdma_sc_cqp
*cqp
,
65 struct irdma_mcast_grp_info
*info
,
68 return irdma_access_mcast_grp(cqp
, info
, IRDMA_CQP_OP_CREATE_MCAST_GRP
,
72 static inline int irdma_sc_modify_mcast_grp(struct irdma_sc_cqp
*cqp
,
73 struct irdma_mcast_grp_info
*info
,
76 return irdma_access_mcast_grp(cqp
, info
, IRDMA_CQP_OP_MODIFY_MCAST_GRP
,
80 static inline int irdma_sc_destroy_mcast_grp(struct irdma_sc_cqp
*cqp
,
81 struct irdma_mcast_grp_info
*info
,
84 return irdma_access_mcast_grp(cqp
, info
, IRDMA_CQP_OP_DESTROY_MCAST_GRP
,
87 #endif /* IRDMA_UDA_H */