Skip to content

Commit

Permalink
Update skb_get_rxhash to handle rhel70
Browse files Browse the repository at this point in the history
Change-Id: Ibc2188bafd5001cbadd017ca9d5bfd5c146e9baf
  • Loading branch information
npchandran committed Mar 12, 2015
1 parent 499e1a1 commit 041192c
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
5 changes: 3 additions & 2 deletions include/vr_compat.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,9 @@ typedef u64 netdev_features_t;
*
* #define skb_get_rxhash skb_get_hash
*/
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(3,13,11)) && \
!(defined(skb_get_rxhash))
#if (((LINUX_VERSION_CODE >= KERNEL_VERSION(3,13,11)) && \
!(defined(skb_get_rxhash))) || \
(defined(RHEL_MAJOR) && (RHEL_MAJOR >= 7)))
static inline __u32
skb_get_rxhash(struct sk_buff *skb)
{
Expand Down
3 changes: 2 additions & 1 deletion linux/vr_genetlink.c
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,8 @@ vr_genetlink_init(void)
if (ret)
return ret;

#if (LINUX_VERSION_CODE < KERNEL_VERSION(3,13,0))
#if ((LINUX_VERSION_CODE < KERNEL_VERSION(3,13,0)) && \
(!(defined(RHEL_MAJOR) && (RHEL_MAJOR >= 7))))
return genl_register_family_with_ops(&vrouter_genl_family, vrouter_genl_ops,
ARRAY_SIZE(vrouter_genl_ops));
#else
Expand Down

0 comments on commit 041192c

Please sign in to comment.