<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/drivers/net/bonding, branch v3.12.15</title>
<subtitle>Linux kernel source tree</subtitle>
<id>https://git.amat.us/linux/atom/drivers/net/bonding?h=v3.12.15</id>
<link rel='self' href='https://git.amat.us/linux/atom/drivers/net/bonding?h=v3.12.15'/>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/'/>
<updated>2014-02-26T09:22:52Z</updated>
<entry>
<title>bonding: 802.3ad: make aggregator_identifier bond-private</title>
<updated>2014-02-26T09:22:52Z</updated>
<author>
<name>Jiri Bohac</name>
<email>jiri@boha.cz</email>
</author>
<published>2014-02-14T17:13:50Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=c92210fdc60d7be2ece4fbdbdd82d811355583d8'/>
<id>urn:sha1:c92210fdc60d7be2ece4fbdbdd82d811355583d8</id>
<content type='text'>
[ Upstream commit 163c8ff30dbe473abfbb24a7eac5536c87f3baa9 ]

aggregator_identifier is used to assign unique aggregator identifiers
to aggregators of a bond during device enslaving.

aggregator_identifier is currently a global variable that is zeroed in
bond_3ad_initialize().

This sequence will lead to duplicate aggregator identifiers for eth1 and eth3:

create bond0
change bond0 mode to 802.3ad
enslave eth0 to bond0 		//eth0 gets agg id 1
enslave eth1 to bond0 		//eth1 gets agg id 2
create bond1
change bond1 mode to 802.3ad
enslave eth2 to bond1		//aggregator_identifier is reset to 0
				//eth2 gets agg id 1
enslave eth3 to bond0 		//eth3 gets agg id 2

Fix this by making aggregator_identifier private to the bond.

Signed-off-by: Jiri Bohac &lt;jbohac@suse.cz&gt;
Acked-by: Veaceslav Falico &lt;vfalico@redhat.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
Signed-off-by: Jiri Slaby &lt;jslaby@suse.cz&gt;
</content>
</entry>
<entry>
<title>bonding: fix two race conditions in bond_store_updelay/downdelay</title>
<updated>2013-12-08T15:29:12Z</updated>
<author>
<name>Nikolay Aleksandrov</name>
<email>nikolay@redhat.com</email>
</author>
<published>2013-11-13T16:07:46Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=accbc62ee04bb72ee23a96ec10b0a6a2e2260a55'/>
<id>urn:sha1:accbc62ee04bb72ee23a96ec10b0a6a2e2260a55</id>
<content type='text'>
[ Upstream commit b869ccfab1e324507fa3596e3e1308444fb68227 ]

This patch fixes two race conditions between bond_store_updelay/downdelay
and bond_store_miimon which could lead to division by zero as miimon can
be set to 0 while either updelay/downdelay are being set and thus miss the
zero check in the beginning, the zero div happens because updelay/downdelay
are stored as new_value / bond-&gt;params.miimon. Use rtnl to synchronize with
miimon setting.

CC: Jay Vosburgh &lt;fubar@us.ibm.com&gt;
CC: Andy Gospodarek &lt;andy@greyhouse.net&gt;
CC: Veaceslav Falico &lt;vfalico@redhat.com&gt;
Signed-off-by: Nikolay Aleksandrov &lt;nikolay@redhat.com&gt;
Acked-by: Veaceslav Falico &lt;vfalico@redhat.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>bonding: don't permit to use ARP monitoring in 802.3ad mode</title>
<updated>2013-12-08T15:29:11Z</updated>
<author>
<name>Veaceslav Falico</name>
<email>vfalico@redhat.com</email>
</author>
<published>2013-11-12T14:37:40Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=24e9fcb4cf4653bc4142fd05f3a87dc42f31375a'/>
<id>urn:sha1:24e9fcb4cf4653bc4142fd05f3a87dc42f31375a</id>
<content type='text'>
[ Upstream commit ec9f1d15db8185f63a2c3143dc1e90ba18541b08 ]

Currently the ARP monitoring is not supported with 802.3ad, and it's
prohibited to use it via the module params.

However we still can set it afterwards via sysfs, cause we only check for
*LB modes there.

To fix this - add a check for 802.3ad mode in bonding_store_arp_interval.

