Whamcloud - gitweb
b=14997
[fs/lustre-release.git] / lustre / autoconf / lustre-core.m4
index 727d1a9..a415368 100644 (file)
@@ -1114,6 +1114,27 @@ LB_LINUX_TRY_COMPILE([
 ])
 ])
 
+# RHEL5 PageChecked and SetPageChecked defined
+AC_DEFUN([LC_PAGE_CHECKED],
+[AC_MSG_CHECKING([kernel has PageChecked and SetPageChecked])
+LB_LINUX_TRY_COMPILE([
+        #include <linux/page-flags.h>
+],[
+        #ifndef PageChecked
+        #error PageChecked not defined in kernel
+        #endif
+        #ifndef SetPageChecked
+        #error SetPageChecked not defined in kernel
+        #endif
+],[
+        AC_MSG_RESULT(yes)
+        AC_DEFINE(HAVE_PAGE_CHECKED, 1,
+                  [does kernel have PageChecked and SetPageChecked])
+],[
+        AC_MSG_RESULT(NO)
+])
+])
+
 AC_DEFUN([LC_EXPORT_TRUNCATE_COMPLETE],
 [LB_CHECK_SYMBOL_EXPORT([truncate_complete_page],
 [mm/truncate.c],[
@@ -1141,6 +1162,24 @@ AC_DEFINE(HAVE___D_REHASH, 1,
 ])
 ])
 
+AC_DEFUN([LC_EXPORT_D_MOVE_LOCKED],
+[LB_CHECK_SYMBOL_EXPORT([d_move_locked],
+[fs/dcache.c],[
+AC_DEFINE(HAVE_D_MOVE_LOCKED, 1,
+            [d_move_locked is exported by the kernel])
+],[
+])
+])
+
+AC_DEFUN([LC_EXPORT___D_MOVE],
+[LB_CHECK_SYMBOL_EXPORT([__d_move],
+[fs/dcache.c],[
+AC_DEFINE(HAVE___D_MOVE, 1,
+            [__d_move is exported by the kernel])
+],[
+])
+])
+
 # The actual symbol exported varies among architectures, so we need
 # to check many symbols (but only in the current architecture.)  No
 # matter what symbol is exported, the kernel #defines node_to_cpumask
@@ -1304,8 +1343,10 @@ AC_DEFUN([LC_CONST_ACL_SIZE],
 tmp_flags="$CFLAGS"
 CFLAGS="$CFLAGS -I $LINUX/include $EXTRA_KCFLAGS"
 AC_TRY_RUN([
+#define __KERNEL__
 #include <linux/autoconf.h>
 #include <linux/types.h>
+#undef __KERNEL__
 // block include 
 #define __LINUX_POSIX_ACL_H
 
@@ -1366,6 +1407,8 @@ AC_DEFUN([LC_PROG_LINUX],
          LC_EXPORT_TRUNCATE_COMPLETE
          LC_EXPORT_D_REHASH_COND
          LC_EXPORT___D_REHASH
+         LC_EXPORT_D_MOVE_LOCKED
+         LC_EXPORT___D_MOVE
          LC_EXPORT_NODE_TO_CPUMASK
 
          LC_STRUCT_KIOBUF
@@ -1430,6 +1473,7 @@ AC_DEFUN([LC_PROG_LINUX],
 
          #2.6.18 + RHEL5 (fc6)
          LC_PG_FS_MISC
+         LC_PAGE_CHECKED
 
          # 2.6.19
          LC_INODE_BLKSIZE
@@ -1732,7 +1776,6 @@ lustre/include/Makefile
 lustre/include/lustre_ver.h
 lustre/include/linux/Makefile
 lustre/include/lustre/Makefile
-lustre/kernel_patches/targets/2.6-suse.target
 lustre/kernel_patches/targets/2.6-vanilla.target
 lustre/kernel_patches/targets/2.6-rhel4.target
 lustre/kernel_patches/targets/2.6-rhel5.target