<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/drivers/net/bonding, branch v3.4.61</title>
<subtitle>Linux kernel source tree</subtitle>
<id>https://git.amat.us/linux/atom/drivers/net/bonding?h=v3.4.61</id>
<link rel='self' href='https://git.amat.us/linux/atom/drivers/net/bonding?h=v3.4.61'/>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/'/>
<updated>2013-06-27T18:27:33Z</updated>
<entry>
<title>bonding: rlb mode of bond should not alter ARP originating via bridge</title>
<updated>2013-06-27T18:27:33Z</updated>
<author>
<name>Zheng Li</name>
<email>zheng.x.li@oracle.com</email>
</author>
<published>2013-06-19T07:53:47Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=322130dea90940d65b811bd67790aecf86e6340f'/>
<id>urn:sha1:322130dea90940d65b811bd67790aecf86e6340f</id>
<content type='text'>
[ Upstream commit 567b871e503316b0927e54a3d7c86d50b722d955 ]

Do not modify or load balance ARP packets passing through balance-alb
mode (wherein the ARP did not originate locally, and arrived via a bridge).

Modifying pass-through ARP replies causes an incorrect MAC address
to be placed into the ARP packet, rendering peers unable to communicate
with the actual destination from which the ARP reply originated.

Load balancing pass-through ARP requests causes an entry to be
created for the peer in the rlb table, and bond_alb_monitor will
occasionally issue ARP updates to all peers in the table instrucing them
as to which MAC address they should communicate with; this occurs when
some event sets rx_ntt.  In the bridged case, however, the MAC address
used for the update would be the MAC of the slave, not the actual source
MAC of the originating destination.  This would render peers unable to
communicate with the destinations beyond the bridge.

Signed-off-by: Zheng Li &lt;zheng.x.li@oracle.com&gt;
Signed-off-by: Jay Vosburgh &lt;fubar@us.ibm.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
Signed-off-by: Matthew O'Connor &lt;liquidhorse@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>bonding: IFF_BONDING is not stripped on enslave failure</title>
<updated>2013-05-01T16:41:07Z</updated>
<author>
<name>nikolay@redhat.com</name>
<email>nikolay@redhat.com</email>
</author>
<published>2013-04-11T09:18:56Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=2a11e5fe4e27757d6316f25119ec02d4b3ab199a'/>
<id>urn:sha1:2a11e5fe4e27757d6316f25119ec02d4b3ab199a</id>
<content type='text'>
[ Upstream commit b6a5a7b9a528a8b4c8bec940b607c5dd9102b8cc ]

While enslaving a new device and after IFF_BONDING flag is set, in case
of failure it is not stripped from the device's priv_flags while
cleaning up, which could lead to other problems.
Cleaning at err_close because the flag is set after dev_open().

v2: no change

Signed-off-by: Nikolay Aleksandrov &lt;nikolay@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 bonding_masters race condition in bond unloading</title>
<updated>2013-05-01T16:41:06Z</updated>
<author>
<name>nikolay@redhat.com</name>
<email>nikolay@redhat.com</email>
</author>
<published>2013-04-06T00:54:38Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=643094adbef902c4a1f5a544f1f8eb8512e7ff8c'/>
<id>urn:sha1:643094adbef902c4a1f5a544f1f8eb8512e7ff8c</id>
<content type='text'>
[ Upstream commit 69b0216ac255f523556fa3d4ff030d857eaaa37f ]

While the bonding module is unloading, it is considered that after
rtnl_link_unregister all bond devices are destroyed but since no
synchronization mechanism exists, a new bond device can be created
via bonding_masters before unregister_pernet_subsys which would
lead to multiple problems (e.g. NULL pointer dereference, wrong RIP,
list corruption).

This patch fixes the issue by removing any bond devices left in the
netns after bonding_masters is removed from sysfs.

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: get netdev_rx_handler_unregister out of locks</title>
<updated>2013-04-05T17:04:52Z</updated>
<author>
<name>Veaceslav Falico</name>
<email>vfalico@redhat.com</email>
</author>
<published>2013-04-02T05:15:16Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=aa5ec2292c944b46ac536056b89ddfeb4e35fde3'/>
<id>urn:sha1:aa5ec2292c944b46ac536056b89ddfeb4e35fde3</id>
<content type='text'>
[ Upstream commit fcd99434fb5c137274d2e15dd2a6a7455f0f29ff ]

