RDMA/ocrdma: Honor return value of ocrdma_resolve_dmac

Check for return value for ocrdma_resolve_dmac while setting AV params.

Signed-off-by: Devesh Sharma <devesh.sharma@emulex.com>
Signed-off-by: Mitesh Ahuja <mitesh.ahuja@emulex.com>
Signed-off-by: Selvin Xavier <selvin.xavier@emulex.com>
Signed-off-by: Roland Dreier <roland@purestorage.com>
This commit is contained in:
Devesh Sharma 2014-12-18 14:13:04 +05:30 committed by Roland Dreier
parent 043e9deed9
commit a601dc77f8
1 changed files with 3 additions and 1 deletions

View File

@ -2451,7 +2451,9 @@ static int ocrdma_set_av_params(struct ocrdma_qp *qp,
qp->sgid_idx = ah_attr->grh.sgid_index;
memcpy(&cmd->params.sgid[0], &sgid.raw[0], sizeof(cmd->params.sgid));
ocrdma_resolve_dmac(qp->dev, ah_attr, &mac_addr[0]);
status = ocrdma_resolve_dmac(qp->dev, ah_attr, &mac_addr[0]);
if (status)
return status;
cmd->params.dmac_b0_to_b3 = mac_addr[0] | (mac_addr[1] << 8) |
(mac_addr[2] << 16) | (mac_addr[3] << 24);
/* convert them to LE format. */