From mboxrd@z Thu Jan 1 00:00:00 1970 From: Hiroshi Shimamoto Subject: [PATCH] kni: compatibility with RHEL 7 Date: Thu, 12 Jun 2014 08:09:54 +0000 Message-ID: <7F861DC0615E0C47A872E6F3C5FCDDBD0110E674@BPXM14GP.gisp.nec.co.jp> Mime-Version: 1.0 Content-Type: text/plain; charset="iso-2022-jp" Content-Transfer-Encoding: quoted-printable Cc: Hayato Momma To: "dev-VfR2kkLFssw@public.gmane.org" Return-path: Content-Language: ja-JP 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" From: Hiroshi Shimamoto Compilation in RHEL7 is failed. This fixes the build issue. RHEL7 has skb_set_hash, the kernel version is 3.10 though. Don't define skb_set_hash for RHEL7. Signed-off-by: Hiroshi Shimamoto Reviewed-by: Hayato Momma --- lib/librte_eal/linuxapp/kni/ethtool/igb/kcompat.h | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/kcompat.h b/lib/librte= _eal/linuxapp/kni/ethtool/igb/kcompat.h index 4c27d5d..b4de6e2 100644 --- a/lib/librte_eal/linuxapp/kni/ethtool/igb/kcompat.h +++ b/lib/librte_eal/linuxapp/kni/ethtool/igb/kcompat.h @@ -3843,6 +3843,9 @@ static inline struct sk_buff *__kc__vlan_hwaccel_put_= tag(struct sk_buff *skb, #endif /* >=3D 3.10.0 */ =20 #if ( LINUX_VERSION_CODE < KERNEL_VERSION(3,14,0) ) + +#if (!(RHEL_RELEASE_CODE && RHEL_RELEASE_CODE >=3D RHEL_RELEASE_VERSION(7,= 0))) + #ifdef NETIF_F_RXHASH #define PKT_HASH_TYPE_L3 0 static inline void @@ -3851,6 +3854,8 @@ skb_set_hash(struct sk_buff *skb, __u32 hash, __alway= s_unused int type) skb->rxhash =3D hash; } #endif /* NETIF_F_RXHASH */ +#endif /* < RHEL7 */ + #endif /* < 3.14.0 */ =20 #endif /* _KCOMPAT_H_ */ --=20 1.9.1