Skip to content

Commit

Permalink
ice: handle the VF VSI rebuild failure
Browse files Browse the repository at this point in the history
VSI rebuild can be failed for LAN queue config, then the VF's VSI will
be NULL, the VF reset should be stopped with the VF entering into the
disable state.

Fixes: 12bb018 ("ice: Refactor VF reset")
Signed-off-by: Haiyue Wang <haiyue.wang@intel.com>
Tested-by: Konrad Jankowski <konrad0.jankowski@intel.com>
Signed-off-by: Tony Nguyen <anthony.l.nguyen@intel.com>
  • Loading branch information
haiyuewa authored and anguy11 committed Jun 4, 2021
1 parent 8679f07 commit c7ee6ce
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion drivers/net/ethernet/intel/ice/ice_virtchnl_pf.c
Original file line number Diff line number Diff line change
Expand Up @@ -1700,7 +1700,12 @@ bool ice_reset_vf(struct ice_vf *vf, bool is_vflr)
ice_vf_ctrl_vsi_release(vf);

ice_vf_pre_vsi_rebuild(vf);
ice_vf_rebuild_vsi_with_release(vf);

if (ice_vf_rebuild_vsi_with_release(vf)) {
dev_err(dev, "Failed to release and setup the VF%u's VSI\n", vf->vf_id);
return false;
}

ice_vf_post_vsi_rebuild(vf);

/* if the VF has been reset allow it to come up again */
Expand Down

0 comments on commit c7ee6ce

Please sign in to comment.