i40e/base: increase PF reset max loop limit
[dpdk.git] / drivers / net / i40e / base / i40e_common.c
index 20bbce1..3ba2aee 100644 (file)
@@ -371,9 +371,27 @@ void i40e_debug_aq(struct i40e_hw *hw, enum i40e_debug_mask mask, void *desc,
 bool i40e_check_asq_alive(struct i40e_hw *hw)
 {
        if (hw->aq.asq.len)
-               return !!(rd32(hw, hw->aq.asq.len) & I40E_PF_ATQLEN_ATQENABLE_MASK);
-       else
-               return false;
+#ifdef PF_DRIVER
+#ifdef INTEGRATED_VF
+               if (!i40e_is_vf(hw))
+                       return !!(rd32(hw, hw->aq.asq.len) &
+                               I40E_PF_ATQLEN_ATQENABLE_MASK);
+#else
+               return !!(rd32(hw, hw->aq.asq.len) &
+                       I40E_PF_ATQLEN_ATQENABLE_MASK);
+#endif /* INTEGRATED_VF */
+#endif /* PF_DRIVER */
+#ifdef VF_DRIVER
+#ifdef INTEGRATED_VF
+               if (i40e_is_vf(hw))
+                       return !!(rd32(hw, hw->aq.asq.len) &
+                               I40E_VF_ATQLEN1_ATQENABLE_MASK);
+#else
+               return !!(rd32(hw, hw->aq.asq.len) &
+                       I40E_VF_ATQLEN1_ATQENABLE_MASK);
+#endif /* INTEGRATED_VF */
+#endif /* VF_DRIVER */
+       return false;
 }
 
 /**
@@ -1084,7 +1102,7 @@ STATIC enum i40e_media_type i40e_get_media_type(struct i40e_hw *hw)
        return media;
 }
 
-#define I40E_PF_RESET_WAIT_COUNT       110
+#define I40E_PF_RESET_WAIT_COUNT       200
 /**
  * i40e_pf_reset - Reset the PF
  * @hw: pointer to the hardware structure