An upcoming backport adds dev_get_stats() to a pre-2.6.29 Linux kernel, so we
have to check for the presence of an dev_get_stats() definition instead of for
the particular kernel version.
OVS_GREP_IFELSE([$KSRC26/include/linux/netdevice.h], [dev_disable_lro],
[OVS_DEFINE([HAVE_DEV_DISABLE_LRO])])
+ OVS_GREP_IFELSE([$KSRC26/include/linux/netdevice.h], [dev_get_stats],
+ [OVS_DEFINE([HAVE_DEV_GET_STATS])])
# Check for the proto_data_valid member in struct sk_buff. The [^@]
# is necessary because some versions of this header remove the
extern void dev_disable_lro(struct net_device *dev);
#endif
-#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,29)
+#ifndef HAVE_DEV_GET_STATS
static inline const struct net_device_stats *
dev_get_stats(struct net_device *dev)
{