net/bnxt: fix HWRM command during FW reset
[dpdk.git] / drivers / net / bnxt / bnxt_hwrm.c
index 4c0fac6..dc0b405 100644 (file)
@@ -221,6 +221,8 @@ static int bnxt_hwrm_send_message(struct bnxt *bp, void *msg,
                        rc = -EINVAL; \
                else if (rc == HWRM_ERR_CODE_CMD_NOT_SUPPORTED) \
                        rc = -ENOTSUP; \
+               else if (rc == HWRM_ERR_CODE_HOT_RESET_PROGRESS) \
+                       rc = -EAGAIN; \
                else if (rc > 0) \
                        rc = -EIO; \
                return rc; \
@@ -249,6 +251,8 @@ static int bnxt_hwrm_send_message(struct bnxt *bp, void *msg,
                        rc = -EINVAL; \
                else if (rc == HWRM_ERR_CODE_CMD_NOT_SUPPORTED) \
                        rc = -ENOTSUP; \
+               else if (rc == HWRM_ERR_CODE_HOT_RESET_PROGRESS) \
+                       rc = -EAGAIN; \
                else if (rc > 0) \
                        rc = -EIO; \
                return rc; \