From 52913246e0056c9c6215a778a3b31b6b9ce5c3ef Mon Sep 17 00:00:00 2001 From: Rami Rosen Date: Thu, 31 Jan 2008 16:56:03 -0800 Subject: [MACVLAN]: Setting macvlan_handle_frame_hook to NULL when rtnl_link_register() fails. In drivers/net/macvlan.c, when rtnl_link_register() fails in macvlan_init_module(), there is no point to set it (second time in this method) to macvlan_handle_frame; macvlan_init_module() will return a negative number, so instead this patch sets macvlan_handle_frame_hook to NULL. Signed-off-by: Rami Rosen Acked-by: Patrick McHardy Signed-off-by: David S. Miller --- drivers/net/macvlan.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'drivers/net/macvlan.c') diff --git a/drivers/net/macvlan.c b/drivers/net/macvlan.c index 6ef6b8b39e71..f651a816b280 100644 --- a/drivers/net/macvlan.c +++ b/drivers/net/macvlan.c @@ -508,7 +508,7 @@ static int __init macvlan_init_module(void) goto err1; return 0; err1: - macvlan_handle_frame_hook = macvlan_handle_frame; + macvlan_handle_frame_hook = NULL; unregister_netdevice_notifier(&macvlan_notifier_block); return err; } -- cgit v1.2.3