compat: add dummy file kmemleak.h
authorHauke Mehrtens <hauke@hauke-m.de>
Sun, 22 Apr 2012 21:59:25 +0000 (23:59 +0200)
committerLuis R. Rodriguez <mcgrof@frijolero.org>
Mon, 23 Apr 2012 21:21:33 +0000 (14:21 -0700)
Some drivers are including kmemleak.h directly and this causes a build
problem on old kernel versions as it is not available on all.

mcgrof@tux ~/compat (git::master)$ ckmake
Trying kernel                  3.4.0-030400rc1-generic [OK]
Trying kernel                  3.3.0-030300rc2-generic [OK]
Trying kernel                     3.2.2-030202-generic [OK]
Trying kernel                    3.1.10-030110-generic [OK]
Trying kernel                    3.0.18-030018-generic [OK]
Trying kernel                  2.6.39-02063904-generic [OK]
Trying kernel                  2.6.38-02063808-generic [OK]
Trying kernel                  2.6.37-02063706-generic [OK]
Trying kernel                  2.6.36-02063604-generic [OK]
Trying kernel                  2.6.35-02063512-generic [OK]
Trying kernel                  2.6.34-02063410-generic [OK]
Trying kernel                  2.6.33-02063305-generic [OK]
Trying kernel                  2.6.32-02063255-generic [OK]
Trying kernel                  2.6.31-02063113-generic [OK]
Trying kernel                  2.6.30-02063010-generic [OK]
Trying kernel                  2.6.29-02062906-generic [OK]
Trying kernel                  2.6.28-02062810-generic [OK]
Trying kernel                    2.6.27-020627-generic [OK]
Trying kernel                    2.6.26-020626-generic [OK]
Trying kernel                    2.6.25-020625-generic [OK]
Trying kernel                    2.6.24-020624-generic [OK]

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
Signed-off-by: Luis R. Rodriguez <mcgrof@frijolero.org>
include/linux/kmemleak.h [new file with mode: 0644]

diff --git a/include/linux/kmemleak.h b/include/linux/kmemleak.h
new file mode 100644 (file)
index 0000000..83bd199
--- /dev/null
@@ -0,0 +1,5 @@
+#include <linux/version.h>
+
+#if (LINUX_VERSION_CODE > KERNEL_VERSION(2,6,30))
+#include_next <linux/kmemleak.h>
+#endif /* (LINUX_VERSION_CODE > KERNEL_VERSION(2,6,25)) */