* [dpdk-dev] [PATCH] kni: bug fix in module_init and module_exit
@ 2016-08-25 11:45 郭鹏飞
2016-08-25 16:19 ` Ferruh Yigit
0 siblings, 1 reply; 2+ messages in thread
From: 郭鹏飞 @ 2016-08-25 11:45 UTC (permalink / raw)
To: dev
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain; charset=GBK, Size: 1796 bytes --]
From 932e33f33cf2a19ac5fa4295535b6b0e20c61890 Mon Sep 17 00:00:00 2001
From: Vincent Guo <guopengfei160@163.com>
Date: Thu, 25 Aug 2016 17:50:10 +0800
Subject: [PATCH] kni: bug fix in module_init and module_exit
unregister_XXX should be called when module exits or error occurs
during module init, but register_XXX is called in case that
HAVE_SIMPLIFIED_PERNET_OPERATIONS is not set.
---
lib/librte_eal/linuxapp/kni/kni_misc.c | 4 ++--
1 files 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 67e9b7d..d7850be 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");
}
--
1.7.1\x16º&¦fV¢çaj×(8n\x02è6ç]ùãM6Ó^zÛ«ö¶)Z·
«\¢d^qè¯y×ë¢i±Ö·
«\¢i±Ö·
«\¢m´÷]ö×Íöñ¼¥Ù(®\x03è²×âÇ\bDLø\b\x1e\x05×|õú+uëÝ¥Ù(®\x04á»n@º\r´×wç4ûM´Ð!\x12M\x17z+Þuúè)í\x1d={fj)i®bÚaÇjÞv\x16r¢Ù±Óا¶f¢èv)í¦\x1cvçaj×(]9×]¶ºÈ§2Ò¿]°Ø\^¬@\x1cDR\0\x01\x12Û\bÄ\x03\x7f8Û¿ÛÛ\r¡Ébz{\z»b~'\x1aµêު笵ç[Êluçaj×(ú,µø±Â+a\x11#\x13=(ß6ã]ÃÓ´á»n@º\r´×uç4ûM4ÑDÂEç\x1e÷~º&²n)(¶)ZÉ"j)Þà¾õï_yjk6çaj×(]7ë½}å¼¢Ù±Óا¶f¢èv)í¦\x1cvçaj×(Íxãÿ5ã"¶\x11\x1213âvîÏ\x06¼\x1c¿Mv×~\x13í¹\x02è6Ó^´ïù÷N4Ñ:\x05zºî
×Þ®»¡Ê("¶)ízW(§«zqèr\x19G«zxhr\x19X ×2mêÜ¢g^½Ú]àEçÞéÜzÀ&ÒCÃ8rIÃ
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [dpdk-dev] [PATCH] kni: bug fix in module_init and module_exit
2016-08-25 11:45 [dpdk-dev] [PATCH] kni: bug fix in module_init and module_exit 郭鹏飞
@ 2016-08-25 16:19 ` Ferruh Yigit
0 siblings, 0 replies; 2+ messages in thread
From: Ferruh Yigit @ 2016-08-25 16:19 UTC (permalink / raw)
To: 郭鹏飞, dev
Hi Vincent,
On 8/25/2016 12:45 PM, 郭鹏飞 wrote:
> From 932e33f33cf2a19ac5fa4295535b6b0e20c61890 Mon Sep 17 00:00:00 2001
> From: Vincent Guo <guopengfei160@163.com>
> Date: Thu, 25 Aug 2016 17:50:10 +0800
> Subject: [PATCH] kni: bug fix in module_init and module_exit
> unregister_XXX should be called when module exits or error occurs
> during module init, but register_XXX is called in case that
> HAVE_SIMPLIFIED_PERNET_OPERATIONS is not set.
>
Patch content is good, thanks for the fix, but patch doesn't apply
cleanly (leading spaces are missing)
Also in commit log, Signed-off-by and Fixes tags are missing.
And commit log can be simpler, something like:
"Fix pernet calls when HAVE_SIMPLIFIED_PERNET_OPERATIONS is not set."
Would you mind sending a new version of the patch?
Thanks,
ferruh
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2016-08-25 16:19 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-08-25 11:45 [dpdk-dev] [PATCH] kni: bug fix in module_init and module_exit 郭鹏飞
2016-08-25 16:19 ` Ferruh Yigit
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).