-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[libteam] Send updates as soon as we need to update the LACP partner …
…about changes (#2955)
- Loading branch information
1 parent
6ca35b5
commit 3f4de49
Showing
2 changed files
with
40 additions
and
0 deletions.
There are no files selected for viewing
39 changes: 39 additions & 0 deletions
39
src/libteam/0014-Send-LACP-PDU-immediately-if-our-state-changed.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
From 0e0ee4a68b118d540d9ef5836a55483fcfb8771b Mon Sep 17 00:00:00 2001 | ||
From: Pavel Shirshov <[email protected]> | ||
Date: Wed, 29 May 2019 19:15:20 +0000 | ||
Subject: [PATCH] Send LACP PDU immediately if our state changed | ||
|
||
--- | ||
teamd/teamd_runner_lacp.c | 8 ++++---- | ||
1 file changed, 4 insertions(+), 4 deletions(-) | ||
|
||
diff --git a/teamd/teamd_runner_lacp.c b/teamd/teamd_runner_lacp.c | ||
index 19592c5..a505284 100644 | ||
--- a/teamd/teamd_runner_lacp.c | ||
+++ b/teamd/teamd_runner_lacp.c | ||
@@ -1049,8 +1049,7 @@ static int lacp_port_set_state(struct lacp_port *lacp_port, | ||
return err; | ||
|
||
lacp_port_actor_update(lacp_port); | ||
- if (lacp_port->periodic_on) | ||
- return 0; | ||
+ | ||
return lacpdu_send(lacp_port); | ||
} | ||
|
||
@@ -1160,9 +1159,10 @@ static int lacpdu_process(struct lacp_port *lacp_port, struct lacpdu* lacpdu) | ||
if (err) | ||
return err; | ||
|
||
+ lacp_port_actor_update(lacp_port); | ||
+ | ||
/* Check if the other side has correct info about us */ | ||
- if (!lacp_port->periodic_on && | ||
- memcmp(&lacpdu->partner, &lacp_port->actor, | ||
+ if (memcmp(&lacpdu->partner, &lacp_port->actor, | ||
sizeof(struct lacpdu_info))) { | ||
err = lacpdu_send(lacp_port); | ||
if (err) | ||
-- | ||
2.7.4 | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters