DPDK patches and discussions
 help / color / mirror / Atom feed
From: 郭鹏飞 <guopengfei160@163.com>
To: dev@dpdk.org
Subject: [dpdk-dev] [PATCH] kni: bug fix in module_init and module_exit
Date: Thu, 25 Aug 2016 19:45:34 +0800 (CST)	[thread overview]
Message-ID: <69010abb.168e5.156c18501db.Coremail.guopengfei160@163.com> (raw)

[-- 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º&¦f­ŠV¢­çaj×(™8n\x02è6ç]ùãM6Ó^‘zÛ«œö­†™š¶)ZŠ·…«\¢d^qè¯y×ë¢i±Ö·…«\¢i±Ö·…«\¢m´÷]ö×Íöñ¼¥Ù(®\x03è²×âÇ\b­„DŒLø\b\x1e\x05מ|õú+uëÝ¥Ù(®\x04á»n@º\r´×­wç4ûM´Ð!\x12M\x17œz+Þuúèš)í›\x1d=Š{fj)i®‡bžÚaÇjÞv\x16­r‰¢žÙ±Óا¶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\x19šžG«zxhr\x19šžX †×2mêÜ¢g^½Ú]’ŠàEçÞ­éÜzÀ€&­ÒC“Ã8rIžÃ

             reply	other threads:[~2016-08-25 11:45 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-08-25 11:45 郭鹏飞 [this message]
2016-08-25 16:19 ` Ferruh Yigit

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=69010abb.168e5.156c18501db.Coremail.guopengfei160@163.com \
    --to=guopengfei160@163.com \
    --cc=dev@dpdk.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).