[dpdk-dev] bond: update the NTT flag when partner's state changes from slow to fast

Message ID FC1AAE34B870124C835BDA1138D00F5C5A97A56F@DGGEMA501-MBX.china.huawei.com (mailing list archive)
State Superseded, archived
Headers

Checks

Context Check Description
ci/checkpatch warning coding style issues
ci/Intel-compilation fail apply patch file failure

Commit Message

zhangsha (A) May 22, 2017, 6:40 a.m. UTC
  From eddd395916002cca1c2f83a01d368b95295f2adf Mon Sep 17 00:00:00 2001
From: Sha Zhang <zhangsha.zhang@huawei.com>
Date: Mon, 22 May 2017 14:33:37 +0800
Subject: [PATCH] bond: update the NTT flag when partner's state changes from
slow to fast

According to the standard, state machine of lacp should transmit lacpdu
when partner's state changes from slow to fast, rather than from fast to slow.

Signed-off-by: Sha Zhang <zhangsha.zhang@huawei.com>
---
drivers/net/bonding/rte_eth_bond_8023ad.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

--
1.8.3.1
  

Comments

Doherty, Declan June 26, 2017, 3:17 p.m. UTC | #1
On 22/05/2017 7:40 AM, zhangsha (A) wrote:
> From eddd395916002cca1c2f83a01d368b95295f2adf Mon Sep 17 00:00:00 2001
> From: Sha Zhang <zhangsha.zhang@huawei.com>
> Date: Mon, 22 May 2017 14:33:37 +0800
> Subject: [PATCH] bond: update the NTT flag when partner's state changes from
> slow to fast
>
> According to the standard, state machine of lacp should transmit lacpdu
> when partner's state changes from slow to fast, rather than from fast to slow.
>
> Signed-off-by: Sha Zhang <zhangsha.zhang@huawei.com>
> ---
...
>

Acked-by: Declan Doherty <declan.doherty@intel.com>
  

Patch

diff --git a/drivers/net/bonding/rte_eth_bond_8023ad.c b/drivers/net/bonding/rte_eth_bond_8023ad.c
index 7b863d6..742fd44 100644
--- a/drivers/net/bonding/rte_eth_bond_8023ad.c
+++ b/drivers/net/bonding/rte_eth_bond_8023ad.c
@@ -435,7 +435,7 @@ 
                                                * In other case (was fast and now it is slow) just switch
                                                * timeout to slow without forcing send of LACP (because standard
                                                * say so)*/
-                                              if (!is_partner_fast)
+                                             if (is_partner_fast)
                                                               SM_FLAG_SET(port, NTT);
                               } else
                                               return; /* Nothing changed */