Fix kernel panic on various SMP machines. The culprit is a null
authorMark Huang <mlhuang@cs.princeton.edu>
Mon, 14 Aug 2006 15:10:44 +0000 (15:10 +0000)
committerMark Huang <mlhuang@cs.princeton.edu>
Mon, 14 Aug 2006 15:10:44 +0000 (15:10 +0000)
commit6eca7604f13afa67087ec9996628ce4aa881154c
treea97b635dc4c3016b9078a865a8898039540b04b1
parentc1c0d62ba011250a54b971920f0b6ed51407e8b7
Fix kernel panic on various SMP machines. The culprit is a null
ub->skb in ulog_send(). If ulog_timer() has already been scheduled on
one CPU and is spinning on the lock, and ipt_ulog_packet() flushes the
queue on another CPU by calling ulog_send() right before it exits,
there will be no skbuff when ulog_timer() acquires the lock and calls
ulog_send(). Cancelling the timer in ulog_send() doesn't help because
it has already been scheduled and is running on the first CPU.

Similar problem exists in ebt_ulog.c and nfnetlink_log.c.
net/bridge/netfilter/ebt_ulog.c
net/netfilter/nfnetlink_log.c