]> git.baikalelectronics.ru Git - kernel.git/commit
Merge branch 'bonding'
authorDavid S. Miller <davem@davemloft.net>
Thu, 22 May 2014 19:46:38 +0000 (15:46 -0400)
committerDavid S. Miller <davem@davemloft.net>
Thu, 22 May 2014 19:46:38 +0000 (15:46 -0400)
commit2f48a46d92d8f15f30c1b67a50f2b5e9de8629dc
tree8fac08b65e226b156f8cfe3089fb8dfbae4cc323
parente9f1da106dfd96965cd76c7c2eed969689d7f6b5
parent40b9e593fa762322ba1b94a78b41436690eb97c3
Merge branch 'bonding'

Veaceslav Falico says:

====================
bonding: fix enslaving a dev without mtu setting support

With the introduction of bond_free_slave() we need to have slave->bond
populated before calling it, however if the dev_mtu_set(slave, mtu) fails,
we call bond_free_slave() before actually setting slave->bond, and thus
we'll panic.

Fix this by populating slave->bond (and ->dev, it seems appropriate) as
early as possible.

Also, remove a harmful check for NULL in bond_get_bond_by_slave(), as it's
only hiding the real problem and making it harder to debug.
====================

CC: Jay Vosburgh <j.vosburgh@gmail.com>
CC: Andy Gospodarek <andy@greyhouse.net>
CC: netdev@vger.kernel.org
Signed-off-by: Veaceslav Falico <vfalico@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>