]> git.baikalelectronics.ru Git - kernel.git/commit
bonding: set primary param via sysfs
authorJiri Pirko <jpirko@redhat.com>
Fri, 18 Sep 2009 02:13:22 +0000 (02:13 +0000)
committerDavid S. Miller <davem@davemloft.net>
Thu, 1 Oct 2009 21:34:29 +0000 (14:34 -0700)
commit4518849eb6128e07e5590e6c938abd08b78c6fa3
treea373ef184d4dd1fa175617f1fdec7bc0f7eeef65
parent3a4c0541adabf551a56529e978253ca8238a889c
bonding: set primary param via sysfs

Primary module parameter passed to bonding is pernament. That means if you
release the primary slave and enslave it again, it becomes the primary slave
again. But if you set primary slave via sysfs, the primary slave is only set
once and it's not remembered in bond->params structure. Therefore the setting is
lost after releasing the primary slave. This simple one-liner fixes this.

Signed-off-by: Jiri Pirko <jpirko@redhat.com>
Signed-off-by: Jay Vosburgh <fubar@us.ibm.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/bonding/bond_sysfs.c