From mboxrd@z Thu Jan 1 00:00:00 1970 From: Stephen Hemminger Subject: Re: [PATCH] kni: fix build with kernel 4.8 Date: Thu, 8 Sep 2016 11:00:40 -0700 Message-ID: <20160908110040.32ec79f5@xeon-e3> References: <1473357296-10375-1-git-send-email-ferruh.yigit@intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Cc: dev@dpdk.org To: Ferruh Yigit Return-path: Received: from mail-pa0-f41.google.com (mail-pa0-f41.google.com [209.85.220.41]) by dpdk.org (Postfix) with ESMTP id 9250F68F8 for ; Thu, 8 Sep 2016 20:00:31 +0200 (CEST) Received: by mail-pa0-f41.google.com with SMTP id id6so19545200pad.3 for ; Thu, 08 Sep 2016 11:00:31 -0700 (PDT) In-Reply-To: <1473357296-10375-1-git-send-email-ferruh.yigit@intel.com> List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" On Thu, 8 Sep 2016 18:54:56 +0100 Ferruh Yigit wrote: > Linux kernel v4.8 removes macro DEFINE_PCI_DEVICE_TABLE > > Linux: 7e9321599011 ("treewide: remove references to the now unnecessary > DEFINE_PCI_DEVICE_TABLE") > > Added the macro to compatibility headers of the kni ethtool drivers. > > Signed-off-by: Ferruh Yigit > --- > lib/librte_eal/linuxapp/kni/ethtool/igb/kcompat.h | 7 +++++++ > lib/librte_eal/linuxapp/kni/ethtool/ixgbe/kcompat.h | 6 ++++++ > 2 files changed, 13 insertions(+) > > diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/kcompat.h b/lib/librte_eal/linuxapp/kni/ethtool/igb/kcompat.h > index bdd0806..9560aae 100644 > --- a/lib/librte_eal/linuxapp/kni/ethtool/igb/kcompat.h > +++ b/lib/librte_eal/linuxapp/kni/ethtool/igb/kcompat.h > @@ -3915,4 +3915,11 @@ skb_set_hash(struct sk_buff *skb, __u32 hash, __always_unused int type) > /* ndo_bridge_getlink adds new filter_mask and vlan_fill parameters */ > #define HAVE_NDO_BRIDGE_GETLINK_FILTER_MASK_VLAN_FILL > #endif /* >= 4.2.0 */ > + > +#if ( LINUX_VERSION_CODE >= KERNEL_VERSION(4,8,0) ) > +#ifndef DEFINE_PCI_DEVICE_TABLE > +#define DEFINE_PCI_DEVICE_TABLE(_table) const struct pci_device_id _table[] > +#endif /* DEFINE_PCI_DEVICE_TABLE */ > +#endif /* >= 4.8.0 */ > + Good to see the KNI driver staying up to date with upstream. Please just remove use of DEFINE_PCI_DEVICE_TABLE rather than resurrecting it!