git: d025b84268ec - main - ixgbe: Apply the 82599 D3 link workaround only for D3
Kevin Bowling <[email protected]>
| Newsgroups | gmane.os.freebsd.devel.cvs.src |
|---|---|
| Message-ID | <6a75eb3d.44a15.5e2f06d9__32620.8816653647$1786112875$gmane$org@gitrepo.freebsd.org> |
The branch main has been updated by kbowling: URL: https://cgit.FreeBSD.org/src/commit/?id=d025b84268ec18d55c2d3088729cf4ad7673ecac commit d025b84268ec18d55c2d3088729cf4ad7673ecac Author: Kevin Bowling <[email protected]> AuthorDate: 2026-08-05 14:33:32 +0000 Commit: Kevin Bowling <[email protected]> CommitDate: 2026-08-07 14:26:41 +0000 ixgbe: Apply the 82599 D3 link workaround only for D3 ixgbe_stop_mac_link_on_d3_82599() implements the workaround for 82599 erratum 33. It forces incompatible auto-negotiation settings before the device enters D3, and reset clears them when returning to D0. ixgbe_if_stop() is also used for ordinary interface reconfiguration and recovery. Those paths do not enter D3 and should not program this power-management workaround. They continue to stop the adapter and disable the transmit laser. Move the call to ixgbe_setup_low_power_mode(), after ixgbe_if_stop(). This preserves the required ordering for detach, shutdown, and suspend while avoiding the D3 settings during ordinary restarts. MFC after: 2 weeks --- sys/dev/ixgbe/if_ix.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/sys/dev/ixgbe/if_ix.c b/sys/dev/ixgbe/if_ix.c index 96188ca7ef7f..5ab30a8054a9 100644 --- a/sys/dev/ixgbe/if_ix.c +++ b/sys/dev/ixgbe/if_ix.c @@ -3788,6 +3788,10 @@ ixgbe_setup_low_power_mode(if_ctx_t ctx) ixgbe_if_stop(ctx); } + /* Disable the 82599 link only when actually entering D3. */ + if (hw->mac.type == ixgbe_mac_82599EB) + ixgbe_stop_mac_link_on_d3_82599(hw); + return error; } /* ixgbe_setup_low_power_mode */ @@ -4758,8 +4762,6 @@ ixgbe_if_stop(if_ctx_t ctx) ixgbe_reset_hw(hw); hw->adapter_stopped = false; ixgbe_stop_adapter(hw); - if (hw->mac.type == ixgbe_mac_82599EB) - ixgbe_stop_mac_link_on_d3_82599(hw); /* Turn off the laser - noop with no optics */ ixgbe_disable_tx_laser(hw);