vmac: fix for v2.6.36
author黄涛 <huangtao@rock-chips.com>
Mon, 1 Aug 2011 03:25:20 +0000 (11:25 +0800)
committer黄涛 <huangtao@rock-chips.com>
Mon, 1 Aug 2011 03:25:20 +0000 (11:25 +0800)
drivers/net/rk29_vmac.c

index 5f3c6e6c4e2531a9568c28044a8b42536134dccd..ea6f723bb7a2fe49818c88123dc7580c54660ba6 100755 (executable)
@@ -45,6 +45,7 @@
 #include <linux/slab.h>\r
 #include <linux/types.h>\r
 #include <linux/wakelock.h>\r
+#include <linux/version.h>\r
 \r
 #include <mach/iomux.h>\r
 #include <mach/gpio.h>\r
@@ -1275,7 +1276,7 @@ void vmac_tx_timeout(struct net_device *dev)
 static void create_multicast_filter(struct net_device *dev,\r
        unsigned long *bitmask)\r
 {\r
-#if 1\r
+#if (LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 34))\r
        struct netdev_hw_addr *ha;\r
        unsigned long crc;\r
        char *addrs;\r
@@ -1323,7 +1324,7 @@ static void create_multicast_filter(struct net_device *dev,
 }\r
 static void vmac_set_multicast_list(struct net_device *dev)\r
 {\r
-#if 1\r
+#if (LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 34))\r
        struct vmac_priv *ap = netdev_priv(dev);\r
        unsigned long flags, bitmask[2];\r
        int promisc, reg;\r