Add empty definitions for the sparse checker annotations (__user,
__kernel, __safe, ...) defined by the kernel. This will allow these
annotations to be used in files common to kernel modules and libcfs.
Signed-off-by: John L. Hammond <john.hammond@intel.com>
Change-Id: I26a7d3fad0bc07535db4dfaa25e40bb10ff4e951
Reviewed-on: http://review.whamcloud.com/6969
Tested-by: Hudson
Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Sebastien Buisson <sebastien.buisson@bull.net>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
typedef unsigned long ulong_ptr_t;
typedef long long_ptr_t;
+/* Sparse annotations, copied from linux/compiler.h. */
+#define __user
+#define __kernel
+#define __safe
+#define __force
+#define __nocast
+#define __iomem
+#define __chk_user_ptr(x) ((void)0)
+#define __chk_io_ptr(x) ((void)0)
+#define __builtin_warning(x, y...) (1)
+#define __acquires(x)
+#define __releases(x)
+#define __acquire(x) ((void)0)
+#define __release(x) ((void)0)
+#define __cond_lock(x, c) (c)
+
#endif