bonding: register slave pointer for rx_handler
authorJiri Pirko <jpirko@redhat.com>
Sat, 12 Mar 2011 03:14:35 +0000 (03:14 +0000)
committerDavid S. Miller <davem@davemloft.net>
Wed, 16 Mar 2011 19:51:19 +0000 (12:51 -0700)
commitf1c1775ac7e61950225925c949045406ffcb43de
treedff2fc348c566df3c18f023043fd308bb75662f7
parentc888385a0d61c4c6923ecc3b9dacfe8a1d8cb222
bonding: register slave pointer for rx_handler

Register slave pointer as rx_handler data. That would eventually prevent
need to loop over slave devices to find the right slave.

Use synchronize_net to ensure that bond_handle_frame does not get slave
structure freed when working with that.

Signed-off-by: Jiri Pirko <jpirko@redhat.com>
Reviewed-by: Nicolas de Pesloüan <nicolas.2p.debian@free.fr>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/bonding/bond_main.c
drivers/net/bonding/bonding.h