linux/net/ipv4/ipvs
Oleg Nesterov c214b2cc5f ipvs: flush defense_work before module unload
net/ipv4/ipvs/ip_vs_core.c

	module_exit
	    ip_vs_cleanup
		ip_vs_control_cleanup
		    cancel_rearming_delayed_work
	// done

This is unsafe.  The module may be unloaded and the memory may be freed
while defense_work's handler is still running/preempted.

Do flush_work(&defense_work.work) after cancel_rearming_delayed_work().

Alternatively, we could add flush_work() to cancel_rearming_delayed_work(),
but note that we can't change cancel_delayed_work() in the same manner
because it may be called from atomic context.

Signed-off-by: Oleg Nesterov <oleg@tv-sign.ru>
Cc: "David S. Miller" <davem@davemloft.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-05-09 12:30:52 -07:00
..
ip_vs_app.c [SK_BUFF]: Introduce skb_copy_to_linear_data{_offset} 2007-04-25 22:28:29 -07:00
ip_vs_conn.c [PATCH] mark struct file_operations const 7 2007-02-12 09:48:46 -08:00
ip_vs_core.c [NET]: Treat CHECKSUM_PARTIAL as CHECKSUM_UNNECESSARY 2007-04-25 22:28:43 -07:00
ip_vs_ctl.c ipvs: flush defense_work before module unload 2007-05-09 12:30:52 -07:00
ip_vs_dh.c [SK_BUFF]: Introduce ip_hdr(), remove skb->nh.iph 2007-04-25 22:25:10 -07:00
ip_vs_est.c [NET]: Conversions from kmalloc+memset to k(z|c)alloc. 2006-07-21 14:51:30 -07:00
ip_vs_ftp.c [SK_BUFF]: Convert skb->tail to sk_buff_data_t 2007-04-25 22:26:28 -07:00
ip_vs_lblc.c [SK_BUFF]: Introduce ip_hdr(), remove skb->nh.iph 2007-04-25 22:25:10 -07:00
ip_vs_lblcr.c [SK_BUFF]: Introduce ip_hdr(), remove skb->nh.iph 2007-04-25 22:25:10 -07:00
ip_vs_lc.c Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
ip_vs_nq.c Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
ip_vs_proto_ah.c [NET] IPV4: Use hton{s,l}() where appropriate. 2007-04-25 22:23:58 -07:00
ip_vs_proto_esp.c [INET_SOCK]: Move struct inet_sock & helper functions to net/inet_sock.h 2006-01-03 13:11:21 -08:00
ip_vs_proto_tcp.c [SK_BUFF]: Introduce ip_hdr(), remove skb->nh.iph 2007-04-25 22:25:10 -07:00
ip_vs_proto_udp.c [SK_BUFF]: Introduce ip_hdr(), remove skb->nh.iph 2007-04-25 22:25:10 -07:00
ip_vs_proto.c [IPVS]: Use kmemdup where appropriate 2006-12-02 21:30:16 -08:00
ip_vs_rr.c [NET] IPV4: Fix whitespace errors. 2007-02-10 23:19:39 -08:00
ip_vs_sched.c [PATCH] remove many unneeded #includes of sched.h 2007-02-14 08:09:54 -08:00
ip_vs_sed.c Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
ip_vs_sh.c [SK_BUFF]: Introduce ip_hdr(), remove skb->nh.iph 2007-04-25 22:25:10 -07:00
ip_vs_sync.c [IPVS]: Make ip_vs_sync.c <= 80col wide. 2006-12-11 14:35:03 -08:00
ip_vs_wlc.c Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
ip_vs_wrr.c Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
ip_vs_xmit.c [SK_BUFF]: Use offsets for skb->{mac,network,transport}_header on 64bit architectures 2007-04-25 22:26:21 -07:00
Kconfig Still more typo fixes 2006-10-03 22:36:44 +02:00
Makefile [IPVS]: remove net/ipv4/ipvs/ip_vs_proto_icmp.c 2005-06-02 13:02:25 -07:00