Commit b2883dfe authored by Dave Ertman's avatar Dave Ertman Committed by Jeff Kirsher

ice: Adjust DCB INIT for SW mode

Adjust ice_init_dcb to set the is_sw_lldp boolean
in the case where the FW has been detected to be
in an untenable state such that the driver
should forcibly make sure it is off.

This will ensure that the FW is in a known state.
Signed-off-by: default avatarDave Ertman <david.m.ertman@intel.com>
Tested-by: default avatarAndrew Bowers <andrewx.bowers@intel.com>
Signed-off-by: default avatarJeff Kirsher <jeffrey.t.kirsher@intel.com>
parent c6012ac1
...@@ -965,9 +965,9 @@ enum ice_status ice_init_dcb(struct ice_hw *hw, bool enable_mib_change) ...@@ -965,9 +965,9 @@ enum ice_status ice_init_dcb(struct ice_hw *hw, bool enable_mib_change)
pi->dcbx_status == ICE_DCBX_STATUS_NOT_STARTED) { pi->dcbx_status == ICE_DCBX_STATUS_NOT_STARTED) {
/* Get current DCBX configuration */ /* Get current DCBX configuration */
ret = ice_get_dcb_cfg(pi); ret = ice_get_dcb_cfg(pi);
pi->is_sw_lldp = (hw->adminq.sq_last_status == ICE_AQ_RC_EPERM);
if (ret) if (ret)
return ret; return ret;
pi->is_sw_lldp = false;
} else if (pi->dcbx_status == ICE_DCBX_STATUS_DIS) { } else if (pi->dcbx_status == ICE_DCBX_STATUS_DIS) {
return ICE_ERR_NOT_READY; return ICE_ERR_NOT_READY;
} }
...@@ -975,8 +975,8 @@ enum ice_status ice_init_dcb(struct ice_hw *hw, bool enable_mib_change) ...@@ -975,8 +975,8 @@ enum ice_status ice_init_dcb(struct ice_hw *hw, bool enable_mib_change)
/* Configure the LLDP MIB change event */ /* Configure the LLDP MIB change event */
if (enable_mib_change) { if (enable_mib_change) {
ret = ice_aq_cfg_lldp_mib_change(hw, true, NULL); ret = ice_aq_cfg_lldp_mib_change(hw, true, NULL);
if (!ret) if (ret)
pi->is_sw_lldp = false; pi->is_sw_lldp = true;
} }
return ret; return ret;
......
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