From 6914c3b844195875c351d2c36685a84715f1e659 Mon Sep 17 00:00:00 2001 From: Vincent Guo Date: Fri, 2 Sep 2016 18:23:13 +0800 Subject: [PATCH] kni: fix module init/exit Fix pernet calls when HAVE_SIMPLIFIED_PERNET_OPERATIONS is not set. Fixes: e6734d21b4e1 ("kni: fix build with kernel 2.6.32") Signed-off-by: Vincent Guo Acked-by Ferruh Yigit --- lib/librte_eal/linuxapp/kni/kni_misc.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/librte_eal/linuxapp/kni/kni_misc.c b/lib/librte_eal/linuxapp/kni/kni_misc.c index 4f0750797e..3501dc1bac 100644 --- a/lib/librte_eal/linuxapp/kni/kni_misc.c +++ b/lib/librte_eal/linuxapp/kni/kni_misc.c @@ -194,7 +194,7 @@ out: #ifdef HAVE_SIMPLIFIED_PERNET_OPERATIONS unregister_pernet_subsys(&kni_net_ops); #else - register_pernet_gen_subsys(&kni_net_id, &kni_net_ops); + unregister_pernet_gen_subsys(kni_net_id, &kni_net_ops); #endif return rc; } @@ -206,7 +206,7 @@ kni_exit(void) #ifdef HAVE_SIMPLIFIED_PERNET_OPERATIONS unregister_pernet_subsys(&kni_net_ops); #else - register_pernet_gen_subsys(&kni_net_id, &kni_net_ops); + unregister_pernet_gen_subsys(kni_net_id, &kni_net_ops); #endif KNI_PRINT("####### DPDK kni module unloaded #######\n"); } -- 2.20.1