summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Brown2018-03-19 14:47:39 +0100
committerMichael Brown2018-03-19 14:47:39 +0100
commit342ff967cc109f8e21e743d841434b08737d9e6c (patch)
tree4f577d1266defaa42311a596e00834f4b532f791
parent[ocsp] Allow OCSP checks to be disabled (diff)
downloadipxe-342ff967cc109f8e21e743d841434b08737d9e6c.tar.gz
ipxe-342ff967cc109f8e21e743d841434b08737d9e6c.tar.xz
ipxe-342ff967cc109f8e21e743d841434b08737d9e6c.zip
[lacp] Check the partner's own state when checking for blocked links
The blocked link test in eth_slow_lacp_rx() is performed before the actor TLV is copied to the partner TLV, and so must test the actor state field rather than the partner state field. Signed-off-by: Michael Brown <mcb30@ipxe.org>
-rw-r--r--src/net/eth_slow.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/net/eth_slow.c b/src/net/eth_slow.c
index cbc22aef..baa51dbc 100644
--- a/src/net/eth_slow.c
+++ b/src/net/eth_slow.c
@@ -157,11 +157,11 @@ static int eth_slow_lacp_rx ( struct io_buffer *iobuf,
* then block the link until after the next expected LACP
* packet.
*/
- if ( ~lacp->partner.state & ( LACP_STATE_IN_SYNC |
- LACP_STATE_COLLECTING |
- LACP_STATE_DISTRIBUTING ) ) {
+ if ( ~lacp->actor.state & ( LACP_STATE_IN_SYNC |
+ LACP_STATE_COLLECTING |
+ LACP_STATE_DISTRIBUTING ) ) {
DBGC ( netdev, "SLOW %s LACP partner is down\n", netdev->name );
- interval = ( ( lacp->partner.state & LACP_STATE_FAST ) ?
+ interval = ( ( lacp->actor.state & LACP_STATE_FAST ) ?
( ( LACP_INTERVAL_FAST + 1 ) * TICKS_PER_SEC ) :
( ( LACP_INTERVAL_SLOW + 1 ) * TICKS_PER_SEC ) );
netdev_link_block ( netdev, interval );