Commit 06914ac2 authored by Mitch Williams's avatar Mitch Williams Committed by Jeff Kirsher

ice: Always notify FW of VF reset

The call to ice_dis_vsi_txq() acts as the notification to the firmware
that the VF is being reset. Because of this, we need to make this call
every time we reset, regardless of whatever else we do to stop the Tx
queues.

Without this change, VF resets would fail to complete on interfaces that
were up and running.
Signed-off-by: default avatarMitch Williams <mitch.a.williams@intel.com>
Tested-by: default avatarAndrew Bowers <andrewx.bowers@intel.com>
Signed-off-by: default avatarJeff Kirsher <jeffrey.t.kirsher@intel.com>
parent 473ca574
...@@ -1074,9 +1074,16 @@ bool ice_reset_all_vfs(struct ice_pf *pf, bool is_vflr) ...@@ -1074,9 +1074,16 @@ bool ice_reset_all_vfs(struct ice_pf *pf, bool is_vflr)
for (v = 0; v < pf->num_alloc_vfs; v++) for (v = 0; v < pf->num_alloc_vfs; v++)
ice_trigger_vf_reset(&pf->vf[v], is_vflr); ice_trigger_vf_reset(&pf->vf[v], is_vflr);
for (v = 0; v < pf->num_alloc_vfs; v++) for (v = 0; v < pf->num_alloc_vfs; v++) {
if (test_bit(ICE_VF_STATE_QS_ENA, pf->vf[v].vf_states)) struct ice_vsi *vsi;
ice_dis_vf_qs(&pf->vf[v]);
vf = &pf->vf[v];
vsi = pf->vsi[vf->lan_vsi_idx];
if (test_bit(ICE_VF_STATE_QS_ENA, vf->vf_states))
ice_dis_vf_qs(vf);
ice_dis_vsi_txq(vsi->port_info, vsi->idx, 0, 0, NULL, NULL,
NULL, ICE_VF_RESET, vf->vf_id, NULL);
}
/* HW requires some time to make sure it can flush the FIFO for a VF /* HW requires some time to make sure it can flush the FIFO for a VF
* when it resets it. Poll the VPGEN_VFRSTAT register for each VF in * when it resets it. Poll the VPGEN_VFRSTAT register for each VF in
...@@ -1171,9 +1178,9 @@ static bool ice_reset_vf(struct ice_vf *vf, bool is_vflr) ...@@ -1171,9 +1178,9 @@ static bool ice_reset_vf(struct ice_vf *vf, bool is_vflr)
if (test_bit(ICE_VF_STATE_QS_ENA, vf->vf_states)) if (test_bit(ICE_VF_STATE_QS_ENA, vf->vf_states))
ice_dis_vf_qs(vf); ice_dis_vf_qs(vf);
else
/* Call Disable LAN Tx queue AQ call even when queues are not /* Call Disable LAN Tx queue AQ whether or not queues are
* enabled. This is needed for successful completion of VFR * enabled. This is needed for successful completion of VFR.
*/ */
ice_dis_vsi_txq(vsi->port_info, vsi->idx, 0, 0, NULL, NULL, ice_dis_vsi_txq(vsi->port_info, vsi->idx, 0, 0, NULL, NULL,
NULL, ICE_VF_RESET, vf->vf_id, NULL); NULL, ICE_VF_RESET, vf->vf_id, NULL);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment