[IFB]: Fix crash on input device removal
commit5f4a9d1b7a413d6aac382c51692ac0df785068c5
authorPatrick McHardy <kaber@trash.net>
Tue, 3 Apr 2007 02:03:55 +0000 (3 04:03 +0200)
committerAdrian Bunk <bunk@stusta.de>
Tue, 3 Apr 2007 02:03:55 +0000 (3 04:03 +0200)
tree51067f1b0f341dcebc79e5c17e88d45189e613ee
parentcceec5186fce242e095dc5e9496841df5d4133b9
[IFB]: Fix crash on input device removal

The input_device pointer is not refcounted, which means the device may
disappear while packets are queued, causing a crash when ifb passes packets
with a stale skb->dev pointer to netif_rx().

Fix by storing the interface index instead and do a lookup where neccessary.

Signed-off-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: Adrian Bunk <bunk@stusta.de>
drivers/net/ifb.c
include/linux/skbuff.h
include/net/pkt_cls.h
net/core/dev.c
net/core/skbuff.c
net/sched/act_mirred.c