Now that netdev_rx_handler_unregister contains synchronize_net(), we need
to call it outside of bond-&gt;lock, cause it might sleep. Also, remove the
already unneded synchronize_net().

Signed-off-by: Veaceslav Falico &lt;vfalico@redhat.com&gt;
Acked-by: Eric Dumazet &lt;edumazet@google.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 disabling of arp_interval and miimon</title>
<updated>2013-04-05T17:04:39Z</updated>
<author>
<name>nikolay@redhat.com</name>
<email>nikolay@redhat.com</email>
</author>
<published>2013-03-27T03:32:41Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=ae8c63b03d7b70c0b65f1b6e304ed1976fb3019b'/>
<id>urn:sha1:ae8c63b03d7b70c0b65f1b6e304ed1976fb3019b</id>
<content type='text'>
[ Upstream commit 1bc7db16782c2a581fb4d53ca853631050f31611 ]

Currently if either arp_interval or miimon is disabled, they both get
disabled, and upon disabling they get executed once more which is not
the proper behaviour. Also when doing a no-op and disabling an already
disabled one, the other again gets disabled.
Also fix the error messages with the proper valid ranges, and a small
typo fix in the up delay error message (outputting "down delay", instead
of "up delay").

Signed-off-by: Nikolay Aleksandrov &lt;nikolay@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 miimon and arp_interval delayed work race conditions</title>
<updated>2013-04-05T17:04:39Z</updated>
<author>
<name>nikolay@redhat.com</name>
<email>nikolay@redhat.com</email>
</author>
<published>2012-11-29T01:31:31Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=d98ea1888738fea067a1411eaefc46637f1dad8d'/>
<id>urn:sha1:d98ea1888738fea067a1411eaefc46637f1dad8d</id>
<content type='text'>
[ Upstream commit fbb0c41b814d497c656fc7be9e35456f139cb2fb ]

First I would give three observations which will be used later.
Observation 1: if (delayed_work_pending(wq)) cancel_delayed_work(wq)
 This usage is wrong because the pending bit is cleared just before the
 work's fn is executed and if the function re-arms itself we might end up
 with the work still running. It's safe to call cancel_delayed_work_sync()
 even if the work is not queued at all.
Observation 2: Use of INIT_DELAYED_WORK()
 Work needs to be initialized only once prior to (de/en)queueing.
Observation 3: IFF_UP is set only after ndo_open is called

Related race conditions:
1. Race between bonding_store_miimon() and bonding_store_arp_interval()
 Because of Obs.1 we can end up having both works enqueued.
2. Multiple races with INIT_DELAYED_WORK()
 Since the works are not protected by anything between INIT_DELAYED_WORK()
 and calls to (en/de)queue it is possible for races between the following
 functions:
 (races are also possible between the calls to INIT_DELAYED_WORK()
  and workqueue code)
 bonding_store_miimon() - bonding_store_arp_interval(), bond_close(),
			  bond_open(), enqueued functions
 bonding_store_arp_interval() - bonding_store_miimon(), bond_close(),
				bond_open(), enqueued functions
3. By Obs.1 we need to change bond_cancel_all()

Bugs 1 and 2 are fixed by moving all work initializations in bond_open
which by Obs. 2 and Obs. 3 and the fact that we make sure that all works
are cancelled in bond_close(), is guaranteed not to have any work
enqueued.
Also RTNL lock is now acquired in bonding_store_miimon/arp_interval so
they can't race with bond_close and bond_open. The opposing work is
cancelled only if the IFF_UP flag is set and it is cancelled
unconditionally. The opposing work is already cancelled if the interface
is down so no need to cancel it again. This way we don't need new
synchronizations for the bonding workqueue. These bugs (and fixes) are
tied together and belong in the same patch.
Note: I have left 1 line intentionally over 80 characters (84) because I
      didn't like how it looks broken down. If you'd prefer it otherwise,
      then simply break it.

 v2: Make description text &lt; 75 columns

