From mboxrd@z Thu Jan 1 00:00:00 1970 From: Thomas Monjalon Subject: Re: [PATCH] kni: fix compile errors on Oracle Linux6.4 and RHEL6.5 Date: Tue, 10 Jun 2014 12:02:43 +0200 Message-ID: <3962139.NISuUL0v1x@xps13> References: <1402303135-28248-1-git-send-email-helin.zhang@intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7Bit Cc: dev-VfR2kkLFssw@public.gmane.org To: Helin Zhang Return-path: In-Reply-To: <1402303135-28248-1-git-send-email-helin.zhang-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org> List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces-VfR2kkLFssw@public.gmane.org Sender: "dev" Hi Helin, 2014-06-09 16:38, Helin Zhang: > #if ( LINUX_VERSION_CODE < KERNEL_VERSION(3,5,0) ) > #define skb_tx_timestamp(skb) do {} while (0) > -#if !(RHEL_RELEASE_CODE && RHEL_RELEASE_CODE >= RHEL_RELEASE_VERSION(6,4)) > -static inline bool ether_addr_equal(const u8 *addr1, const u8 *addr2) > +#ifndef ether_addr_equal It should be always true as it is a function (not known by the preprocessor). > +static inline bool __kc_ether_addr_equal(const u8 *addr1, const u8 *addr2) > { > return !compare_ether_addr(addr1, addr2); > } > -#endif > +#define ether_addr_equal(_addr1, _addr2) __kc_ether_addr_equal((_addr1),(_addr2)) > +#endif /* __kc_ether_addr_equal*/ So it is always replacing ether_addr_equal() by a kcompat equivalent for old kernels, even if ether_addr_equal() is already defined as a C function. Just to confirm: is it really what we want? [...] > -#endif > +#define ethtool_adv_to_mmd_eee_adv_t(adv) \ > +__kc_ethtool_adv_to_mmd_eee_adv_t(adv) An indentation is missing here. > +#endif /* ethtool_adv_to_mmd_eee_adv_t */ > +#endif /* */ Why an empty comment? Thanks -- Thomas