CC: Jay Vosburgh &lt;fubar@us.ibm.com&gt;
CC: Andy Gospodarek &lt;andy@greyhouse.net&gt;
Signed-off-by: Veaceslav Falico &lt;vfalico@redhat.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>bonding: RCUify bond_set_rx_mode()</title>
<updated>2013-12-08T15:29:11Z</updated>
<author>
<name>Veaceslav Falico</name>
<email>vfalico@redhat.com</email>
</author>
<published>2013-09-28T19:18:56Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=6281cb601b21207cde24e0c5b43a3da56227b21d'/>
<id>urn:sha1:6281cb601b21207cde24e0c5b43a3da56227b21d</id>
<content type='text'>
[ Upstream commit b32418705107265dfca5edfe2b547643e53a732e ]

Currently we rely on rtnl locking in bond_set_rx_mode(), however it's not
always the case:

RTNL: assertion failed at drivers/net/bonding/bond_main.c (3391)
...
 [&lt;ffffffff81651ca5&gt;] dump_stack+0x54/0x74
 [&lt;ffffffffa029e717&gt;] bond_set_rx_mode+0xc7/0xd0 [bonding]
 [&lt;ffffffff81553af7&gt;] __dev_set_rx_mode+0x57/0xa0
 [&lt;ffffffff81557ff8&gt;] __dev_mc_add+0x58/0x70
 [&lt;ffffffff81558020&gt;] dev_mc_add+0x10/0x20
 [&lt;ffffffff8161e26e&gt;] igmp6_group_added+0x18e/0x1d0
 [&lt;ffffffff81186f76&gt;] ? kmem_cache_alloc_trace+0x236/0x260
 [&lt;ffffffff8161f80f&gt;] ipv6_dev_mc_inc+0x29f/0x320
 [&lt;ffffffff8161f9e7&gt;] ipv6_sock_mc_join+0x157/0x260
...

Fix this by using RCU primitives.

Reported-by: Joe Lawrence &lt;joe.lawrence@stratus.com&gt;
Tested-by: Joe Lawrence &lt;joe.lawrence@stratus.com&gt;
CC: Jay Vosburgh &lt;fubar@us.ibm.com&gt;
CC: Andy Gospodarek &lt;andy@greyhouse.net&gt;
Signed-off-by: Veaceslav Falico &lt;vfalico@redhat.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>bonding: Fix broken promiscuity reference counting issue</title>
<updated>2013-10-01T04:10:55Z</updated>
<author>
<name>Neil Horman</name>
<email>nhorman@tuxdriver.com</email>
</author>
<published>2013-09-27T16:22:15Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=5a0068deb611109c5ba77358be533f763f395ee4'/>
<id>urn:sha1:5a0068deb611109c5ba77358be533f763f395ee4</id>
<content type='text'>
Recently grabbed this report:
https://bugzilla.redhat.com/show_bug.cgi?id=1005567

Of an issue in which the bonding driver, with an attached vlan encountered the
following errors when bond0 was taken down and back up:

dummy1: promiscuity touches roof, set promiscuity failed. promiscuity feature of
device might be broken.

The error occurs because, during __bond_release_one, if we release our last
slave, we take on a random mac address and issue a NETDEV_CHANGEADDR
notification.  With an attached vlan, the vlan may see that the vlan and bond
mac address were in sync, but no longer are.  This triggers a call to dev_uc_add
and dev_set_rx_mode, which enables IFF_PROMISC on the bond device.  Then, when
we complete __bond_release_one, we use the current state of the bond flags to
determine if we should decrement the promiscuity of the releasing slave.  But
since the bond changed promiscuity state during the release operation, we
incorrectly decrement the slave promisc count when it wasn't in promiscuous mode
to begin with, causing the above error

Fix is pretty simple, just cache the bonding flags at the start of the function
and use those when determining the need to set promiscuity.

This is also needed for the ALLMULTI flag