Signed-off-by: Nikolay Aleksandrov &lt;nikolay@redhat.com&gt;
Signed-off-by: Jay Vosburgh &lt;fubar@us.ibm.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: remove already created master sysfs link on failure</title>
<updated>2013-04-05T17:04:39Z</updated>
<author>
<name>Veaceslav Falico</name>
<email>vfalico@redhat.com</email>
</author>
<published>2013-03-26T16:43:28Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=b11b7d9b968aebaf70618db4393612784dfbebcd'/>
<id>urn:sha1:b11b7d9b968aebaf70618db4393612784dfbebcd</id>
<content type='text'>
[ Upstream commit 9fe16b78ee17579cb4f333534cf7043e94c67024 ]

If slave sysfs symlink failes to be created - we end up without removing
the master sysfs symlink. Remove it in case of failure.

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: don't call update_speed_duplex() under spinlocks</title>
<updated>2013-03-28T19:11:52Z</updated>
<author>
<name>Veaceslav Falico</name>
<email>vfalico@redhat.com</email>
</author>
<published>2013-03-12T06:31:32Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=e7778a61fff957a36c0e53fc565df17d68dcbee6'/>
<id>urn:sha1:e7778a61fff957a36c0e53fc565df17d68dcbee6</id>
<content type='text'>
[ Upstream commit 876254ae2758d50dcb08c7bd00caf6a806571178 ]

bond_update_speed_duplex() might sleep while calling underlying slave's
routines. Move it out of atomic context in bond_enslave() and remove it
from bond_miimon_commit() - it was introduced by commit 546add79, however
when the slave interfaces go up/change state it's their responsibility to
fire NETDEV_UP/NETDEV_CHANGE events so that bonding can properly update
their speed.

I've tested it on all combinations of ifup/ifdown, autoneg/speed/duplex
changes, remote-controlled and local, on (not) MII-based cards. All changes
are visible.

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 race condition in bonding_store_slaves_active</title>
<updated>2013-01-11T17:06:26Z</updated>
<author>
<name>nikolay@redhat.com</name>
<email>nikolay@redhat.com</email>
</author>
<published>2012-11-29T01:37:59Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=1097b6a83df844d5145a1f9821300028857d8ca9'/>
<id>urn:sha1:1097b6a83df844d5145a1f9821300028857d8ca9</id>
<content type='text'>
[ Upstream commit e196c0e579902f42cf72414461fb034e5a1ffbf7 ]

Race between bonding_store_slaves_active() and slave manipulation
 functions. The bond_for_each_slave use in bonding_store_slaves_active()
 is not protected by any synchronization mechanism.
 NULL pointer dereference is easy to reach.
 Fixed by acquiring the bond-&gt;lock for the slave walk.

 v2: Make description text &lt; 75 columns

Signed-off-by: Nikolay Aleksandrov &lt;nikolay@redhat.com&gt;
Signed-off-by: Jay Vosburgh &lt;fubar@us.ibm.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: Bonding driver does not consider the gso_max_size/gso_max_segs setting of slave devices.</title>
<updated>2013-01-11T17:06:26Z</updated>
<author>
<name>Sarveshwar Bandi</name>
<email>sarveshwar.bandi@emulex.com</email>
</author>
<published>2012-11-21T04:35:03Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=1789172140b7b61955b87b3070fb30da1a701d7c'/>
<id>urn:sha1:1789172140b7b61955b87b3070fb30da1a701d7c</id>
<content type='text'>
[ Upstream commit 0e376bd0b791ac6ac6bdb051492df0769c840848 ]

Patch sets the lowest gso_max_size and gso_max_segs values of the slave devices during enslave and detach.

Signed-off-by: Sarveshwar Bandi &lt;sarveshwar.bandi@emulex.com&gt;
Acked-by: Eric Dumazet &lt;edumazet@google.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>
</feed>
