[Pvfs2-cvs] commit by slang in pvfs2/maint/config: kernel.m4
CVS commit program
cvs at parl.clemson.edu
Sat Nov 24 13:49:18 EST 2007
Update of /projects/cvsroot/pvfs2/maint/config
In directory parlweb1:/tmp/cvs-serv30662/maint/config
Modified Files:
Tag: pvfs-2-7-branch
kernel.m4
Log Message:
allow kmod to build against kernel with rt patches
Index: kernel.m4
===================================================================
RCS file: /projects/cvsroot/pvfs2/maint/config/kernel.m4,v
diff -p -u -r1.46 -r1.46.2.1
--- kernel.m4 6 Nov 2007 16:29:52 -0000 1.46
+++ kernel.m4 24 Nov 2007 18:49:18 -0000 1.46.2.1
@@ -849,5 +849,44 @@ AC_DEFUN([AX_KERNEL_FEATURES],
AC_MSG_RESULT(no)
)
+ AC_MSG_CHECKING(if kernel address_space struct has a spin_lock field)
+ AC_TRY_COMPILE([
+ #define __KERNEL__
+ #include <linux/fs.h>
+ ], [
+ struct address_space as;
+ spin_lock(&as.page_lock);
+ ],
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_SPIN_LOCK_ADDR_SPACE_STRUCT, 1, [Define if kernel address_space struct has a spin_lock instead of rw_lock]),
+ AC_MSG_RESULT(no)
+ )
+
+ AC_MSG_CHECKING(if kernel address_space struct has a priv_lock field - from RT linux)
+ AC_TRY_COMPILE([
+ #define __KERNEL__
+ #include <linux/fs.h>
+ ], [
+ struct address_space as;
+ spin_lock(&as.priv_lock);
+ ],
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_RT_PRIV_LOCK_ADDR_SPACE_STRUCT, 1, [Define if kernel address_space struct has a spin_lock for private data instead of rw_lock -- used by RT linux]),
+ AC_MSG_RESULT(no)
+ )
+
+ AC_MSG_CHECKING(if kernel defines mapping_nrpages macro - from RT linux)
+ AC_TRY_COMPILE([
+ #define __KERNEL__
+ #include <linux/fs.h>
+ ], [
+ struct address_space idata;
+ int i = mapping_nrpages(&idata);
+ ],
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_MAPPING_NRPAGES_MACRO, 1, [Define if kernel defines mapping_nrpages macro -- defined by RT linux]),
+ AC_MSG_RESULT(no)
+ )
+
CFLAGS=$oldcflags
])
More information about the Pvfs2-cvs
mailing list