RHEL7 backported nf_hookfn from newer kernel. Handle compatibility
by checking nf_hookfn declaration.
Signed-off-by: Pravin B Shelar <pshelar@nicira.com>
Acked-by: Jesse Gross <jesse@nicira.com>
OVS_GREP_IFELSE([$KSRC/include/linux/netdevice.h], [can_checksum_protocol])
OVS_GREP_IFELSE([$KSRC/include/linux/netdevice.h], [netdev_features_t])
OVS_GREP_IFELSE([$KSRC/include/linux/netdevice.h], [pcpu_sw_netstats])
+ OVS_GREP_IFELSE([$KSRC/include/linux/netfilter.h], [nf_hookfn.*nf_hook_ops],
+ [OVS_DEFINE([HAVE_NF_HOOKFN_ARG_OPS])])
OVS_GREP_IFELSE([$KSRC/include/linux/random.h], [prandom_u32])
schedule_clean_percpu();
}
-#if LINUX_VERSION_CODE >= KERNEL_VERSION(3,13,0)
+#ifdef HAVE_NF_HOOKFN_ARG_OPS
#define FIRST_PARAM const struct nf_hook_ops *ops,
#else
#define FIRST_PARAM unsigned int hooknum,