Commit ea7596c1 authored by Zhu Yanjun's avatar Zhu Yanjun Committed by Jason Gunthorpe

RDMA/irdma: Make irdma_create_mg_ctx return a void

The function irdma_create_mg_ctx always returns 0, so make it void and
delete the return value check.

Link: https://lore.kernel.org/r/20220224182832.3896686-1-yanjun.zhu@linux.devSigned-off-by: default avatarZhu Yanjun <yanjun.zhu@linux.dev>
Acked-by: default avatarShiraz Saleem <shiraz.saleem@intel.com>
Signed-off-by: default avatarJason Gunthorpe <jgg@nvidia.com>
parent 884194ef
...@@ -84,7 +84,7 @@ int irdma_sc_access_ah(struct irdma_sc_cqp *cqp, struct irdma_ah_info *info, ...@@ -84,7 +84,7 @@ int irdma_sc_access_ah(struct irdma_sc_cqp *cqp, struct irdma_ah_info *info,
* irdma_create_mg_ctx() - create a mcg context * irdma_create_mg_ctx() - create a mcg context
* @info: multicast group context info * @info: multicast group context info
*/ */
static int irdma_create_mg_ctx(struct irdma_mcast_grp_info *info) static void irdma_create_mg_ctx(struct irdma_mcast_grp_info *info)
{ {
struct irdma_mcast_grp_ctx_entry_info *entry_info = NULL; struct irdma_mcast_grp_ctx_entry_info *entry_info = NULL;
u8 idx = 0; /* index in the array */ u8 idx = 0; /* index in the array */
...@@ -103,8 +103,6 @@ static int irdma_create_mg_ctx(struct irdma_mcast_grp_info *info) ...@@ -103,8 +103,6 @@ static int irdma_create_mg_ctx(struct irdma_mcast_grp_info *info)
ctx_idx++; ctx_idx++;
} }
} }
return 0;
} }
/** /**
...@@ -119,7 +117,6 @@ int irdma_access_mcast_grp(struct irdma_sc_cqp *cqp, ...@@ -119,7 +117,6 @@ int irdma_access_mcast_grp(struct irdma_sc_cqp *cqp,
u64 scratch) u64 scratch)
{ {
__le64 *wqe; __le64 *wqe;
int ret_code = 0;
if (info->mg_id >= IRDMA_UDA_MAX_FSI_MGS) { if (info->mg_id >= IRDMA_UDA_MAX_FSI_MGS) {
ibdev_dbg(to_ibdev(cqp->dev), "WQE: mg_id out of range\n"); ibdev_dbg(to_ibdev(cqp->dev), "WQE: mg_id out of range\n");
...@@ -132,9 +129,7 @@ int irdma_access_mcast_grp(struct irdma_sc_cqp *cqp, ...@@ -132,9 +129,7 @@ int irdma_access_mcast_grp(struct irdma_sc_cqp *cqp,
return -ENOMEM; return -ENOMEM;
} }
ret_code = irdma_create_mg_ctx(info); irdma_create_mg_ctx(info);
if (ret_code)
return ret_code;
set_64bit_val(wqe, 32, info->dma_mem_mc.pa); set_64bit_val(wqe, 32, info->dma_mem_mc.pa);
set_64bit_val(wqe, 16, set_64bit_val(wqe, 16,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment