mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-01-28 13:40:55 -05:00
ice: Fix VSI rebuild WARN_ON check for VF
In commitb03d519d34("ice: store VF pointer instead of VF ID") WARN_ON checks were added to validate the vsi->vf pointer and catch programming errors. However, one check to vsi->vf was missed. This caused a call trace when resetting VFs. Fix ice_vsi_rebuild by encompassing VF pointer in WARN_ON check. Fixes:b03d519d34("ice: store VF pointer instead of VF ID") Signed-off-by: Benjamin Mikailenko <benjamin.mikailenko@intel.com> Tested-by: Marek Szlosek <marek.szlosek@intel.com> Signed-off-by: Tony Nguyen <anthony.l.nguyen@intel.com>
This commit is contained in:
committed by
Tony Nguyen
parent
84ba289016
commit
7fe05e125d
@@ -3181,7 +3181,7 @@ int ice_vsi_rebuild(struct ice_vsi *vsi, bool init_vsi)
|
||||
|
||||
pf = vsi->back;
|
||||
vtype = vsi->type;
|
||||
if (WARN_ON(vtype == ICE_VSI_VF) && !vsi->vf)
|
||||
if (WARN_ON(vtype == ICE_VSI_VF && !vsi->vf))
|
||||
return -EINVAL;
|
||||
|
||||
ice_vsi_init_vlan_ops(vsi);
|
||||
|
||||
Reference in New Issue
Block a user