From: Hauke Mehrtens Date: Mon, 18 Feb 2013 21:37:36 +0000 (+0100) Subject: compat: deactivate netdev_set_default_ethtool_ops() for some 3.7 kernels X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=4971ae5e2075a284ff36a68cab7c3f407a852801;p=openwrt%2Fstaging%2Fblogic.git compat: deactivate netdev_set_default_ethtool_ops() for some 3.7 kernels netdev_set_default_ethtool_ops() was backported in 3.7.8 and compat should not ship it on any more recent versions any more. Signed-off-by: Hauke Mehrtens --- diff --git a/compat/compat-3.8.c b/compat/compat-3.8.c index b3d399c0aab9..8134323453ac 100644 --- a/compat/compat-3.8.c +++ b/compat/compat-3.8.c @@ -18,6 +18,7 @@ #include "hid-ids.h" #include +#if (LINUX_VERSION_CODE < KERNEL_VERSION(3,7,8)) void netdev_set_default_ethtool_ops(struct net_device *dev, const struct ethtool_ops *ops) { @@ -25,6 +26,7 @@ void netdev_set_default_ethtool_ops(struct net_device *dev, dev->ethtool_ops = ops; } EXPORT_SYMBOL_GPL(netdev_set_default_ethtool_ops); +#endif /* a list of devices that shouldn't be handled by HID core at all */ static const struct hid_device_id hid_ignore_list[] = { diff --git a/include/linux/compat-3.8.h b/include/linux/compat-3.8.h index 545e9f04f6ea..4aeffdba6408 100644 --- a/include/linux/compat-3.8.h +++ b/include/linux/compat-3.8.h @@ -9,8 +9,10 @@ #include #include +#if (LINUX_VERSION_CODE < KERNEL_VERSION(3,7,8)) extern void netdev_set_default_ethtool_ops(struct net_device *dev, const struct ethtool_ops *ops); +#endif #define HID_BUS_ANY 0xffff #define HID_GROUP_ANY 0x0000