From: Bang Nguyen Date: Wed, 26 Mar 2014 04:52:46 +0000 (-0700) Subject: rds: Fix regression in dynamic active bonding configuration X-Git-Tag: v4.1.12-92~293^2^2~37 X-Git-Url: https://www.infradead.org/git/?a=commitdiff_plain;h=7b21ad5fd1801a5e94fb0e93b74d85894b52c387;p=users%2Fjedix%2Flinux-maple.git rds: Fix regression in dynamic active bonding configuration OraBug: 18481645 Commit 6cf7cc30 "rds: dynamic active bonding configuration" introduced a regression. Late joining IB interfaces were not configured correctly. When active bonding configuration shows both interfaces down, IP failover was not happening. This patch fixes this issue. Signed-off-by: Bang Nguyen Signed-off-by: Ajaykumar Hotchandani (cherry picked from commit 12755dbf7b4adc8ea2a935900b81c384731f6fff) Signed-off-by: Jerry Snitselaar (cherry picked from commit 12eebc4b9e28c3899089277ff9725bdcff1829aa) --- diff --git a/net/rds/ib.c b/net/rds/ib.c index 7bf7aa4c0e2e7..3fd8457b474d2 100644 --- a/net/rds/ib.c +++ b/net/rds/ib.c @@ -1032,14 +1032,8 @@ static void rds_ib_failback(struct work_struct *_work) u8 i, ip_active_port, port = work->port; if (ip_config[port].port_state == RDS_IB_PORT_INIT) { - printk(KERN_NOTICE "RDS/IB: %s/port_%d/%s is ERROR\n", - ip_config[port].rds_ibdev->dev->name, - ip_config[port].port_num, - ip_config[port].if_name); - - rds_ib_do_failover(port, 0, 0, work->event_type); - if (ip_config[port].ip_active_port != port) - ip_config[port].port_state = RDS_IB_PORT_DOWN; + ip_config[port].port_state = RDS_IB_PORT_UP; + ip_config[port].ip_active_port = port; goto out; } @@ -1195,7 +1189,9 @@ static void rds_ib_dump_ip_config(void) NIPQUAD(ip_config[i].ip_bcast), NIPQUAD(ip_config[i].ip_mask), (ip_config[i].port_state == - RDS_IB_PORT_UP ? "UP" : "DOWN")); + RDS_IB_PORT_UP ? "UP" : + (ip_config[i].port_state == + RDS_IB_PORT_DOWN ? "DOWN" : "INIT"))); for (j = 0; j < ip_config[i].alias_cnt; j++) { printk(KERN_INFO "Alias %s "