CC: Jay Vosburgh &lt;fubar@us.ibm.com&gt;
CC: Andy Gospodarek &lt;andy@greyhouse.net&gt;
CC: Mark Wu &lt;wudxw@linux.vnet.ibm.com&gt;
CC: "David S. Miller" &lt;davem@davemloft.net&gt;
Reported-by: Mark Wu &lt;wudxw@linux.vnet.ibm.com&gt;

Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>bonding: Make alb learning packet interval configurable</title>
<updated>2013-09-16T02:20:44Z</updated>
<author>
<name>Neil Horman</name>
<email>nhorman@tuxdriver.com</email>
</author>
<published>2013-09-13T15:05:33Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=7eacd03810960823393521063734fc8188446bca'/>
<id>urn:sha1:7eacd03810960823393521063734fc8188446bca</id>
<content type='text'>
running bonding in ALB mode requires that learning packets be sent periodically,
so that the switch knows where to send responding traffic.  However, depending
on switch configuration, there may not be any need to send traffic at the
default rate of 3 packets per second, which represents little more than wasted
data.  Allow the ALB learning packet interval to be made configurable via sysfs

Signed-off-by: Neil Horman &lt;nhorman@tuxdriver.com&gt;
Acked-by: Acked-by: Veaceslav Falico &lt;vfalico@redhat.com&gt;
CC: Jay Vosburgh &lt;fubar@us.ibm.com&gt;
CC: Andy Gospodarek &lt;andy@greyhouse.net&gt;
CC: "David S. Miller" &lt;davem@davemloft.net&gt;
Signed-off-by: Andy Gospodarek &lt;andy@greyhouse.net&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>bonding: fix bond_arp_rcv setting and arp validate desync state</title>
<updated>2013-09-11T19:55:17Z</updated>
<author>
<name>nikolay@redhat.com</name>
<email>nikolay@redhat.com</email>
</author>
<published>2013-09-06T22:00:26Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=5bb9e0b50d2188d8fac481742d9f801436e2c5ab'/>
<id>urn:sha1:5bb9e0b50d2188d8fac481742d9f801436e2c5ab</id>
<content type='text'>
We make bond_arp_rcv global so it can be used in bond_sysfs if the bond
interface is up and arp_interval is being changed to a positive value
and cleared otherwise as per Jay's suggestion.
This also fixes a problem where bond_arp_rcv was set even though
arp_validate was disabled while the bond was up by unsetting recv_probe
in bond_store_arp_validate and respectively setting it if enabled.

Signed-off-by: Nikolay Aleksandrov &lt;nikolay@redhat.com&gt;
Signed-off-by: Marcelo Ricardo Leitner &lt;mleitner@redhat.com&gt;
Acked-by: Veaceslav Falico &lt;vfalico@redhat.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>bonding: fix store_arp_validate race with mode change</title>
<updated>2013-09-11T19:55:17Z</updated>
<author>
<name>nikolay@redhat.com</name>
<email>nikolay@redhat.com</email>
</author>
<published>2013-09-06T22:00:25Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=5c5038dc26bdc609022a897e15f9ccdd28402ad9'/>
<id>urn:sha1:5c5038dc26bdc609022a897e15f9ccdd28402ad9</id>
<content type='text'>
We need to protect store_arp_validate via rtnl because it can race with
mode changing and we can end up having arp_validate set in a mode
different from active-backup.

Signed-off-by: Nikolay Aleksandrov &lt;nikolay@redhat.com&gt;
Acked-by: Veaceslav Falico &lt;vfalico@redhat.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>bonding: drop read_lock in bond_compute_features</title>
<updated>2013-09-04T04:27:25Z</updated>
<author>
<name>nikolay@redhat.com</name>
<email>nikolay@redhat.com</email>
</author>
<published>2013-09-02T11:51:42Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=c48268611a3df84a9250d2fc34ad671cdae43440'/>
<id>urn:sha1:c48268611a3df84a9250d2fc34ad671cdae43440</id>
<content type='text'>
bond_compute_features is always called with RTNL held, so we can safely
drop the read bond-&gt;lock.

Signed-off-by: Nikolay Aleksandrov &lt;nikolay@redhat.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>bonding: drop read_lock in bond_fix_features</title>
<updated>2013-09-04T04:27:25Z</updated>
<author>
<name>nikolay@redhat.com</name>
<email>nikolay@redhat.com</email>
</author>
<published>2013-09-02T11:51:41Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=9b7b165ac1adf5169f0ee03d107423ce7f5805d9'/>
<id>urn:sha1:9b7b165ac1adf5169f0ee03d107423ce7f5805d9</id>
<content type='text'>
We're protected by RTNL so nothing can happen and we can safely drop the
read bond-&gt;lock.

Signed-off-by: Nikolay Aleksandrov &lt;nikolay@redhat.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
</feed>
