datapath: Provide compatibility code for SET_ETHTOOL_OPS constness.
[sliver-openvswitch.git] / datapath / linux-2.6 / compat-2.6 / include / linux / netdevice.h
index e8988c9..ac1ff82 100644 (file)
@@ -110,4 +110,10 @@ static inline void netdev_rx_handler_unregister(struct net_device *dev)
 }
 #endif
 
+#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,19)
+#undef SET_ETHTOOL_OPS
+#define SET_ETHTOOL_OPS(netdev, ops) \
+       ( (netdev)->ethtool_ops = (struct ethtool_ops *)(ops) )
+#endif
+
 #endif