Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1692450 > unrolled thread

[PATCH] net: bonding: Fix transmit load balancing in balance-alb mode

Started byKosuke Tatsukawa <tatsu@ab.jp.nec.com>
First post2017-07-20 07:40 +0200
Last post2017-07-21 00:40 +0200
Articles 3 — 3 participants

Back to article view | Back to linux.kernel


Contents

  [PATCH] net: bonding: Fix transmit load balancing in balance-alb  mode Kosuke Tatsukawa <tatsu@ab.jp.nec.com> - 2017-07-20 07:40 +0200
    Re: [PATCH] net: bonding: Fix transmit load balancing in balance-alb mode Andy Gospodarek <andy@greyhouse.net> - 2017-07-20 16:10 +0200
    Re: [PATCH] net: bonding: Fix transmit load balancing in  balance-alb mode David Miller <davem@davemloft.net> - 2017-07-21 00:40 +0200

#1692450 — [PATCH] net: bonding: Fix transmit load balancing in balance-alb mode

FromKosuke Tatsukawa <tatsu@ab.jp.nec.com>
Date2017-07-20 07:40 +0200
Subject[PATCH] net: bonding: Fix transmit load balancing in balance-alb mode
Message-ID<u5clR-2N9-27@gated-at.bofh.it>
balance-alb mode used to have transmit dynamic load balancing feature
enabled by default.  However, transmit dynamic load balancing no longer
works in balance-alb after commit 8b426dc54cf4 ("bonding: remove
hardcoded value").

Both balance-tlb and balance-alb use the function bond_do_alb_xmit() to
send packets.  This function uses the parameter tlb_dynamic_lb.
tlb_dynamic_lb used to have the default value of 1 for balance-alb, but
now the value is set to 0 except in balance-tlb.

Re-enable transmit dyanmic load balancing by initializing tlb_dynamic_lb
for balance-alb similar to balance-tlb.

Signed-off-by: Kosuke Tatsukawa <tatsu@ab.jp.nec.com>
Cc: stable@vger.kernel.org
---
 drivers/net/bonding/bond_main.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/net/bonding/bond_main.c b/drivers/net/bonding/bond_main.c
index 14ff622..181839d 100644
--- a/drivers/net/bonding/bond_main.c
+++ b/drivers/net/bonding/bond_main.c
@@ -4596,7 +4596,7 @@ static int bond_check_params(struct bond_params *params)
 	}
 	ad_user_port_key = valptr->value;
 
-	if (bond_mode == BOND_MODE_TLB) {
+	if ((bond_mode == BOND_MODE_TLB) || (bond_mode == BOND_MODE_ALB)) {
 		bond_opt_initstr(&newval, "default");
 		valptr = bond_opt_parse(bond_opt_get(BOND_OPT_TLB_DYNAMIC_LB),
 					&newval);

[toc] | [next] | [standalone]


#1692967 — Re: [PATCH] net: bonding: Fix transmit load balancing in balance-alb mode

FromAndy Gospodarek <andy@greyhouse.net>
Date2017-07-20 16:10 +0200
SubjectRe: [PATCH] net: bonding: Fix transmit load balancing in balance-alb mode
Message-ID<u5kjo-7N-15@gated-at.bofh.it>
In reply to#1692450
On Thu, Jul 20, 2017 at 1:20 AM, Kosuke Tatsukawa <tatsu@ab.jp.nec.com> wrote:
> balance-alb mode used to have transmit dynamic load balancing feature
> enabled by default.  However, transmit dynamic load balancing no longer
> works in balance-alb after commit 8b426dc54cf4 ("bonding: remove
> hardcoded value").
>
> Both balance-tlb and balance-alb use the function bond_do_alb_xmit() to
> send packets.  This function uses the parameter tlb_dynamic_lb.
> tlb_dynamic_lb used to have the default value of 1 for balance-alb, but
> now the value is set to 0 except in balance-tlb.
>
> Re-enable transmit dyanmic load balancing by initializing tlb_dynamic_lb
> for balance-alb similar to balance-tlb.
>
> Signed-off-by: Kosuke Tatsukawa <tatsu@ab.jp.nec.com>
> Cc: stable@vger.kernel.org

You probably should add:

Fixes: 8b426dc54cf4 ("bonding: remove hardcoded value").

Otherwise this looks reasonable to me.

Acked-by: Andy Gospodarek <andy@greyhouse.net>


> ---
>  drivers/net/bonding/bond_main.c |    2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/drivers/net/bonding/bond_main.c b/drivers/net/bonding/bond_main.c
> index 14ff622..181839d 100644
> --- a/drivers/net/bonding/bond_main.c
> +++ b/drivers/net/bonding/bond_main.c
> @@ -4596,7 +4596,7 @@ static int bond_check_params(struct bond_params *params)
>         }
>         ad_user_port_key = valptr->value;
>
> -       if (bond_mode == BOND_MODE_TLB) {
> +       if ((bond_mode == BOND_MODE_TLB) || (bond_mode == BOND_MODE_ALB)) {
>                 bond_opt_initstr(&newval, "default");
>                 valptr = bond_opt_parse(bond_opt_get(BOND_OPT_TLB_DYNAMIC_LB),
>                                         &newval);
>

[toc] | [prev] | [next] | [standalone]


#1693265 — Re: [PATCH] net: bonding: Fix transmit load balancing in balance-alb mode

FromDavid Miller <davem@davemloft.net>
Date2017-07-21 00:40 +0200
SubjectRe: [PATCH] net: bonding: Fix transmit load balancing in balance-alb mode
Message-ID<u5sgV-4Zm-5@gated-at.bofh.it>
In reply to#1692450
From: Kosuke Tatsukawa <tatsu@ab.jp.nec.com>
Date: Thu, 20 Jul 2017 05:20:40 +0000

> balance-alb mode used to have transmit dynamic load balancing feature
> enabled by default.  However, transmit dynamic load balancing no longer
> works in balance-alb after commit 8b426dc54cf4 ("bonding: remove
> hardcoded value").
> 
> Both balance-tlb and balance-alb use the function bond_do_alb_xmit() to
> send packets.  This function uses the parameter tlb_dynamic_lb.
> tlb_dynamic_lb used to have the default value of 1 for balance-alb, but
> now the value is set to 0 except in balance-tlb.
> 
> Re-enable transmit dyanmic load balancing by initializing tlb_dynamic_lb
> for balance-alb similar to balance-tlb.
> 
> Signed-off-by: Kosuke Tatsukawa <tatsu@ab.jp.nec.com>

Applied and queued up for -stable, thanks.

Andy, thanks for the Fixes: tag.

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web