@@ -1218,12 +1218,11 @@ int irdma_hw_modify_qp(struct irdma_device *iwdev, struct irdma_qp *iwqp,
return status;
switch (m_info->next_iwarp_state) {
- struct irdma_gen_ae_info ae_info;
-
case IRDMA_QP_STATE_RTS:
case IRDMA_QP_STATE_IDLE:
case IRDMA_QP_STATE_TERMINATE:
- case IRDMA_QP_STATE_CLOSING:
+ case IRDMA_QP_STATE_CLOSING: {
+ struct irdma_gen_ae_info ae_info;
if (info->curr_iwarp_state == IRDMA_QP_STATE_IDLE)
irdma_send_reset(iwqp->cm_node);
else
@@ -1250,7 +1249,7 @@ int irdma_hw_modify_qp(struct irdma_device *iwdev, struct irdma_qp *iwqp,
irdma_handle_cqp_op(rf, cqp_request);
irdma_put_cqp_request(&rf->cqp, cqp_request);
}
- break;
+ } break;
case IRDMA_QP_STATE_ERROR:
default:
break;
When defining CONFIG_INIT_STACK_ALL_ZERO a warning is emitted due to this variable in the switch, moving it into the case solves the problem. Signed-off-by: Jack Vogel <jack.vogel@oracle.com> --- drivers/infiniband/hw/irdma/utils.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-)