]> Gitweb @ Texas Instruments - Open Source Git Repositories - git.TI.com/gitweb - wilink8-wlan/compat.git/commitdiff
compat: add support for kernel 2.6.39
authorHauke Mehrtens <hauke@hauke-m.de>
Thu, 31 Mar 2011 16:21:33 +0000 (09:21 -0700)
committerLuis R. Rodriguez <lrodriguez@atheros.com>
Thu, 31 Mar 2011 19:15:41 +0000 (12:15 -0700)
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
include/linux/compat-2.6.39.h
include/linux/compat-2.6.40.h [new file with mode: 0644]
include/linux/compat-2.6.h

index bf4442bf63902a82f1670bad08c45fb3cdf1b35b..2c62d90e89a4b5721d8d8b9b8b2fb23ebea6984f 100644 (file)
@@ -8,23 +8,6 @@
 #include <linux/tty.h>
 #include <linux/irq.h>
 
-/*
- * This is not part of The 2.6.37 kernel yet but we
- * we use it to optimize the backport code we
- * need to implement. Instead of using ifdefs
- * to check what version of the check we use
- * we just replace all checks on current code
- * with this. I'll submit this upstream too, that
- * way all we'd have to do is to implement this
- * for older kernels, then we would not have to
- * edit the upstrema code for backport efforts.
- */
-#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,36))
-#define br_port_exists(dev)    (dev->priv_flags & IFF_BRIDGE_PORT)
-#else
-#define br_port_exists(dev)    (dev->br_port)
-#endif
-
 #define tiocmget(tty) tiocmget(tty, NULL)
 #define tiocmset(tty, set, clear) tiocmset(tty, NULL, set, clear)
 
diff --git a/include/linux/compat-2.6.40.h b/include/linux/compat-2.6.40.h
new file mode 100644 (file)
index 0000000..42f9fee
--- /dev/null
@@ -0,0 +1,27 @@
+#ifndef LINUX_26_40_COMPAT_H
+#define LINUX_26_40_COMPAT_H
+
+#include <linux/version.h>
+
+#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,40))
+
+/*
+ * This is not part of The 2.6.37 kernel yet but we
+ * we use it to optimize the backport code we
+ * need to implement. Instead of using ifdefs
+ * to check what version of the check we use
+ * we just replace all checks on current code
+ * with this. I'll submit this upstream too, that
+ * way all we'd have to do is to implement this
+ * for older kernels, then we would not have to
+ * edit the upstrema code for backport efforts.
+ */
+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,36))
+#define br_port_exists(dev)    (dev->priv_flags & IFF_BRIDGE_PORT)
+#else
+#define br_port_exists(dev)    (dev->br_port)
+#endif
+
+#endif /* (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,40)) */
+
+#endif /* LINUX_26_40_COMPAT_H */
index 478f833c5751dc41fd0a68a9e9f7982de2754372..8e45fc06a6e78a78bb7044c1fd16c333c1f0fe3a 100644 (file)
@@ -32,5 +32,6 @@
 #include <linux/compat-2.6.37.h>
 #include <linux/compat-2.6.38.h>
 #include <linux/compat-2.6.39.h>
+#include <linux/compat-2.6.40.h>
 
 #endif /* LINUX_26_COMPAT_H */