alistair23-linux/drivers/net/bonding
Andy Gospodarek a0db2dad09 bonding: properly stop queuing work when requested
During a test where a pair of bonding interfaces using ARP monitoring
were both brought up and torn down (with an rmmod) repeatedly, a panic
in the timer code was noticed.  I tracked this down and determined that
any of the bonding functions that ran as workqueue handlers and requeued
more work might not properly exit when the module was removed.

There was a flag protected by the bond lock called kill_timers that is
set when the interface goes down or the module is removed, but many of
the functions that monitor link status now unlock the bond lock to take
rtnl first.  There is a chance that another CPU running the rmmod could
get the lock and set kill_timers after the first check has passed.

This patch does not allow any function to queue work that will make
itself run unless kill_timers is not set.  I also noticed while doing
this work that bond_resend_igmp_join_requests did not have a check for
kill_timers, so I added the needed call there as well.

Signed-off-by: Andy Gospodarek <andy@greyhouse.net>
Reported-by: Liang Zheng <lzheng@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2011-10-03 13:48:20 -04:00
..
bond_3ad.c bonding: properly stop queuing work when requested 2011-10-03 13:48:20 -04:00
bond_3ad.h
bond_alb.c bonding: properly stop queuing work when requested 2011-10-03 13:48:20 -04:00
bond_alb.h
bond_debugfs.c
bond_ipv6.c bonding: do vlan cleanup 2011-07-21 13:47:58 -07:00
bond_main.c bonding: properly stop queuing work when requested 2011-10-03 13:48:20 -04:00
bond_procfs.c bonding: add min links parameter to 802.3ad 2011-06-23 02:12:55 -07:00
bond_sysfs.c bonding: fix string comparison errors 2011-07-27 22:39:30 -07:00
bonding.h bonding: do vlan cleanup 2011-07-21 13:47:58 -07:00
Makefile