Patrick McHardy 7312096454 macvlan: Fix memleak on device removal/crash on module removal
As noticed by Ben Greear, macvlan crashes the kernel when unloading the
module. The reason is that it tries to clean up the macvlan_port pointer
on the macvlan device itself instead of the underlying device. A non-NULL
pointer is taken as indication that the macvlan_handle_frame_hook is
valid, when receiving the next packet on the underlying device it tries
to call the NULL hook and crashes.

Clean up the macvlan_port on the correct device to fix this.

Signed-off-by; Patrick McHardy <kaber@trash.net>
Tested-by: Ben Greear <greearb@candelatech.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2008-05-08 01:13:31 -07:00
..
2008-04-30 23:15:34 +02:00
2008-04-29 08:06:27 -07:00
2008-04-29 13:46:54 -07:00
2008-04-30 08:29:47 -07:00
2008-04-30 08:29:47 -07:00
2008-04-29 08:06:18 -07:00
2008-04-30 08:29:47 -07:00
2008-04-30 08:29:52 -07:00
2008-04-30 08:29:52 -07:00