err_recovery_lock needs to be released before returning in
stop and close_op if FW_RESET flag is set.
Fixes:
6f5f3b99821e ("net/bnxt: check chip reset in stop and close")
Signed-off-by: Somnath Kotur <somnath.kotur@broadcom.com>
Reviewed-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
if (bp->flags & BNXT_FLAG_FW_RESET) {
PMD_DRV_LOG(ERR,
"Adapter recovering from error..Please retry\n");
+ pthread_mutex_unlock(&bp->err_recovery_lock);
return -EAGAIN;
}
pthread_mutex_unlock(&bp->err_recovery_lock);
if (bp->flags & BNXT_FLAG_FW_RESET) {
PMD_DRV_LOG(ERR,
"Adapter recovering from error...Please retry\n");
+ pthread_mutex_unlock(&bp->err_recovery_lock);
return -EAGAIN;
}
pthread_mutex_unlock(&bp->err_recovery_lock);