From: HELIN ZHANG <helin.zhang@intel.com>
To: dev@dpdk.org
Subject: [dpdk-dev] [PATCH] kni: bug fix of compiling KNI kernel module on Linux kernel 3.6.10
Date: Sun, 18 May 2014 22:14:18 +0800 [thread overview]
Message-ID: <1400422458-16322-1-git-send-email-helin.zhang@intel.com> (raw)
Error of "implicit-function-declaration" can be seen when building
KNI kernel module on Linux kernel 3.6.10 platform.
The root cause is as follows.
On Linux kernel 3.6.10, ETHTOOL_GEEE is defined in Linux header file
of "linux/ethtool.h", while is not defined in most of other
linux kernel versions.
mmd_eee_cap_to_ethtool_sup_t(), mmd_eee_adv_to_ethtool_adv_t() and
ethtool_adv_to_mmd_eee_adv_t() in kcompat.h are disabled by
"#if !defined(ETHTOOL_GEEE) || (RHEL_RELEASE_CODE && RHEL_RELEASE_CODE
<= RHEL_RELEASE_VERSION(6,4))", while are called in igb_get_eee()
in igb_ethtool.c which is enabled by "#ifdef ETHTOOL_GEEE".
This patch is to fix the compile issue.
Signed-off-by: HELIN ZHANG <helin.zhang@intel.com>
---
lib/librte_eal/linuxapp/kni/ethtool/igb/kcompat.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/kcompat.h b/lib/librte_eal/linuxapp/kni/ethtool/igb/kcompat.h
index 19df483..54c2ac5 100644
--- a/lib/librte_eal/linuxapp/kni/ethtool/igb/kcompat.h
+++ b/lib/librte_eal/linuxapp/kni/ethtool/igb/kcompat.h
@@ -3586,7 +3586,7 @@ static inline bool ether_addr_equal(const u8 *addr1, const u8 *addr2)
#define ADVERTISED_40000baseLR4_Full (1 << 26)
#endif
-#if !defined(ETHTOOL_GEEE) || (RHEL_RELEASE_CODE && RHEL_RELEASE_CODE <= RHEL_RELEASE_VERSION(6,4))
+#if defined(ETHTOOL_GEEE) || (RHEL_RELEASE_CODE && RHEL_RELEASE_CODE <= RHEL_RELEASE_VERSION(6,4))
/**
* mmd_eee_cap_to_ethtool_sup_t
* @eee_cap: value of the MMD EEE Capability register
--
1.8.1.4
next reply other threads:[~2014-05-18 14:14 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-05-18 14:14 HELIN ZHANG [this message]
2014-05-20 9:16 ` Thomas Monjalon
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=1400422458-16322-1-git-send-email-helin.zhang@intel.com \
--to=helin.zhang@intel.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).