Re: [Patch V2] bonding: fix netpoll in active-backup mode

From: Cong Wang
Date: Wed Mar 09 2011 - 07:33:44 EST


ä 2011å03æ08æ 21:43, Neil Horman åé:
On Tue, Mar 08, 2011 at 05:58:56PM +0800, Amerigo Wang wrote:
V2: avoid calling slave_diable_netpoll() with write_lock_bh() held.

netconsole doesn't work in active-backup mode, because we don't do anything
for nic failover in active-backup mode. We should disable netpoll on the
failing slave when it is detected down and enable netpoll when it becomes
the active slave.

You still haven't explained why it needs to be this way. what exactly is the
shortcomming with leaving netpoll enabled on all slaves, regardless of state?
It should be sufficient if, during a failover in a mode where the inactive slave
should not tx data, that you simply clear the slave __LINK_STATE_START bit. That will
prevent higher layers from sending any queued data without you needing to muck
about with netpoll state.


Oh, actually I thought the struct net_device of the failing interface will be freed,
but that is not true...

So, yeah, I think just setup netpoll in bond_netpoll_setup() should be sufficient.

Thanks.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/