Browse Source

i40evf: resend FW request if no response

Sometimes the firmware will not indicate an error but fail to pass a
message between the VF and the PF driver. If this happens, just resend
the request.

This fixes an initialization failure if many VFs are instantiated at the
same time and the VF module is autoloaded.

Change-ID: Idd1ad8da2fd5137859244685c355941427d317d7
Signed-off-by: Mitch Williams <mitch.a.williams@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Mitch Williams 11 years ago
parent
commit
56f9920a95
1 changed files with 4 additions and 0 deletions
  1. 4 0
      drivers/net/ethernet/intel/i40evf/i40evf_main.c

+ 4 - 0
drivers/net/ethernet/intel/i40evf/i40evf_main.c

@@ -2018,6 +2018,10 @@ static void i40evf_init_task(struct work_struct *work)
 		if (err) {
 		if (err) {
 			dev_info(&pdev->dev, "Unable to verify API version (%d), retrying\n",
 			dev_info(&pdev->dev, "Unable to verify API version (%d), retrying\n",
 				err);
 				err);
+			if (err == I40E_ERR_ADMIN_QUEUE_NO_WORK) {
+				dev_info(&pdev->dev, "Resending request\n");
+				err = i40evf_send_api_ver(adapter);
+			}
 			goto err;
 			goto err;
 		}
 		}
 		err = i40evf_send_vf_config_msg(adapter);
 		err = i40evf_send_vf_config_msg(adapter);