bonding: pair enable_port with slave_arr_updates
Subsystems (3)
PATCH v2 1/1 bonding: pair enable_port with slave_arr_updates
When 803.2ad mode enables a participating port, it should update the slave-array. I have observed that the member links are participating and are part of the active aggregator while the traffic is egressing via only one member link (in a case where two links are participating). Via krpobes I discovered that that slave-arr has only one link added while the other participating link wasn't part of the slave-arr.
I couldn't see what caused that situation but the simple code-walk through provided me hints that the enable_port wasn't always associated with the slave-array update.
--- drivers/net/bonding/bond_3ad.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)
drivers/net/bonding/bond_3ad.c +4 -1
@@ -1021,8 +1021,9 @@ static void ad_mux_machine(struct port *port, bool *update_slave_arr)if (port->aggregator && port->aggregator->is_active && !__port_is_enabled (port)) { -__enable_port (port); +/* Slave array needs update */ + *update_slave_arr = true; } }break ;
@@ -1779,6 +1780,8 @@ static void ad_agg_selection_logic(struct aggregator *agg, port = port->next_port_in_aggregator) {__enable_port (port); } +/* Slave array needs update. */ + *update_slave_arr = true; } }
Signature · 1 line
2.35.0.rc2.247.g8bbb082509-goog
Quoted 7 lines · Mahesh Bandewar
When 803.2ad mode enables a participating port, it should update the slave-array. I have observed that the member links are participating and are part of the active aggregator while the traffic is egressing via only one member link (in a case where two links are participating). Via krpobes I discovered that that slave-arr has only one link added while the other participating link wasn't part of the slave-arr.
Quoted 6 lines
I couldn't see what caused that situation but the simple code-walk through provided me hints that the
enable_portwasn't always associated with the slave-array update.Change-Id I6c9ed91b027d53580734f1198579e71deee60bbfSigned-off-by Mahesh Bandewar <[email protected]>
Please remove the Change-Id line.
Quoted 9 lines
---
drivers/net/bonding/bond_3ad.c| 5 ++++-1 file changed, 4 insertions(+), 1 deletion(-)drivers/net/bonding/bond_3ad.c +0
-0
drivers/net/bonding/bond_3ad.c static void ad_mux_machine(struct port *port, bool *update_slave_arr) · line 1026
Quoted 7 lines
drivers/net/bonding/bond_3ad.c +2
-1@@ -1021,8 +1021,9 @@ static void ad_mux_machine(struct port *port, bool *update_slave_arr)if (port->aggregator && port->aggregator->is_active && !__port_is_enabled (port)) { -__enable_port (port); +/* Slave array needs update */ + *update_slave_arr = true;
Given the name of the variable here, I think the comment is
superfluous (both here and the change below).
Functionally, though, I think the change is reasonable. Could
you fix these two nits and repost?
-J
Quoted 15 lines
drivers/net/bonding/bond_3ad.c +2
-0} }break ;@@ -1779,6 +1780,8 @@ static void ad_agg_selection_logic(struct aggregator *agg, port = port->next_port_in_aggregator) {__enable_port (port); } +/* Slave array needs update. */ + *update_slave_arr = true; } }Signature · 1 line
2.35.0.rc2.247.g8bbb082509-goog
---
-Jay Vosburgh, [email protected]