From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-pd0-f182.google.com (mail-pd0-f182.google.com [209.85.192.182]) by dpdk.org (Postfix) with ESMTP id 1F42658F8 for ; Wed, 5 Mar 2014 16:59:27 +0100 (CET) Received: by mail-pd0-f182.google.com with SMTP id g10so1200860pdj.41 for ; Wed, 05 Mar 2014 08:00:55 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type; bh=34mnH57jltJr7ABo7ffdgdXQ30RPq+NQUmKUS1GxVUk=; b=Lc81oL7lvkQc7DcHovDWOPF5ton0W0+fZutELi9kw971Tk0Ll3WoU6Rix1ML4DzZ+t F6HTsVqDOL1gR1eohj+VIORYKEmnZFvYNGpVq412uruMTyrNx1DJDNHfFH3P7QWJFFoj XNVgwqUQParmNKfb3DFlMo3+0c/i6pOo65goLgZ9yHfQcw7vNC7Ycs+1Ly+LBMmbHGDr bzZqUQlLdn49WRV6/jtVrXVCMUa5onsonsQJw5x3AAHP5feERmOd91QupC8+YczEsRdJ AKBYfvQpYvXwxKW7HdO8IPJrtS6n6fOVTiS46aguv/ogm1M2g25LJ0RX+ouJigx0ofTy kG6Q== X-Gm-Message-State: ALoCoQmatIoKkT7Ln55NgUpLz19jmYsj4UJGSLXcUiVjFROPU6JI07LPmfnM5q1Y144rwBf+So6V MIME-Version: 1.0 X-Received: by 10.68.178.66 with SMTP id cw2mr7732119pbc.89.1394035255812; Wed, 05 Mar 2014 08:00:55 -0800 (PST) Received: by 10.68.14.65 with HTTP; Wed, 5 Mar 2014 08:00:55 -0800 (PST) In-Reply-To: <9cfac239bfe0489d901fe0158ff227ec@BLUPR05MB200.namprd05.prod.outlook.com> References: <9cfac239bfe0489d901fe0158ff227ec@BLUPR05MB200.namprd05.prod.outlook.com> Date: Wed, 5 Mar 2014 17:00:55 +0100 Message-ID: From: David Marchand To: Patrick McGleenon Content-Type: text/plain; charset=ISO-8859-1 X-Content-Filtered-By: Mailman/MimeDel 2.1.15 Cc: "dev@dpdk.org" Subject: Re: [dpdk-dev] kni: error building with kernel < 3.3 and ether_addr_equal backport X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Mar 2014 15:59:28 -0000 Hello Patrick, I encountered this problem as well, we are currently working on a fix. I have a few concerns, see below, but if you address them, feel free to contribute a new patch. On Wed, Mar 5, 2014 at 2:32 PM, Patrick McGleenon < Patrick.McGleenon@owmobility.com> wrote: > [..] > diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/kcompat.h > b/lib/librte_eal/linuxapp/kni/ethtool/igb/kcompat.h > index a404c9f..f6f6635 100644 > --- a/lib/librte_eal/linuxapp/kni/ethtool/igb/kcompat.h > +++ b/lib/librte_eal/linuxapp/kni/ethtool/igb/kcompat.h > @@ -3528,11 +3528,12 @@ extern void _kc_skb_add_rx_frag(struct sk_buff *, > int, struct page *, > > /*****************************************************************************/ > #if ( LINUX_VERSION_CODE < KERNEL_VERSION(3,5,0) ) > #define skb_tx_timestamp(skb) do {} while (0) > -static inline bool ether_addr_equal(const u8 *addr1, const u8 *addr2) > +static inline bool kni_ether_addr_equal(const u8 *addr1, const u8 *addr2) > { > return !compare_ether_addr(addr1, addr2); > } > #else > +typedef ether_addr_equal kni_ether_addr_equal; > #define HAVE_FDB_OPS > #define HAVE_ETHTOOL_GET_TS_INFO > #endif /* < 3.5.0 */ > I am not sure this typedef will work. Did you try to build on kernels >= 3.5 ? > diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/kcompat.h > b/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/kcompat.h > index 3fb6b14..45f6c4c 100644 > --- a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/kcompat.h > +++ b/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/kcompat.h > @@ -3107,11 +3107,12 @@ typedef netdev_features_t kni_netdev_features_t; > > > /*****************************************************************************/ > #if ( LINUX_VERSION_CODE < KERNEL_VERSION(3,5,0) ) > -static inline bool ether_addr_equal(const u8 *addr1, const u8 *addr2) > +static inline bool kni_ether_addr_equal(const u8 *addr1, const u8 *addr2) > { > return !compare_ether_addr(addr1, addr2); > } > #else > +typedef ether_addr_equal kni_ether_addr_equal; > #define HAVE_FDB_OPS > #endif /* < 3.5.0 */ > Same comment. Regards, -- David Marchand