[Pkg-lustre-svn-commit] updated: [05472f4] First attempt to build 2.6.26er vanilla server with 1.8.2

Patrick Winnertz winnie at debian.org
Thu Mar 4 18:19:32 UTC 2010


The following commit has been merged in the master branch:
commit 05472f4ed5827e4de4403d588b7d2d2635f79819
Author: Patrick Winnertz <winnie at debian.org>
Date:   Thu Mar 4 14:53:28 2010 +0100

    First attempt to build 2.6.26er vanilla server with 1.8.2
    
    Signed-off-by: Patrick Winnertz <winnie at debian.org>

diff --git a/debian/patches/00list b/debian/patches/00list
index 5844aa0..6a96baa 100644
--- a/debian/patches/00list
+++ b/debian/patches/00list
@@ -27,6 +27,6 @@ fix-oot-builds.dpatch
 #lnet-missing-prototypes.dpatch
 fix_various_typecasts.dpatch
 #build-fixes-for_2.6.18_servers.dpatch
-autogen-run.dpatch
 no-strict-aliasing.dpatch
 fix_bashisms_for_dash.dpatch
+autogen-run.dpatch
diff --git a/debian/patches/autogen-run.dpatch b/debian/patches/autogen-run.dpatch
index b72d6a6..93f542c 100755
--- a/debian/patches/autogen-run.dpatch
+++ b/debian/patches/autogen-run.dpatch
@@ -1,12 +1,12 @@
 #! /bin/sh /usr/share/dpatch/dpatch-run
-## autogen-run.dpatch by Patrick Winnertz <winnie at debian.org>
+## autogen-run.dpatch by Patrick Winnertz
 ##
 ## All lines beginning with `## DP:' are a description of the patch.
-## DP: autogen.sh output on lenny, as unstable is broken currently
+## DP: result of autogen.sh on lenny, as it is broken on unstable currently
 
 @DPATCH@
 diff --git a/aclocal.m4 b/aclocal.m4
-index bf2b8cd..beb9062 100644
+index 83f968d..b90bfb7 100644
 --- a/aclocal.m4
 +++ b/aclocal.m4
 @@ -873,7 +873,7 @@ if test $target_cpu == "powerpc64"; then
@@ -140,6 +140,15 @@ index bf2b8cd..beb9062 100644
  # LS_CONFIGURE
  #
  # configure bits for lustre-snmp
+@@ -6705,7 +6599,7 @@ AC_CACHE_CHECK([dependency style of $depcc],
+        grep sub/conftest.${OBJEXT-o} sub/conftest.Po > /dev/null 2>&1 &&
+        ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
+       # icc doesn't choke on unknown options, it will just issue warnings
+-      # (even with -Werror -fno-strict-aliasing).  So we grep stderr for any message
++      # (even with -Werror).  So we grep stderr for any message
+       # that says an option was ignored.
+       if grep 'ignoring option' conftest.err >/dev/null 2>&1; then :; else
+         am_cv_$1_dependencies_compiler_type=$depmode
 diff --git a/autoMakefile.in b/autoMakefile.in
 index a7881f3..151f562 100644
 --- a/autoMakefile.in
@@ -311,7 +320,7 @@ index 980bc9f..dfce080 100644
  
  /* use tunable backoff TCP */
 diff --git a/configure b/configure
-index 55ca570..e62bec2 100755
+index 27faa3e..0dc9b73 100755
 --- a/configure
 +++ b/configure
 @@ -1,27 +1,56 @@
@@ -3862,6 +3871,15 @@ index 55ca570..e62bec2 100755
  if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then
    echo $ECHO_N "(cached) $ECHO_C" >&6
  else
+@@ -3025,7 +3682,7 @@ else
+        grep sub/conftest.${OBJEXT-o} sub/conftest.Po > /dev/null 2>&1 &&
+        ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
+       # icc doesn't choke on unknown options, it will just issue warnings
+-      # (even with -Werror -fno-strict-aliasing).  So we grep stderr for any message
++      # (even with -Werror).  So we grep stderr for any message
+       # that says an option was ignored.
+       if grep 'ignoring option' conftest.err >/dev/null 2>&1; then :; else
+         am_cv_CC_dependencies_compiler_type=$depmode
 @@ -3041,8 +3698,8 @@ else
  fi
  
@@ -5979,6 +5997,15 @@ index 55ca570..e62bec2 100755
  	rm -f build/conftest.i
  	cat >conftest.c <<_ACEOF
  /* confdefs.h.  */
+@@ -4937,7 +5748,7 @@ main (void)
+ _ACEOF
+ 
+ rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
+-if { ac_try='cp conftest.c build && make -d $makerule LUSTRE_KERNEL_TEST=conftest.i ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/`uname -m|sed -e 's/ppc.*/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/'`/include -I$LINUX/include -I$LINUX_OBJ/include -I$LINUX_OBJ/include2 -include include/linux/autoconf.h" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM $MODULE_TARGET=$PWD/build'
++if { ac_try='cp conftest.c build && make -d $makerule LUSTRE_KERNEL_TEST=conftest.i ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/`uname -m|sed -e 's/ppc.*/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/'`/include -I$LINUX/include -I$LINUX_OBJ/include -I$LINUX_OBJ/include2 -include include/linux/autoconf.h" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror -fno-strict-aliasing-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM $MODULE_TARGET=$PWD/build'
+   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+   (eval $ac_try) 2>&5
+   ac_status=$?
 @@ -4949,8 +5760,8 @@ if { ac_try='cp conftest.c build && make -d $makerule LUSTRE_KERNEL_TEST=conftes
    echo "$as_me:$LINENO: \$? = $ac_status" >&5
    (exit $ac_status); }; }; then
@@ -6480,10 +6507,10 @@ index 55ca570..e62bec2 100755
    enable_affinity='yes'
 -fi;
 +fi
-+
  
 -echo "$as_me:$LINENO: checking for CPU affinity support" >&5
 -echo $ECHO_N "checking for CPU affinity support... $ECHO_C" >&6
++
 +{ echo "$as_me:$LINENO: checking for CPU affinity support" >&5
 +echo $ECHO_N "checking for CPU affinity support... $ECHO_C" >&6; }
  if test x$enable_affinity = xno ; then
@@ -6611,12 +6638,12 @@ index 55ca570..e62bec2 100755
 -echo "$as_me:$LINENO: result: $QSNET" >&5
 -echo "${ECHO_T}$QSNET" >&6
 +fi
++
++{ echo "$as_me:$LINENO: result: $QSNET" >&5
++echo "${ECHO_T}$QSNET" >&6; }
  
 -echo "$as_me:$LINENO: checking if quadrics kernel headers are present" >&5
 -echo $ECHO_N "checking if quadrics kernel headers are present... $ECHO_C" >&6
-+{ echo "$as_me:$LINENO: result: $QSNET" >&5
-+echo "${ECHO_T}$QSNET" >&6; }
-+
 +{ echo "$as_me:$LINENO: checking if quadrics kernel headers are present" >&5
 +echo $ECHO_N "checking if quadrics kernel headers are present... $ECHO_C" >&6; }
  if test -d $QSNET/drivers/net/qsnet ; then
@@ -7601,7 +7628,7 @@ index 55ca570..e62bec2 100755
 +{ echo "$as_me:$LINENO: checking kernel __u64 is long long type" >&5
 +echo $ECHO_N "checking kernel __u64 is long long type... $ECHO_C" >&6; }
  tmp_flags="$EXTRA_KCFLAGS"
- EXTRA_KCFLAGS="$EXTRA_KCFLAGS -Werror"
+ EXTRA_KCFLAGS="$EXTRA_KCFLAGS -Werror -fno-strict-aliasing"
  cat >conftest.c <<_ACEOF
 @@ -7702,8 +8513,8 @@ if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f
    echo "$as_me:$LINENO: \$? = $ac_status" >&5
@@ -7632,7 +7659,7 @@ index 55ca570..e62bec2 100755
 +{ echo "$as_me:$LINENO: checking ssize_t is signed long type" >&5
 +echo $ECHO_N "checking ssize_t is signed long type... $ECHO_C" >&6; }
  tmp_flags="$CFLAGS"
- CFLAGS="$CFLAGS -Werror"
+ CFLAGS="$CFLAGS -Werror -fno-strict-aliasing"
  cat >conftest.$ac_ext <<_ACEOF
 @@ -7740,30 +8551,25 @@ cat >conftest.$ac_ext <<_ACEOF
  
@@ -7698,7 +7725,7 @@ index 55ca570..e62bec2 100755
 +{ echo "$as_me:$LINENO: checking size_t is unsigned long type" >&5
 +echo $ECHO_N "checking size_t is unsigned long type... $ECHO_C" >&6; }
  tmp_flags="$CFLAGS"
- CFLAGS="$CFLAGS -Werror"
+ CFLAGS="$CFLAGS -Werror -fno-strict-aliasing"
  cat >conftest.$ac_ext <<_ACEOF
 @@ -7800,30 +8607,25 @@ cat >conftest.$ac_ext <<_ACEOF
  
@@ -7987,7 +8014,7 @@ index 55ca570..e62bec2 100755
 +{ echo "$as_me:$LINENO: checking check kernel has struct kmem_cache" >&5
 +echo $ECHO_N "checking check kernel has struct kmem_cache... $ECHO_C" >&6; }
  tmp_flags="$EXTRA_KCFLAGS"
- EXTRA_KCFLAGS="-Werror"
+ EXTRA_KCFLAGS="-Werror -fno-strict-aliasing"
  cat >conftest.c <<_ACEOF
 @@ -8259,8 +9062,8 @@ if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f
    echo "$as_me:$LINENO: \$? = $ac_status" >&5
@@ -8190,9 +8217,10 @@ index 55ca570..e62bec2 100755
 +echo "${ECHO_T}yes" >&6; }
  
  	tmp_flags="$EXTRA_KCFLAGS"
- 	EXTRA_KCFLAGS="-Werror"
+-	EXTRA_KCFLAGS="-Werror"
 -	echo "$as_me:$LINENO: checking whether we can really use dump_trace" >&5
 -echo $ECHO_N "checking whether we can really use dump_trace... $ECHO_C" >&6
++	EXTRA_KCFLAGS="-Werror -fno-strict-aliasing"
 +	{ echo "$as_me:$LINENO: checking whether we can really use dump_trace" >&5
 +echo $ECHO_N "checking whether we can really use dump_trace... $ECHO_C" >&6; }
  	cat >conftest.c <<_ACEOF
@@ -8259,9 +8287,10 @@ index 55ca570..e62bec2 100755
 +echo "${ECHO_T}yes" >&6; }
  
  	tmp_flags="$EXTRA_KCFLAGS"
- 	EXTRA_KCFLAGS="-Werror"
+-	EXTRA_KCFLAGS="-Werror"
 -	echo "$as_me:$LINENO: checking whether we can really use dump_trace" >&5
 -echo $ECHO_N "checking whether we can really use dump_trace... $ECHO_C" >&6
++	EXTRA_KCFLAGS="-Werror -fno-strict-aliasing"
 +	{ echo "$as_me:$LINENO: checking whether we can really use dump_trace" >&5
 +echo $ECHO_N "checking whether we can really use dump_trace... $ECHO_C" >&6; }
  	cat >conftest.c <<_ACEOF
@@ -8392,7 +8421,7 @@ index 55ca570..e62bec2 100755
 +{ echo "$as_me:$LINENO: checking if kernel defines unshare_fs_struct()" >&5
 +echo $ECHO_N "checking if kernel defines unshare_fs_struct()... $ECHO_C" >&6; }
  tmp_flags="$EXTRA_KCFLAGS"
- EXTRA_KCFLAGS="-Werror"
+ EXTRA_KCFLAGS="-Werror -fno-strict-aliasing"
  cat >conftest.c <<_ACEOF
 @@ -8945,8 +9749,8 @@ if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f
    echo "$as_me:$LINENO: \$? = $ac_status" >&5
@@ -9941,7 +9970,7 @@ index 55ca570..e62bec2 100755
 +          { echo "$as_me:$LINENO: checking mapping->tree_lock is rw_lock" >&5
 +echo $ECHO_N "checking mapping->tree_lock is rw_lock... $ECHO_C" >&6; }
  tmp_flags="$EXTRA_KCFLAGS"
- EXTRA_KCFLAGS="-Werror"
+ EXTRA_KCFLAGS="-Werror -fno-strict-aliasing"
  cat >conftest.c <<_ACEOF
 @@ -11222,8 +12030,8 @@ if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f
    echo "$as_me:$LINENO: \$? = $ac_status" >&5
@@ -10286,7 +10315,7 @@ index 55ca570..e62bec2 100755
 +          { echo "$as_me:$LINENO: checking if umount_begin needs vfsmount parameter instead of super_block" >&5
 +echo $ECHO_N "checking if umount_begin needs vfsmount parameter instead of super_block... $ECHO_C" >&6; }
  tmp_flags="$EXTRA_KCFLAGS"
- EXTRA_KCFLAGS="-Werror"
+ EXTRA_KCFLAGS="-Werror -fno-strict-aliasing"
  cat >conftest.c <<_ACEOF
 @@ -11842,8 +12650,8 @@ if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f
    echo "$as_me:$LINENO: \$? = $ac_status" >&5
@@ -10611,7 +10640,7 @@ index 55ca570..e62bec2 100755
 +          { echo "$as_me:$LINENO: checking check vfs_readdir need 64bit inode number" >&5
 +echo $ECHO_N "checking check vfs_readdir need 64bit inode number... $ECHO_C" >&6; }
  tmp_flags="$EXTRA_KCFLAGS"
- EXTRA_KCFLAGS="-Werror"
+ EXTRA_KCFLAGS="-Werror -fno-strict-aliasing"
  cat >conftest.c <<_ACEOF
 @@ -12343,8 +13152,8 @@ if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f
    echo "$as_me:$LINENO: \$? = $ac_status" >&5
@@ -11029,7 +11058,7 @@ index 55ca570..e62bec2 100755
 +        { echo "$as_me:$LINENO: checking if kernel using gfp_t for shrinker second paramter" >&5
 +echo $ECHO_N "checking if kernel using gfp_t for shrinker second paramter... $ECHO_C" >&6; }
          tmp_flags="$EXTRA_KCFLAGS"
-         EXTRA_KCFLAGS="-Werror"
+         EXTRA_KCFLAGS="-Werror -fno-strict-aliasing"
          cat >conftest.c <<_ACEOF
 @@ -13068,8 +13878,8 @@ if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f
    echo "$as_me:$LINENO: \$? = $ac_status" >&5
@@ -11424,7 +11453,7 @@ index 55ca570..e62bec2 100755
 +          { echo "$as_me:$LINENO: checking mapping->tree_lock is rw_lock" >&5
 +echo $ECHO_N "checking mapping->tree_lock is rw_lock... $ECHO_C" >&6; }
  tmp_flags="$EXTRA_KCFLAGS"
- EXTRA_KCFLAGS="-Werror"
+ EXTRA_KCFLAGS="-Werror -fno-strict-aliasing"
  cat >conftest.c <<_ACEOF
 @@ -13756,8 +14567,8 @@ if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f
    echo "$as_me:$LINENO: \$? = $ac_status" >&5
@@ -11989,7 +12018,7 @@ index 55ca570..e62bec2 100755
 +{ echo "$as_me:$LINENO: checking userspace __u64 is long long type" >&5
 +echo $ECHO_N "checking userspace __u64 is long long type... $ECHO_C" >&6; }
  tmp_flags="$CFLAGS"
- CFLAGS="$CFLAGS -Werror"
+ CFLAGS="$CFLAGS -Werror -fno-strict-aliasing"
  cat >conftest.$ac_ext <<_ACEOF
 @@ -14647,30 +15364,25 @@ cat >conftest.$ac_ext <<_ACEOF
  
@@ -12357,9 +12386,9 @@ index 55ca570..e62bec2 100755
  
 -fi;
 +fi
-+
  
 -# Check whether --with-ldiskfs-inkernel or --without-ldiskfs-inkernel was given.
++
 +# Check whether --with-ldiskfs-inkernel was given.
  if test "${with_ldiskfs_inkernel+set}" = set; then
 -  withval="$with_ldiskfs_inkernel"
@@ -19051,9 +19080,18 @@ index 55ca570..e62bec2 100755
  fi
  
 diff --git a/ldiskfs/aclocal.m4 b/ldiskfs/aclocal.m4
-index 9df75ae..4f9666b 100644
+index f7e7052..fdec1e5 100644
 --- a/ldiskfs/aclocal.m4
 +++ b/ldiskfs/aclocal.m4
+@@ -596,7 +596,7 @@ AC_CACHE_CHECK([dependency style of $depcc],
+        grep sub/conftest.${OBJEXT-o} sub/conftest.Po > /dev/null 2>&1 &&
+        ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
+       # icc doesn't choke on unknown options, it will just issue warnings
+-      # (even with -Werror -fno-strict-aliasing).  So we grep stderr for any message
++      # (even with -Werror).  So we grep stderr for any message
+       # that says an option was ignored.
+       if grep 'ignoring option' conftest.err >/dev/null 2>&1; then :; else
+         am_cv_$1_dependencies_compiler_type=$depmode
 @@ -2420,110 +2420,3 @@ AS_IF([test AS_VAR_GET(ac_Header) = yes], [$2], [$3])[]dnl
  AS_VAR_POPDEF([ac_Header])dnl
  ])
@@ -19246,7 +19284,7 @@ index cc60100..dc9e4f2 100644
  
  /* Define to 1 if you have the ANSI C header files. */
 diff --git a/ldiskfs/configure b/ldiskfs/configure
-index 2ea4aab..5329615 100755
+index 91805b5..b1a94f9 100755
 --- a/ldiskfs/configure
 +++ b/ldiskfs/configure
 @@ -1,27 +1,56 @@
@@ -22633,6 +22671,15 @@ index 2ea4aab..5329615 100755
  if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then
    echo $ECHO_N "(cached) $ECHO_C" >&6
  else
+@@ -2882,7 +3405,7 @@ else
+        grep sub/conftest.${OBJEXT-o} sub/conftest.Po > /dev/null 2>&1 &&
+        ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
+       # icc doesn't choke on unknown options, it will just issue warnings
+-      # (even with -Werror -fno-strict-aliasing).  So we grep stderr for any message
++      # (even with -Werror).  So we grep stderr for any message
+       # that says an option was ignored.
+       if grep 'ignoring option' conftest.err >/dev/null 2>&1; then :; else
+         am_cv_CC_dependencies_compiler_type=$depmode
 @@ -2898,8 +3421,8 @@ else
  fi
  
@@ -24243,6 +24290,15 @@ index 2ea4aab..5329615 100755
  	rm -f build/conftest.i
  	cat >conftest.c <<_ACEOF
  /* confdefs.h.  */
+@@ -4318,7 +5002,7 @@ main (void)
+ _ACEOF
+ 
+ rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
+-if { ac_try='cp conftest.c build && make -d $makerule LUSTRE_KERNEL_TEST=conftest.i ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/`uname -m|sed -e 's/ppc.*/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/'`/include -I$LINUX/include -I$LINUX_OBJ/include -I$LINUX_OBJ/include2 -include include/linux/autoconf.h" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM $MODULE_TARGET=$PWD/build'
++if { ac_try='cp conftest.c build && make -d $makerule LUSTRE_KERNEL_TEST=conftest.i ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/`uname -m|sed -e 's/ppc.*/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/'`/include -I$LINUX/include -I$LINUX_OBJ/include -I$LINUX_OBJ/include2 -include include/linux/autoconf.h" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror -fno-strict-aliasing-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM $MODULE_TARGET=$PWD/build'
+   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+   (eval $ac_try) 2>&5
+   ac_status=$?
 @@ -4330,8 +5014,8 @@ if { ac_try='cp conftest.c build && make -d $makerule LUSTRE_KERNEL_TEST=conftes
    echo "$as_me:$LINENO: \$? = $ac_status" >&5
    (exit $ac_status); }; }; then
@@ -24860,7 +24916,7 @@ index 2ea4aab..5329615 100755
  case $LINUXRELEASE in
  2.6.5*) LDISKFS_SERIES="2.6-suse.series" ;;
  2.6.9*) LDISKFS_SERIES="2.6-rhel4.series" ;;
-@@ -5315,7 +6003,11 @@ case $LINUXRELEASE in
+@@ -5315,22 +6003,27 @@ case $LINUXRELEASE in
  		        LDISKFS_SERIES="2.6-rhel5.series"
                  fi
  	else
@@ -24872,7 +24928,8 @@ index 2ea4aab..5329615 100755
  	fi
  	;;
  2.6.22*) LDISKFS_SERIES="2.6.22-vanilla.series";;
-@@ -5323,14 +6015,14 @@ case $LINUXRELEASE in
++2.6.26*) LDISKFS_SERIES="2.6.26-vanilla.series";;
+ 2.6.27*) LDISKFS_SERIES="2.6-sles11.series";;
  *) { echo "$as_me:$LINENO: WARNING: Unknown kernel version $LINUXRELEASE, fix ldiskfs/configure.ac" >&5
  echo "$as_me: WARNING: Unknown kernel version $LINUXRELEASE, fix ldiskfs/configure.ac" >&2;}
  esac
@@ -24891,7 +24948,7 @@ index 2ea4aab..5329615 100755
  grep -q -E '[[:space:]]d_rehash_cond[[:space:]]' $LINUX/$SYMVERFILE 2>/dev/null
  rc=$?
  if test $rc -ne 0; then
-@@ -5344,12 +6036,12 @@ if test $rc -ne 0; then
+@@ -5344,12 +6037,12 @@ if test $rc -ne 0; then
  	fi
      done
      if test $export -eq 0; then
@@ -24908,7 +24965,7 @@ index 2ea4aab..5329615 100755
  
  cat >>confdefs.h <<\_ACEOF
  #define HAVE_D_REHASH_COND 1
-@@ -5357,8 +6049,8 @@ _ACEOF
+@@ -5357,8 +6050,8 @@ _ACEOF
  
      fi
  else
@@ -24919,7 +24976,7 @@ index 2ea4aab..5329615 100755
  
  cat >>confdefs.h <<\_ACEOF
  #define HAVE_D_REHASH_COND 1
-@@ -5367,8 +6059,8 @@ _ACEOF
+@@ -5367,8 +6060,8 @@ _ACEOF
  fi
  
  
@@ -24930,7 +24987,7 @@ index 2ea4aab..5329615 100755
  grep -q -E '[[:space:]]__d_rehash[[:space:]]' $LINUX/$SYMVERFILE 2>/dev/null
  rc=$?
  if test $rc -ne 0; then
-@@ -5382,12 +6074,12 @@ if test $rc -ne 0; then
+@@ -5382,12 +6075,12 @@ if test $rc -ne 0; then
  	fi
      done
      if test $export -eq 0; then
@@ -24947,7 +25004,7 @@ index 2ea4aab..5329615 100755
  
  cat >>confdefs.h <<\_ACEOF
  #define HAVE___D_REHASH 1
-@@ -5395,8 +6087,8 @@ _ACEOF
+@@ -5395,8 +6088,8 @@ _ACEOF
  
      fi
  else
@@ -24958,7 +25015,7 @@ index 2ea4aab..5329615 100755
  
  cat >>confdefs.h <<\_ACEOF
  #define HAVE___D_REHASH 1
-@@ -5405,8 +6097,8 @@ _ACEOF
+@@ -5405,8 +6098,8 @@ _ACEOF
  fi
  
  
@@ -24969,7 +25026,7 @@ index 2ea4aab..5329615 100755
  grep -q -E '[[:space:]]d_move_locked[[:space:]]' $LINUX/$SYMVERFILE 2>/dev/null
  rc=$?
  if test $rc -ne 0; then
-@@ -5420,12 +6112,12 @@ if test $rc -ne 0; then
+@@ -5420,12 +6113,12 @@ if test $rc -ne 0; then
  	fi
      done
      if test $export -eq 0; then
@@ -24986,7 +25043,7 @@ index 2ea4aab..5329615 100755
  
  cat >>confdefs.h <<\_ACEOF
  #define HAVE_D_MOVE_LOCKED 1
-@@ -5433,8 +6125,8 @@ _ACEOF
+@@ -5433,8 +6126,8 @@ _ACEOF
  
      fi
  else
@@ -24997,7 +25054,7 @@ index 2ea4aab..5329615 100755
  
  cat >>confdefs.h <<\_ACEOF
  #define HAVE_D_MOVE_LOCKED 1
-@@ -5443,8 +6135,8 @@ _ACEOF
+@@ -5443,8 +6136,8 @@ _ACEOF
  fi
  
  
@@ -25008,7 +25065,7 @@ index 2ea4aab..5329615 100755
  grep -q -E '[[:space:]]__d_move[[:space:]]' $LINUX/$SYMVERFILE 2>/dev/null
  rc=$?
  if test $rc -ne 0; then
-@@ -5458,12 +6150,12 @@ if test $rc -ne 0; then
+@@ -5458,12 +6151,12 @@ if test $rc -ne 0; then
  	fi
      done
      if test $export -eq 0; then
@@ -25025,7 +25082,7 @@ index 2ea4aab..5329615 100755
  
  cat >>confdefs.h <<\_ACEOF
  #define HAVE___D_MOVE 1
-@@ -5471,8 +6163,8 @@ _ACEOF
+@@ -5471,8 +6164,8 @@ _ACEOF
  
      fi
  else
@@ -25036,7 +25093,7 @@ index 2ea4aab..5329615 100755
  
  cat >>confdefs.h <<\_ACEOF
  #define HAVE___D_MOVE 1
-@@ -5482,10 +6174,10 @@ fi
+@@ -5482,10 +6175,10 @@ fi
  
  
  
@@ -25049,7 +25106,7 @@ index 2ea4aab..5329615 100755
  
  
  MOSTLYCLEANFILES='.*.cmd .*.flags *.o *.ko *.mod.c .depend .*.1.* Modules.symvers Module.symvers'
-@@ -5509,39 +6201,58 @@ _ACEOF
+@@ -5509,39 +6202,58 @@ _ACEOF
  
  # The following way of writing the cache mishandles newlines in values,
  # but we know of no workaround that is simple, portable, and efficient.
@@ -25124,7 +25181,7 @@ index 2ea4aab..5329615 100755
    fi
  fi
  rm -f confcache
-@@ -5550,32 +6261,18 @@ test "x$prefix" = xNONE && prefix=$ac_default_prefix
+@@ -5550,32 +6262,18 @@ test "x$prefix" = xNONE && prefix=$ac_default_prefix
  # Let make expand exec_prefix.
  test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
  
@@ -25163,7 +25220,7 @@ index 2ea4aab..5329615 100755
  done
  LIBOBJS=$ac_libobjs
  
-@@ -5662,17 +6359,45 @@ cat >>$CONFIG_STATUS <<\_ACEOF
+@@ -5662,17 +6360,45 @@ cat >>$CONFIG_STATUS <<\_ACEOF
  ## M4sh Initialization.  ##
  ## --------------------- ##
  
@@ -25213,7 +25270,7 @@ index 2ea4aab..5329615 100755
  
  # Support unset when possible.
  if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
-@@ -5682,8 +6407,43 @@ else
+@@ -5682,8 +6408,43 @@ else
  fi
  
  
@@ -25258,7 +25315,7 @@ index 2ea4aab..5329615 100755
  PS1='$ '
  PS2='> '
  PS4='+ '
-@@ -5697,18 +6457,19 @@ do
+@@ -5697,18 +6458,19 @@ do
    if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
      eval $as_var=C; export $as_var
    else
@@ -25281,7 +25338,7 @@ index 2ea4aab..5329615 100755
    as_basename=basename
  else
    as_basename=false
-@@ -5716,159 +6477,120 @@ fi
+@@ -5716,159 +6478,120 @@ fi
  
  
  # Name of the executable.
@@ -25512,7 +25569,7 @@ index 2ea4aab..5329615 100755
  
  if mkdir -p . 2>/dev/null; then
    as_mkdir_p=:
-@@ -5877,7 +6599,28 @@ else
+@@ -5877,7 +6600,28 @@ else
    as_mkdir_p=false
  fi
  
@@ -25542,7 +25599,7 @@ index 2ea4aab..5329615 100755
  
  # Sed expression to map a string onto a valid CPP name.
  as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
-@@ -5886,31 +6629,14 @@ as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
+@@ -5886,31 +6630,14 @@ as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
  as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
  
  
@@ -25578,7 +25635,7 @@ index 2ea4aab..5329615 100755
  
    CONFIG_FILES    = $CONFIG_FILES
    CONFIG_HEADERS  = $CONFIG_HEADERS
-@@ -5918,30 +6644,20 @@ generated by GNU Autoconf 2.59.  Invocation command line was
+@@ -5918,30 +6645,20 @@ generated by GNU Autoconf 2.59.  Invocation command line was
    CONFIG_COMMANDS = $CONFIG_COMMANDS
    $ $0 $@
  
@@ -25617,7 +25674,7 @@ index 2ea4aab..5329615 100755
  ac_cs_usage="\
  \`$as_me' instantiates files from templates according to the
  current configuration.
-@@ -5949,7 +6665,7 @@ current configuration.
+@@ -5949,7 +6666,7 @@ current configuration.
  Usage: $0 [OPTIONS] [FILE]...
  
    -h, --help       print this help, then exit
@@ -25626,7 +25683,7 @@ index 2ea4aab..5329615 100755
    -q, --quiet      do not print progress messages
    -d, --debug      don't remove temporary files
        --recheck    update $as_me by reconfiguring in the same conditions
-@@ -5968,19 +6684,21 @@ Configuration commands:
+@@ -5968,19 +6685,21 @@ Configuration commands:
  $config_commands
  
  Report bugs to <bug-autoconf at gnu.org>."
@@ -25654,7 +25711,7 @@ index 2ea4aab..5329615 100755
  _ACEOF
  
  cat >>$CONFIG_STATUS <<\_ACEOF
-@@ -5991,39 +6709,24 @@ while test $# != 0
+@@ -5991,39 +6710,24 @@ while test $# != 0
  do
    case $1 in
    --*=*)
@@ -25700,7 +25757,7 @@ index 2ea4aab..5329615 100755
      debug=: ;;
    --file | --fil | --fi | --f )
      $ac_shift
-@@ -6033,18 +6736,24 @@ Try \`$0 --help' for more information." >&2;}
+@@ -6033,18 +6737,24 @@ Try \`$0 --help' for more information." >&2;}
      $ac_shift
      CONFIG_HEADERS="$CONFIG_HEADERS $ac_optarg"
      ac_need_defaults=false;;
@@ -25730,7 +25787,7 @@ index 2ea4aab..5329615 100755
  
    esac
    shift
-@@ -6060,42 +6769,54 @@ fi
+@@ -6060,42 +6770,54 @@ fi
  _ACEOF
  cat >>$CONFIG_STATUS <<_ACEOF
  if \$ac_cs_recheck; then
@@ -25801,7 +25858,7 @@ index 2ea4aab..5329615 100755
  # If the user did not use the arguments to specify the items to instantiate,
  # then the envvar interface is used.  Set only those that are not.
  # We use the long form for the default assignment because of an extremely
-@@ -6107,627 +6828,616 @@ if $ac_need_defaults; then
+@@ -6107,627 +6829,616 @@ if $ac_need_defaults; then
  fi
  
  # Have a temporary directory for convenience.  Make it in the build tree
@@ -26953,7 +27010,7 @@ index 2ea4aab..5329615 100755
  # Compute $ac_file's index in $config_headers.
  _am_stamp_count=1
  for _am_header in $config_headers :; do
-@@ -6738,135 +7448,39 @@ for _am_header in $config_headers :; do
+@@ -6738,135 +7449,39 @@ for _am_header in $config_headers :; do
        _am_stamp_count=`expr $_am_stamp_count + 1` ;;
    esac
  done
@@ -27115,7 +27172,7 @@ index 2ea4aab..5329615 100755
    # Strip MF so we end up with the name of the file.
    mf=`echo "$mf" | sed -e 's/:.*$//'`
    # Check whether this is an Automake generated Makefile or not.
-@@ -6876,18 +7490,29 @@ echo "$as_me: executing $ac_dest commands" >&6;}
+@@ -6876,18 +7491,29 @@ echo "$as_me: executing $ac_dest commands" >&6;}
    # each Makefile.in and add a new line on top of each file to say so.
    # So let's grep whole file.
    if grep '^#.*generated by automake' $mf > /dev/null 2>&1; then
@@ -27153,7 +27210,7 @@ index 2ea4aab..5329615 100755
    else
      continue
    fi
-@@ -6915,53 +7540,79 @@ echo X"$mf" |
+@@ -6915,53 +7541,79 @@ echo X"$mf" |
         sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
      # Make sure the directory exists.
      test -f "$dirpart/$file" && continue
@@ -30369,7 +30426,7 @@ index fd273ba..7270897 100644
 -]) # _AM_PROG_TAR
 -
 diff --git a/libsysio/configure b/libsysio/configure
-index 039b559..888951d 100755
+index 6b0335c..dca1aa8 100755
 --- a/libsysio/configure
 +++ b/libsysio/configure
 @@ -1,25 +1,54 @@
@@ -32748,15 +32805,11 @@ index 039b559..888951d 100755
  if test -n "$CC"; then
 -  echo "$as_me:$LINENO: result: $CC" >&5
 -echo "${ECHO_T}$CC" >&6
-+  { echo "$as_me:$LINENO: result: $CC" >&5
-+echo "${ECHO_T}$CC" >&6; }
- else
+-else
 -  echo "$as_me:$LINENO: result: no" >&5
 -echo "${ECHO_T}no" >&6
-+  { echo "$as_me:$LINENO: result: no" >&5
-+echo "${ECHO_T}no" >&6; }
- fi
- 
+-fi
+-
 -fi
 -if test -z "$ac_cv_prog_CC"; then
 -  ac_ct_CC=$CC
@@ -32769,7 +32822,9 @@ index 039b559..888951d 100755
 -else
 -  if test -n "$ac_ct_CC"; then
 -  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
--else
++  { echo "$as_me:$LINENO: result: $CC" >&5
++echo "${ECHO_T}$CC" >&6; }
+ else
 -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
 -for as_dir in $PATH
 -do
@@ -32793,8 +32848,10 @@ index 039b559..888951d 100755
 -else
 -  echo "$as_me:$LINENO: result: no" >&5
 -echo "${ECHO_T}no" >&6
--fi
--
++  { echo "$as_me:$LINENO: result: no" >&5
++echo "${ECHO_T}no" >&6; }
+ fi
+ 
 -  CC=$ac_ct_CC
 -else
 -  CC="$ac_cv_prog_CC"
@@ -33434,14 +33491,14 @@ index 039b559..888951d 100755
  
 -ac_cv_prog_cc_g=no
 +
-+fi
+ fi
+-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
 +
 +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
 +fi
 +
 +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- fi
--rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
++fi
 +
 +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
 +   ac_c_werror_flag=$ac_save_c_werror_flag
@@ -33706,7 +33763,7 @@ index 039b559..888951d 100755
 -else
 -  echo "$as_me: failed program was:" >&5
 -sed 's/^/| /' conftest.$ac_ext >&5
--
+ 
 -fi
 -rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
 -done
@@ -33720,7 +33777,7 @@ index 039b559..888951d 100755
 -else
 -  echo "$as_me: failed program was:" >&5
 -sed 's/^/| /' conftest.$ac_ext >&5
- 
+-
 -fi
 -rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
  ac_ext=c
@@ -34374,8 +34431,11 @@ index 039b559..888951d 100755
 +{ echo "$as_me:$LINENO: checking for egrep" >&5
 +echo $ECHO_N "checking for egrep... $ECHO_C" >&6; }
 +if test "${ac_cv_path_EGREP+set}" = set; then
-+  echo $ECHO_N "(cached) $ECHO_C" >&6
-+else
+   echo $ECHO_N "(cached) $ECHO_C" >&6
+ else
+-  if echo a | (grep -E '(a|b)') >/dev/null 2>&1
+-    then ac_cv_prog_egrep='grep -E'
+-    else ac_cv_prog_egrep='egrep'
 +  if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
 +   then ac_cv_path_EGREP="$GREP -E"
 +   else
@@ -34383,11 +34443,8 @@ index 039b559..888951d 100755
 +if test -z "$EGREP"; then
 +set dummy egrep; ac_prog_name=$2
 +if test "${ac_cv_path_EGREP+set}" = set; then
-   echo $ECHO_N "(cached) $ECHO_C" >&6
- else
--  if echo a | (grep -E '(a|b)') >/dev/null 2>&1
--    then ac_cv_prog_egrep='grep -E'
--    else ac_cv_prog_egrep='egrep'
++  echo $ECHO_N "(cached) $ECHO_C" >&6
++else
 +  ac_path_EGREP_found=false
 +# Loop through the user's path and test for each of PROGNAME-LIST
 +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
@@ -34447,21 +34504,21 @@ index 039b559..888951d 100755
 +
 +else
 +  ac_cv_path_EGREP=$EGREP
++fi
++
++
++   fi
  fi
 -echo "$as_me:$LINENO: result: $ac_cv_prog_egrep" >&5
 -echo "${ECHO_T}$ac_cv_prog_egrep" >&6
 - EGREP=$ac_cv_prog_egrep
++{ echo "$as_me:$LINENO: result: $ac_cv_path_EGREP" >&5
++echo "${ECHO_T}$ac_cv_path_EGREP" >&6; }
++ EGREP="$ac_cv_path_EGREP"
  
  
 -echo "$as_me:$LINENO: checking for ANSI C header files" >&5
 -echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
-+   fi
-+fi
-+{ echo "$as_me:$LINENO: result: $ac_cv_path_EGREP" >&5
-+echo "${ECHO_T}$ac_cv_path_EGREP" >&6; }
-+ EGREP="$ac_cv_path_EGREP"
-+
-+
 +{ echo "$as_me:$LINENO: checking for ANSI C header files" >&5
 +echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6; }
  if test "${ac_cv_header_stdc+set}" = set; then
@@ -34838,11 +34895,11 @@ index 039b559..888951d 100755
  	fi
 -fi;
 +fi
++
  
  
  
 -# Check whether --with-stdfd-dev or --without-stdfd-dev was given.
-+
 +# Check whether --with-stdfd-dev was given.
  if test "${with_stdfd_dev+set}" = set; then
 -  withval="$with_stdfd_dev"
@@ -34880,11 +34937,11 @@ index 039b559..888951d 100755
    with_zero_sum_memory=no
 -fi;
 +fi
-+
  
  
  
 -# Check whether --with-defer-init-cwd or --without-defer-init-cwd was given.
++
 +# Check whether --with-defer-init-cwd was given.
  if test "${with_defer_init_cwd+set}" = set; then
 -  withval="$with_defer_init_cwd"
@@ -34899,11 +34956,11 @@ index 039b559..888951d 100755
    with_defer_init_cwd=no
 -fi;
 +fi
-+
  
  
  
 -# Check whether --with-tracing or --without-tracing was given.
++
 +# Check whether --with-tracing was given.
  if test "${with_tracing+set}" = set; then
 -  withval="$with_tracing"
@@ -34918,11 +34975,11 @@ index 039b559..888951d 100755
    TRACING=-DSYSIO_TRACING=1
 -fi;
 +fi
++
  
  
  
 -# Check whether --with-cplant_yod or --without-cplant_yod was given.
-+
 +# Check whether --with-cplant_yod was given.
  if test "${with_cplant_yod+set}" = set; then
 -  withval="$with_cplant_yod"
@@ -35517,7 +35574,7 @@ index 039b559..888951d 100755
  if test x$have_st_gen = xyes; then
  	cat >>confdefs.h <<\_ACEOF
  #define HAVE_GENERATION 1
-@@ -4566,8 +5199,8 @@ _ACEOF
+@@ -4566,10 +5199,10 @@ _ACEOF
  
  fi
  
@@ -35526,8 +35583,11 @@ index 039b559..888951d 100755
 +{ echo "$as_me:$LINENO: checking for POSIX 2008 preadv" >&5
 +echo $ECHO_N "checking for POSIX 2008 preadv... $ECHO_C" >&6; }
  tmp_flags="$CFLAGS"
- CFLAGS="$CFLAGS -Wall -Werror"
+-CFLAGS="$CFLAGS -Wall -Werror"
++CFLAGS="$CFLAGS -Wall -Werror -fno-strict-aliasing"
  cat >conftest.$ac_ext <<_ACEOF
+ /* confdefs.h.  */
+ _ACEOF
 @@ -4594,50 +5227,46 @@ main ()
  }
  _ACEOF
@@ -35596,7 +35656,7 @@ index 039b559..888951d 100755
 +{ echo "$as_me:$LINENO: checking for POSIX 2008 scandir" >&5
 +echo $ECHO_N "checking for POSIX 2008 scandir... $ECHO_C" >&6; }
  tmp_flags="$CFLAGS"
- CFLAGS="$CFLAGS -Wall -Werror"
+ CFLAGS="$CFLAGS -Wall -Werror -fno-strict-aliasing"
  cat >conftest.$ac_ext <<_ACEOF
 @@ -4670,51 +5299,47 @@ main ()
  }
diff --git a/debian/patches/ldiskfs-detect-2.6.20-2.6.22.dpatch b/debian/patches/ldiskfs-detect-2.6.20-2.6.22.dpatch
index e83c623..b84a30d 100755
--- a/debian/patches/ldiskfs-detect-2.6.20-2.6.22.dpatch
+++ b/debian/patches/ldiskfs-detect-2.6.20-2.6.22.dpatch
@@ -5,10 +5,10 @@
 ## DP: Patch from Q-Leap Networks modified by Patrick winnertz <patrick.winnertz at credativ.de>
 
 @DPATCH@
-diff -urNad lustre~/ldiskfs/configure.ac lustre/ldiskfs/configure.ac
---- lustre~/ldiskfs/configure.ac	2009-08-13 11:31:22.000000000 +0200
-+++ lustre/ldiskfs/configure.ac	2009-08-13 11:32:19.000000000 +0200
-@@ -135,8 +135,12 @@
+diff -urNad '--exclude=CVS' '--exclude=.svn' '--exclude=.git' '--exclude=.arch' '--exclude=.hg' '--exclude=_darcs' '--exclude=.bzr' lustre~/ldiskfs/configure.ac lustre/ldiskfs/configure.ac
+--- lustre~/ldiskfs/configure.ac	2010-03-03 17:25:38.000000000 +0100
++++ lustre/ldiskfs/configure.ac	2010-03-04 14:53:13.608332585 +0100
+@@ -112,11 +112,16 @@
                  else
  		        LDISKFS_SERIES="2.6-rhel5.series"
                  fi
@@ -22,3 +22,7 @@ diff -urNad lustre~/ldiskfs/configure.ac lustre/ldiskfs/configure.ac
  	fi
  	;;
  2.6.22*) LDISKFS_SERIES="2.6.22-vanilla.series";;
++2.6.26*) LDISKFS_SERIES="2.6.26-vanilla.series";;
+ 2.6.27*) LDISKFS_SERIES="2.6-sles11.series";;
+ *) AC_MSG_WARN([Unknown kernel version $LINUXRELEASE, fix ldiskfs/configure.ac])
+ esac
diff --git a/ldiskfs/kernel_patches/patches/debian-2.6.26.diff b/ldiskfs/kernel_patches/patches/debian-2.6.26.diff
new file mode 100644
index 0000000..a1f22df
--- /dev/null
+++ b/ldiskfs/kernel_patches/patches/debian-2.6.26.diff
@@ -0,0 +1,1210 @@
+diff -u -r debian-2.6.26/Documentation/filesystems/ext2.txt debian-2.6.26_lustre.1.8.2/Documentation/filesystems/ext2.txt
+--- debian-2.6.26/Documentation/filesystems/ext2.txt	2008-07-13 23:51:29.000000000 +0200
++++ debian-2.6.26_lustre.1.8.2/Documentation/filesystems/ext2.txt	2010-02-12 15:11:19.000000000 +0100
+@@ -58,6 +58,22 @@
+ 
+ xip				Use execute in place (no caching) if possible
+ 
++iopen                          Makes an invisible pseudo-directory called 
++                               __iopen__ available in the root directory
++                               of the filesystem.  Allows open-by-inode-
++                               number.  i.e., inode 3145 can be accessed
++                               via /mntpt/__iopen__/3145
++
++iopen_nopriv                   This option makes the iopen directory be
++                               world-readable.  This may be safer since it
++                               allows daemons to run as an unprivileged user,
++                               however it significantly changes the security
++                               model of a Unix filesystem, since previously
++                               all files under a mode 700 directory were not
++                               generally avilable even if the
++                               permissions on the file itself is
++                               world-readable.
++
+ grpquota,noquota,quota,usrquota	Quota options are silently ignored by ext2.
+ 
+ 
+diff -u -r debian-2.6.26/block/blk-core.c debian-2.6.26_lustre.1.8.2/block/blk-core.c
+--- debian-2.6.26/block/blk-core.c	2008-07-13 23:51:29.000000000 +0200
++++ debian-2.6.26_lustre.1.8.2/block/blk-core.c	2010-02-12 15:14:32.000000000 +0100
+@@ -1270,6 +1270,8 @@
+ 
+ #endif /* CONFIG_FAIL_MAKE_REQUEST */
+ 
++int dev_check_rdonly(struct block_device *bdev);
++
+ /*
+  * Check whether this bio extends beyond the end of the device.
+  */
+@@ -1371,6 +1373,12 @@
+ 
+ 		if (unlikely(test_bit(QUEUE_FLAG_DEAD, &q->queue_flags)))
+ 			goto end_io;
++                /* this is cfs's dev_rdonly check */
++                if (bio->bi_rw == WRITE &&
++                                dev_check_rdonly(bio->bi_bdev)) {
++                        bio_endio(bio, 0);
++                        break;
++                }
+ 
+ 		if (should_fail_request(bio))
+ 			goto end_io;
+@@ -2028,6 +2036,91 @@
+ }
+ EXPORT_SYMBOL(kblockd_flush_work);
+ 
++ /*
++ * Debug code for turning block devices "read-only" (will discard writes
++ * silently).  This is for filesystem crash/recovery testing.
++ */
++struct deventry {
++       dev_t dev;
++       struct deventry *next;
++};
++
++static struct deventry *devlist = NULL;
++static spinlock_t devlock = SPIN_LOCK_UNLOCKED;
++
++int dev_check_rdonly(struct block_device *bdev)
++{
++       struct deventry *cur;
++       if (!bdev) return 0;
++       spin_lock(&devlock);
++       cur = devlist;
++       while(cur) {
++               if (bdev->bd_dev == cur->dev) {
++                       spin_unlock(&devlock);
++                       return 1;
++       }
++               cur = cur->next;
++       }
++       spin_unlock(&devlock);
++       return 0;
++}
++
++void dev_set_rdonly(struct block_device *bdev)
++{
++       struct deventry *newdev, *cur;
++
++       if (!bdev)
++               return;
++       newdev = kmalloc(sizeof(struct deventry), GFP_KERNEL);
++       if (!newdev)
++               return;
++
++       spin_lock(&devlock);
++       cur = devlist;
++       while(cur) {
++               if (bdev->bd_dev == cur->dev) {
++                       spin_unlock(&devlock);
++                       kfree(newdev);
++                       return;
++               }
++               cur = cur->next;
++       }
++       newdev->dev = bdev->bd_dev;
++       newdev->next = devlist;
++       devlist = newdev;
++       spin_unlock(&devlock);
++       printk(KERN_WARNING "Turning device %s (%#x) read-only\n",
++              bdev->bd_disk ? bdev->bd_disk->disk_name : "", bdev->bd_dev);
++}
++
++void dev_clear_rdonly(struct block_device *bdev)
++{
++       struct deventry *cur, *last = NULL;
++       if (!bdev) return;
++       spin_lock(&devlock);
++       cur = devlist;
++       while(cur) {
++               if (bdev->bd_dev == cur->dev) {
++                       if (last)
++                               last->next = cur->next;
++                       else
++                               devlist = cur->next;
++                       spin_unlock(&devlock);
++                       kfree(cur);
++                       printk(KERN_WARNING "Removing read-only on %s (%#x)\n",
++                              bdev->bd_disk ? bdev->bd_disk->disk_name :
++                                              "unknown block", bdev->bd_dev);
++                       return;
++               }
++               last = cur;
++               cur = cur->next;
++       }
++       spin_unlock(&devlock);
++}
++
++EXPORT_SYMBOL(dev_set_rdonly);
++EXPORT_SYMBOL(dev_clear_rdonly);
++
+ int __init blk_dev_init(void)
+ {
+ 	int i;
+diff -u -r debian-2.6.26/drivers/md/raid5.c debian-2.6.26_lustre.1.8.2/drivers/md/raid5.c
+--- debian-2.6.26/drivers/md/raid5.c	2008-07-13 23:51:29.000000000 +0200
++++ debian-2.6.26_lustre.1.8.2/drivers/md/raid5.c	2010-02-12 15:19:25.000000000 +0100
+@@ -1817,6 +1817,8 @@
+ 		bi->bi_next = *bip;
+ 	*bip = bi;
+ 	bi->bi_phys_segments ++;
++        if (bio_sync(bi) && !forwrite)
++                clear_bit(R5_UPTODATE, &sh->dev[dd_idx].flags); /* force to read from disk. */
+ 	spin_unlock_irq(&conf->device_lock);
+ 	spin_unlock(&sh->lock);
+ 
+@@ -3699,6 +3701,8 @@
+ 			      test_bit(BIO_UPTODATE, &bi->bi_flags)
+ 			        ? 0 : -EIO);
+ 	}
++	if (bio_sync(bi))
++		raid5_unplug_device(q);
+ 	return 0;
+ }
+ 
+diff -u -r debian-2.6.26/drivers/scsi/Kconfig debian-2.6.26_lustre.1.8.2/drivers/scsi/Kconfig
+--- debian-2.6.26/drivers/scsi/Kconfig	2009-12-26 09:14:53.000000000 +0100
++++ debian-2.6.26_lustre.1.8.2/drivers/scsi/Kconfig	2010-02-12 15:20:02.000000000 +0100
+@@ -81,6 +81,14 @@
+ 	  In this case, do not compile the driver for your SCSI host adapter
+ 	  (below) as a module either.
+ 
++config SD_IOSTATS
++   bool "Enable SCSI disk I/O stats"
++   depends on BLK_DEV_SD
++   default y
++   ---help---
++     This enables SCSI disk I/O stats collection.  You must also enable
++     /proc file system support if you want this feature.
++
+ config CHR_DEV_ST
+ 	tristate "SCSI tape support"
+ 	depends on SCSI
+diff -u -r debian-2.6.26/drivers/scsi/scsi_proc.c debian-2.6.26_lustre.1.8.2/drivers/scsi/scsi_proc.c
+--- debian-2.6.26/drivers/scsi/scsi_proc.c	2008-07-13 23:51:29.000000000 +0200
++++ debian-2.6.26_lustre.1.8.2/drivers/scsi/scsi_proc.c	2010-02-12 15:22:05.000000000 +0100
+@@ -40,7 +40,8 @@
+ /* 4K page size, but our output routines, use some slack for overruns */
+ #define PROC_BLOCK_SIZE (3*1024)
+ 
+-static struct proc_dir_entry *proc_scsi;
++struct proc_dir_entry *proc_scsi;
++EXPORT_SYMBOL(proc_scsi);
+ 
+ /* Protect sht->present and sht->proc_dir */
+ static DEFINE_MUTEX(global_host_template_mutex);
+diff -u -r debian-2.6.26/drivers/scsi/sd.c debian-2.6.26_lustre.1.8.2/drivers/scsi/sd.c
+--- debian-2.6.26/drivers/scsi/sd.c	2008-07-13 23:51:29.000000000 +0200
++++ debian-2.6.26_lustre.1.8.2/drivers/scsi/sd.c	2010-02-17 14:13:32.000000000 +0100
+@@ -107,6 +107,24 @@
+  * object after last put) */
+ static DEFINE_MUTEX(sd_ref_mutex);
+ 
++#if (defined(CONFIG_SD_IOSTATS) && defined(CONFIG_PROC_FS))
++# include <linux/proc_fs.h>
++# include <linux/seq_file.h>
++struct proc_dir_entry *sd_iostats_procdir = NULL;
++char sd_iostats_procdir_name[] = "sd_iostats";
++static struct file_operations sd_iostats_proc_fops;
++
++extern void sd_iostats_init(void);
++extern void sd_iostats_fini(void);
++void sd_iostats_start_req(struct scsi_cmnd *SCpnt);
++void sd_iostats_finish_req(struct scsi_cmnd *SCpnt);
++#else
++static inline void sd_iostats_init(void) {}
++static inline void sd_iostats_fini(void) {}
++static inline void sd_iostats_start_req(struct scsi_cmnd *SCpnt) {}
++static inline void sd_iostats_finish_req(struct scsi_cmnd *SCpnt) {}
++#endif
++
+ static const char *sd_cache_types[] = {
+ 	"write through", "none", "write back",
+ 	"write back, no read (daft)"
+@@ -531,6 +549,8 @@
+ 	}
+ 	SCpnt->sdb.length = this_count * sdp->sector_size;
+ 
++	sd_iostats_start_req(SCpnt);
++
+ 	/*
+ 	 * We shouldn't disconnect in the middle of a sector, so with a dumb
+ 	 * host adapter, it's safe to assume that we can at least transfer
+@@ -667,7 +687,7 @@
+ 	int diskinfo[4];
+ 
+ 	/* default to most commonly used values */
+-        diskinfo[0] = 0x40;	/* 1 << 6 */
++	diskinfo[0] = 0x40;	/* 1 << 6 */
+        	diskinfo[1] = 0x20;	/* 1 << 5 */
+        	diskinfo[2] = sdkp->capacity >> 11;
+ 	
+@@ -1023,6 +1043,7 @@
+ 		break;
+ 	}
+  out:
++	sd_iostats_finish_req(SCpnt);
+ 	return good_bytes;
+ }
+ 
+@@ -1711,6 +1732,36 @@
+ 	gd->flags = GENHD_FL_DRIVERFS;
+ 	if (sdp->removable)
+ 		gd->flags |= GENHD_FL_REMOVABLE;
++#if (defined(CONFIG_SD_IOSTATS) && defined(CONFIG_PROC_FS))
++       sdkp->stats = kzalloc(sizeof(iostat_stats_t), GFP_KERNEL);
++       if (!sdkp->stats) {
++	       printk(KERN_WARNING "cannot allocate iostat structure for"
++	                           "%s\n", gd->disk_name);
++       } else {
++	       do_gettimeofday(&sdkp->stats->iostat_timeval);
++	       sdkp->stats->iostat_queue_stamp = jiffies;
++	       spin_lock_init(&sdkp->stats->iostat_lock);
++	       if (sd_iostats_procdir) {
++	               struct proc_dir_entry *pde;
++	               pde = create_proc_entry(gd->disk_name, S_IRUGO | S_IWUSR,
++	                                       sd_iostats_procdir);
++	               if (!pde) {
++	                       printk(KERN_WARNING "Can't create /proc/scsi/"
++	                                           "%s/%s\n",
++	                                           sd_iostats_procdir_name,
++	                                           gd->disk_name);
++	                       kfree(sdkp->stats);
++	                       sdkp->stats = NULL;
++	               } else {
++	                       pde->proc_fops = &sd_iostats_proc_fops;
++	                       pde->data = gd;
++	               }
++	       } else {
++	               kfree(sdkp->stats);
++	               sdkp->stats = NULL;
++	       }
++       }
++#endif
+ 
+ 	dev_set_drvdata(dev, sdkp);
+ 	add_disk(gd);
+@@ -1755,6 +1806,366 @@
+ 	return 0;
+ }
+ 
++#if (defined(CONFIG_SD_IOSTATS) && defined(CONFIG_PROC_FS))
++static int
++ sd_iostats_seq_show(struct seq_file *seq, void *v)
++ {
++	struct timeval     now;
++	struct gendisk *disk = seq->private;
++	iostat_stats_t    *stats;
++	unsigned long long read_len;
++	unsigned long long read_len_tot;
++	unsigned long      read_num;
++	unsigned long      read_num_tot;
++	unsigned long long write_len;
++	unsigned long long write_len_tot;
++	unsigned long      write_num;
++	unsigned long      write_num_tot;
++	int                i;
++	int                maxi;
++ 
++	stats = scsi_disk(disk)->stats;
++	if (stats == NULL) {
++	        printk(KERN_ERR "sd_iostats_seq_show: NULL stats entry\n");
++	        BUG();
++	}
++ 
++	do_gettimeofday(&now);
++	now.tv_sec -= stats->iostat_timeval.tv_sec;
++	now.tv_usec -= stats->iostat_timeval.tv_usec;
++	if (now.tv_usec < 0) {
++	        now.tv_usec += 1000000;
++	        now.tv_sec--;
++	}
++ 
++	/* this sampling races with updates */
++	seq_printf(seq, "index:        %lu   snapshot_time:         %lu.%06lu\n",
++	                (unsigned long) scsi_disk(disk)->index,
++	                now.tv_sec, now.tv_usec);
++ 
++	for (i = IOSTAT_NCOUNTERS - 1; i > 0; i--)
++	        if (stats->iostat_read_histogram[i].iostat_count != 0 ||
++	                        stats->iostat_write_histogram[i].iostat_count != 0)
++	                break;
++	maxi = i;
++ 
++	seq_printf(seq, "%8s %8s %12s %8s %12s\n", "size", 
++	                "reads", "total", "writes", "total");
++ 
++	read_len_tot = write_len_tot = 0;
++	read_num_tot = write_num_tot = 0;
++	for (i = 0; i <= maxi; i++) {
++	        read_len = stats->iostat_read_histogram[i].iostat_size;
++	        read_len_tot += read_len;
++	        read_num = stats->iostat_read_histogram[i].iostat_count;
++	        read_num_tot += read_num;
++ 
++	        write_len = stats->iostat_write_histogram[i].iostat_size;
++	        write_len_tot += write_len;
++	        write_num = stats->iostat_write_histogram[i].iostat_count;
++	        write_num_tot += write_num;
++ 
++	        seq_printf (seq, "%8d %8lu %12llu %8lu %12llu\n", 
++	                        512<<i, read_num, read_len, write_num, write_len);
++	}
++ 
++	seq_printf(seq, "%8s %8lu %12llu %8lu %12llu\n\n", "total",
++	                read_num_tot, read_len_tot, 
++	                write_num_tot, write_len_tot);
++ 
++	seq_printf(seq, "%8s %8s %8s\n", "qdepth", "ticks", "%");
++	for (i = 0; i < IOSTAT_NCOUNTERS; i++) {
++	        unsigned long long ticks, percent;
++	        ticks = stats->iostat_queue_ticks[i];
++	        if (ticks == 0)
++	                continue;
++	        percent = stats->iostat_queue_ticks[i] * 100;
++	        do_div(percent, stats->iostat_queue_ticks_sum);
++	        seq_printf(seq, "%8d %8llu %8llu\n", i, ticks, percent);
++	}
++ 
++	if (stats->iostat_reqs != 0) {
++	        unsigned long long aveseek = 0, percent = 0;
++ 
++	        if (stats->iostat_seeks) {
++	                aveseek = stats->iostat_seek_sectors;
++	                do_div(aveseek, stats->iostat_seeks);
++	                percent = stats->iostat_seeks * 100;
++	                do_div(percent, stats->iostat_reqs);
++	        }
++ 
++	        seq_printf(seq, "\n%llu sectors in %llu reqs: %llu seek(s) over "
++	                        "%llu sectors in ave, %llu%% of all reqs\n",
++	                        stats->iostat_sectors, stats->iostat_reqs,
++	                        stats->iostat_seeks, aveseek, percent);
++	}
++ 
++	seq_printf(seq, "\n%16s %8s %8s %8s %8s\n", "process time", "reads",
++	                "%%", "writes", "%%");
++	for (i = 0; i < IOSTAT_NCOUNTERS; i++) {
++	        unsigned long read_percent = 0, write_percent = 0;
++	        if (stats->iostat_wtime[i] == 0 &&
++	                        stats->iostat_rtime[i] == 0)
++	                continue;
++	        if (stats->iostat_read_reqs)
++	                read_percent = stats->iostat_rtime[i] * 100 / 
++	                        stats->iostat_read_reqs;
++	        if (stats->iostat_write_reqs)
++	                write_percent = stats->iostat_wtime[i] * 100 / 
++	                        stats->iostat_write_reqs;
++	        seq_printf(seq, "%16u %8lu %8lu %8lu %8lu\n",
++	                        jiffies_to_msecs(((1UL << i) >> 1) << 1),
++	                        stats->iostat_rtime[i], read_percent,
++	                        stats->iostat_wtime[i], write_percent);
++	}
++ 
++	seq_printf(seq, "\n%16s %8s %8s %8s %8s\n", "time in queue", "reads",
++	                "%%", "writes", "%%");
++	for (i = 0; i < IOSTAT_NCOUNTERS; i++) {
++	        unsigned long read_percent = 0, write_percent = 0;
++	        if (stats->iostat_wtime_in_queue[i] == 0 &&
++	                        stats->iostat_rtime_in_queue[i] == 0)
++	                continue;
++	        if (stats->iostat_read_reqs)
++	                read_percent = stats->iostat_rtime_in_queue[i] * 100 / 
++	                        stats->iostat_read_reqs;
++	        if (stats->iostat_write_reqs)
++	                write_percent = stats->iostat_wtime_in_queue[i] * 100 / 
++	                        stats->iostat_write_reqs;
++	        seq_printf(seq, "%16u %8lu %8lu %8lu %8lu\n",
++	                        jiffies_to_msecs(((1UL << i) >> 1) << 1),
++	                        stats->iostat_rtime_in_queue[i],
++	                        read_percent,
++	                        stats->iostat_wtime_in_queue[i],
++	                        write_percent);
++	}
++ 
++	return 0;
++ }
++ 
++ static void *
++ sd_iostats_seq_start(struct seq_file *p, loff_t *pos)
++ {
++	return (*pos == 0) ? (void *)1 : NULL;
++ }
++ 
++ static void *
++ sd_iostats_seq_next(struct seq_file *p, void *v, loff_t *pos)
++ {
++	++*pos;
++	return NULL;
++ }
++ 
++ static void
++ sd_iostats_seq_stop(struct seq_file *p, void *v)
++ {
++ }
++ 
++ static struct seq_operations sd_iostats_seqops = {
++	.start = sd_iostats_seq_start,
++	.stop  = sd_iostats_seq_stop,
++	.next  = sd_iostats_seq_next,
++	.show  = sd_iostats_seq_show,
++ };
++ 
++ static int
++ sd_iostats_seq_open (struct inode *inode, struct file *file)
++ {
++	int rc;
++ 
++	rc = seq_open(file, &sd_iostats_seqops);
++	if (rc != 0)
++	        return rc;
++ 
++	((struct seq_file *)file->private_data)->private = PDE(inode)->data;
++	return 0;
++ }
++ 
++ static ssize_t
++ sd_iostats_seq_write(struct file *file, const char *buffer,
++	             size_t len, loff_t *off)
++ {
++	struct seq_file   *seq = file->private_data;
++	struct gendisk *disk = seq->private;
++	iostat_stats_t    *stats = scsi_disk(disk)->stats;
++	unsigned long      flags;
++	unsigned long      qdepth;
++ 
++ 
++	spin_lock_irqsave (&stats->iostat_lock, flags);
++	qdepth = stats->iostat_queue_depth;
++	memset (stats, 0, offsetof(iostat_stats_t, iostat_lock));
++	do_gettimeofday(&stats->iostat_timeval);
++	stats->iostat_queue_stamp = jiffies;
++	stats->iostat_queue_depth = qdepth;
++	spin_unlock_irqrestore (&stats->iostat_lock, flags);
++ 
++	return len;
++ }
++ 
++ static struct file_operations sd_iostats_proc_fops = {
++	.owner   = THIS_MODULE,
++	.open    = sd_iostats_seq_open,
++	.read    = seq_read,
++	.write   = sd_iostats_seq_write,
++	.llseek  = seq_lseek,
++	.release = seq_release,
++ };
++ 
++ extern struct proc_dir_entry *proc_scsi;
++ 
++ void
++ sd_iostats_init(void)
++ {
++	if (proc_scsi == NULL) {
++	        printk(KERN_WARNING "No access to sd iostats: "
++	                "proc_scsi is NULL\n");
++	        return;
++	}
++ 
++	sd_iostats_procdir = create_proc_entry(sd_iostats_procdir_name,
++	                                       S_IFDIR | S_IRUGO | S_IXUGO,
++	                                        proc_scsi);
++	if (sd_iostats_procdir == NULL) {
++	        printk(KERN_WARNING "No access to sd iostats: "
++	                "can't create /proc/scsi/%s\n", sd_iostats_procdir_name);
++	        return;
++	}
++ }
++ 
++ void sd_iostats_fini(void)
++ {
++	if (proc_scsi != NULL && sd_iostats_procdir != NULL)
++	        remove_proc_entry(sd_iostats_procdir_name, proc_scsi);
++ 
++	sd_iostats_procdir = NULL;
++ }
++ 
++ void sd_iostats_finish_req(struct scsi_cmnd *SCpnt)
++ {
++	struct request          *rq = SCpnt->request;
++	iostat_stats_t          *stats;
++	unsigned long           *tcounter;
++	int                     tbucket;
++	int                     tmp;
++	unsigned long           irqflags;
++	unsigned long           i;
++ 
++	stats = scsi_disk(rq->rq_disk)->stats;
++	if (stats == NULL)
++	        return;
++ 
++	tmp = jiffies - rq->start_time;
++	for (tbucket = 0; tmp > 1; tbucket++)
++	        tmp >>= 1;
++	if (tbucket >= IOSTAT_NCOUNTERS)
++	        tbucket = IOSTAT_NCOUNTERS - 1;
++	//printk("%u ticks in D to %u\n", jiffies - rq->start_time, tbucket);
++ 
++	tcounter = rq_data_dir(rq) == WRITE ?
++	        &stats->iostat_wtime[tbucket] : &stats->iostat_rtime[tbucket];
++ 
++	spin_lock_irqsave(&stats->iostat_lock, irqflags);
++ 
++	/* update delay stats */
++	(*tcounter)++;
++ 
++	/* update queue depth stats */
++	i = stats->iostat_queue_depth;
++	if (i >= IOSTAT_NCOUNTERS)
++	        i = IOSTAT_NCOUNTERS - 1;
++	stats->iostat_queue_ticks[i] += jiffies - stats->iostat_queue_stamp;
++	stats->iostat_queue_ticks_sum += jiffies - stats->iostat_queue_stamp;
++	BUG_ON(stats->iostat_queue_depth == 0);
++	stats->iostat_queue_depth--;
++ 
++	/* update seek stats. XXX: not sure about nr_sectors */
++	stats->iostat_sectors += rq->nr_sectors;
++	stats->iostat_reqs++;
++	if (rq->sector != stats->iostat_next_sector) {
++	        stats->iostat_seek_sectors +=
++	                rq->sector > stats->iostat_next_sector ?
++	                rq->sector - stats->iostat_next_sector :
++	                stats->iostat_next_sector - rq->sector;
++	        stats->iostat_seeks++;
++	}
++	stats->iostat_next_sector = rq->sector + rq->nr_sectors;
++ 
++	stats->iostat_queue_stamp = jiffies;
++ 
++	spin_unlock_irqrestore(&stats->iostat_lock, irqflags);
++ }
++ 
++ void sd_iostats_start_req(struct scsi_cmnd *SCpnt)
++ {
++	struct request          *rq = SCpnt->request;
++	iostat_stats_t          *stats;
++	iostat_counter_t        *counter;
++	int                     bucket;
++	int                     tbucket;
++	int                     tmp;
++	unsigned long           irqflags;
++	unsigned long           i;
++	int                     nsect;
++ 
++	stats = scsi_disk(rq->rq_disk)->stats;
++	if (stats == NULL)
++	        return;
++ 
++	nsect = scsi_bufflen(SCpnt) >> 9;
++	for (bucket = 0, tmp = nsect; tmp > 1; bucket++)
++	        tmp >>= 1;
++ 
++	if (bucket >= IOSTAT_NCOUNTERS) {
++	        printk (KERN_ERR "sd_iostats_bump: nsect %d too big\n", nsect);
++	        BUG();
++	}
++ 
++	counter = rq_data_dir(rq) == WRITE ?
++	        &stats->iostat_write_histogram[bucket] :
++	        &stats->iostat_read_histogram[bucket];
++ 
++	tmp = jiffies - rq->start_time;
++	for (tbucket = 0; tmp > 1; tbucket++)
++	        tmp >>= 1;
++	if (tbucket >= IOSTAT_NCOUNTERS)
++	        tbucket = IOSTAT_NCOUNTERS - 1;
++	//printk("%u ticks in Q to %u\n", jiffies - rq->start_time, tbucket);
++ 
++	/* an ugly hack to know exact processing time. the right
++	 * solution is to add one more field to struct request
++	 * hopefully it will break nothing ... */
++	rq->start_time = jiffies;
++ 
++	spin_lock_irqsave(&stats->iostat_lock, irqflags);
++ 
++	/* update queue depth stats */
++	i = stats->iostat_queue_depth;
++	if (i >= IOSTAT_NCOUNTERS)
++	        i = IOSTAT_NCOUNTERS - 1;
++	stats->iostat_queue_ticks[i] += jiffies - stats->iostat_queue_stamp;
++	stats->iostat_queue_ticks_sum += jiffies - stats->iostat_queue_stamp;
++	stats->iostat_queue_depth++;
++ 
++	/* update delay stats */
++	if (rq_data_dir(rq) == WRITE) {
++	        stats->iostat_wtime_in_queue[tbucket]++;
++	        stats->iostat_write_reqs++;
++	} else {
++	        stats->iostat_rtime_in_queue[tbucket]++;
++	        stats->iostat_read_reqs++;
++	}
++ 
++	/* update size stats */
++	counter->iostat_size += nsect;
++	counter->iostat_count++;
++ 
++	stats->iostat_queue_stamp = jiffies;
++ 
++	spin_unlock_irqrestore(&stats->iostat_lock, irqflags);
++}
++#endif
++
+ /**
+  *	scsi_disk_release - Called to free the scsi_disk structure
+  *	@dev: pointer to embedded class device
+@@ -1773,6 +2184,13 @@
+ 	idr_remove(&sd_index_idr, sdkp->index);
+ 	spin_unlock(&sd_index_lock);
+ 
++#if (defined(CONFIG_SD_IOSTATS) && defined(CONFIG_PROC_FS))
++        if (sdkp->stats) {
++                remove_proc_entry(disk->disk_name, sd_iostats_procdir);
++                kfree(sdkp->stats);
++                sdkp->stats = NULL;
++        }
++#endif
+ 	disk->private_data = NULL;
+ 	put_disk(disk);
+ 	put_device(&sdkp->device->sdev_gendev);
+@@ -1890,6 +2308,8 @@
+ 	if (!majors)
+ 		return -ENODEV;
+ 
++	sd_iostats_init();
++
+ 	err = class_register(&sd_disk_class);
+ 	if (err)
+ 		goto err_out;
+@@ -1905,6 +2325,7 @@
+ err_out:
+ 	for (i = 0; i < SD_MAJORS; i++)
+ 		unregister_blkdev(sd_major(i), "sd");
++	sd_iostats_fini();
+ 	return err;
+ }
+ 
+diff -u -r debian-2.6.26/fs/block_dev.c debian-2.6.26_lustre.1.8.2/fs/block_dev.c
+--- debian-2.6.26/fs/block_dev.c	2008-07-13 23:51:29.000000000 +0200
++++ debian-2.6.26_lustre.1.8.2/fs/block_dev.c	2010-02-17 14:19:50.000000000 +0100
+@@ -1125,6 +1125,7 @@
+ 		if (bdev != bdev->bd_contains)
+ 			victim = bdev->bd_contains;
+ 		bdev->bd_contains = NULL;
++		dev_clear_rdonly(bdev);
+ 	}
+ 	unlock_kernel();
+ 	mutex_unlock(&bdev->bd_mutex);
+diff -u -r debian-2.6.26/fs/dcache.c debian-2.6.26_lustre.1.8.2/fs/dcache.c
+--- debian-2.6.26/fs/dcache.c	2009-12-26 09:14:56.000000000 +0100
++++ debian-2.6.26_lustre.1.8.2/fs/dcache.c	2010-02-17 14:24:24.000000000 +0100
+@@ -250,6 +250,13 @@
+ 		spin_unlock(&dcache_lock);
+ 		return 0;
+ 	}
++
++        /* network invalidation by Lustre */
++        if (dentry->d_flags & DCACHE_LUSTRE_INVALID) {
++                spin_unlock(&dcache_lock);
++                return 0;
++        }
++
+ 	/*
+ 	 * Check whether to do a partial shrink_dcache
+ 	 * to get rid of unused child entries.
+@@ -1427,14 +1434,23 @@
+  *
+  * Adds a dentry to the hash according to its name.
+  */
+- 
++
++void d_rehash_cond(struct dentry * entry, int lock)
++{
++        if (lock)
++                spin_lock(&dcache_lock);
++        spin_lock(&entry->d_lock);
++        _d_rehash(entry);
++        spin_unlock(&entry->d_lock);
++        if (lock)
++                spin_unlock(&dcache_lock);
++}
++
++EXPORT_SYMBOL(d_rehash_cond);
++
+ void d_rehash(struct dentry * entry)
+ {
+-	spin_lock(&dcache_lock);
+-	spin_lock(&entry->d_lock);
+-	_d_rehash(entry);
+-	spin_unlock(&entry->d_lock);
+-	spin_unlock(&dcache_lock);
++	d_rehash_cond(entry, 1);
+ }
+ 
+ #define do_switch(x,y) do { \
+@@ -1510,7 +1526,7 @@
+  * Update the dcache to reflect the move of a file name. Negative
+  * dcache entries should not be moved in this way.
+  */
+-static void d_move_locked(struct dentry * dentry, struct dentry * target)
++void d_move_locked(struct dentry * dentry, struct dentry * target)
+ {
+ 	struct hlist_head *list;
+ 
+@@ -1568,6 +1584,7 @@
+ 	spin_unlock(&dentry->d_lock);
+ 	write_sequnlock(&rename_lock);
+ }
++EXPORT_SYMBOL(d_move_locked);
+ 
+ /**
+  * d_move - move a dentry
+@@ -2051,6 +2068,7 @@
+ 
+ 	return result;
+ }
++EXPORT_SYMBOL(is_subdir);
+ 
+ void d_genocide(struct dentry *root)
+ {
+diff -u -r debian-2.6.26/fs/filesystems.c debian-2.6.26_lustre.1.8.2/fs/filesystems.c
+--- debian-2.6.26/fs/filesystems.c	2009-12-26 09:14:56.000000000 +0100
++++ debian-2.6.26_lustre.1.8.2/fs/filesystems.c	2010-02-17 14:26:59.000000000 +0100
+@@ -28,7 +28,9 @@
+  */
+ 
+ static struct file_system_type *file_systems;
+-static DEFINE_RWLOCK(file_systems_lock);
++DEFINE_RWLOCK(file_systems_lock);
++
++EXPORT_SYMBOL(file_systems_lock);
+ 
+ /* WARNING: This can be used only if we _already_ own a reference */
+ void get_filesystem(struct file_system_type *fs)
+diff -u -r debian-2.6.26/fs/inode.c debian-2.6.26_lustre.1.8.2/fs/inode.c
+--- debian-2.6.26/fs/inode.c	2008-07-13 23:51:29.000000000 +0200
++++ debian-2.6.26_lustre.1.8.2/fs/inode.c	2010-02-17 14:27:51.000000000 +0100
+@@ -409,7 +409,9 @@
+ 	int nr_scanned;
+ 	unsigned long reap = 0;
+ 
+-	mutex_lock(&iprune_mutex);
++	if (!mutex_trylock(&iprune_mutex))
++		return;
++
+ 	spin_lock(&inode_lock);
+ 	for (nr_scanned = 0; nr_scanned < nr_to_scan; nr_scanned++) {
+ 		struct inode *inode;
+diff -u -r debian-2.6.26/fs/jbd2/checkpoint.c debian-2.6.26_lustre.1.8.2/fs/jbd2/checkpoint.c
+--- debian-2.6.26/fs/jbd2/checkpoint.c	2008-07-13 23:51:29.000000000 +0200
++++ debian-2.6.26_lustre.1.8.2/fs/jbd2/checkpoint.c	2010-02-17 14:28:49.000000000 +0100
+@@ -696,6 +696,7 @@
+ 	J_ASSERT(transaction->t_checkpoint_list == NULL);
+ 	J_ASSERT(transaction->t_checkpoint_io_list == NULL);
+ 	J_ASSERT(transaction->t_updates == 0);
++	J_ASSERT(list_empty(&transaction->t_jcb));
+ 	J_ASSERT(journal->j_committing_transaction != transaction);
+ 	J_ASSERT(journal->j_running_transaction != transaction);
+ 
+diff -u -r debian-2.6.26/fs/jbd2/commit.c debian-2.6.26_lustre.1.8.2/fs/jbd2/commit.c
+--- debian-2.6.26/fs/jbd2/commit.c	2008-07-13 23:51:29.000000000 +0200
++++ debian-2.6.26_lustre.1.8.2/fs/jbd2/commit.c	2010-02-17 14:29:44.000000000 +0100
+@@ -874,6 +874,30 @@
+            transaction can be removed from any checkpoint list it was on
+            before. */
+ 
++        /*
++         * Call any callbacks that had been registered for handles in this
++         * transaction.  It is up to the callback to free any allocated
++         * memory.
++         *
++         * The spinlocking (t_jcb_lock) here is surely unnecessary...
++         */
++        spin_lock(&commit_transaction->t_jcb_lock);
++        if (!list_empty(&commit_transaction->t_jcb)) {
++                struct list_head *p, *n;
++                int error = is_journal_aborted(journal);
++
++                list_for_each_safe(p, n, &commit_transaction->t_jcb) {
++                        struct journal_callback *jcb;
++
++                        jcb = list_entry(p, struct journal_callback, jcb_list);
++                        list_del(p);
++                        spin_unlock(&commit_transaction->t_jcb_lock);
++                        jcb->jcb_func(jcb, error);
++                        spin_lock(&commit_transaction->t_jcb_lock);
++                }
++        }
++        spin_unlock(&commit_transaction->t_jcb_lock);
++
+ 	jbd_debug(3, "JBD: commit phase 7\n");
+ 
+ 	J_ASSERT(commit_transaction->t_sync_datalist == NULL);
+diff -u -r debian-2.6.26/fs/jbd2/journal.c debian-2.6.26_lustre.1.8.2/fs/jbd2/journal.c
+--- debian-2.6.26/fs/jbd2/journal.c	2008-07-13 23:51:29.000000000 +0200
++++ debian-2.6.26_lustre.1.8.2/fs/jbd2/journal.c	2010-02-17 14:38:15.000000000 +0100
+@@ -82,6 +82,8 @@
+ EXPORT_SYMBOL(jbd2_journal_invalidatepage);
+ EXPORT_SYMBOL(jbd2_journal_try_to_free_buffers);
+ EXPORT_SYMBOL(jbd2_journal_force_commit);
++EXPORT_SYMBOL(jbd2_journal_callback_set);
++EXPORT_SYMBOL(jbd2_journal_bmap);
+ 
+ static int journal_convert_superblock_v1(journal_t *, journal_superblock_t *);
+ static void __journal_abort_soft (journal_t *journal, int errno);
+@@ -460,6 +462,7 @@
+ 	spin_unlock(&journal->j_state_lock);
+ 	return ret;
+ }
++EXPORT_SYMBOL(jbd2_log_start_commit);
+ 
+ /*
+  * Force and wait upon a commit if the calling process is not within
+diff -u -r debian-2.6.26/fs/jbd2/transaction.c debian-2.6.26_lustre.1.8.2/fs/jbd2/transaction.c
+--- debian-2.6.26/fs/jbd2/transaction.c	2008-07-13 23:51:29.000000000 +0200
++++ debian-2.6.26_lustre.1.8.2/fs/jbd2/transaction.c	2010-02-17 14:42:20.000000000 +0100
+@@ -51,10 +51,12 @@
+ 	transaction->t_state = T_RUNNING;
+ 	transaction->t_tid = journal->j_transaction_sequence++;
+ 	transaction->t_expires = jiffies + journal->j_commit_interval;
++	INIT_LIST_HEAD(&transaction->t_jcb);
+ 	spin_lock_init(&transaction->t_handle_lock);
++	spin_lock_init(&transaction->t_jcb_lock);
+ 
+ 	/* Set up the commit timer for the new transaction. */
+-	journal->j_commit_timer.expires = round_jiffies(transaction->t_expires);
++	journal->j_commit_timer.expires = transaction->t_expires;
+ 	add_timer(&journal->j_commit_timer);
+ 
+ 	J_ASSERT(journal->j_running_transaction == NULL);
+@@ -252,6 +254,7 @@
+ 	memset(handle, 0, sizeof(*handle));
+ 	handle->h_buffer_credits = nblocks;
+ 	handle->h_ref = 1;
++	INIT_LIST_HEAD(&handle->h_jcb);
+ 
+ 	lockdep_init_map(&handle->h_lockdep_map, "jbd2_handle",
+ 						&jbd2_handle_key, 0);
+@@ -1350,6 +1353,36 @@
+ }
+ 
+ /**
++ * void jbd2_journal_callback_set() -  Register a callback function for this handle.
++ * @handle: handle to attach the callback to.
++ * @func: function to callback.
++ * @jcb:  structure with additional information required by func() , and
++ *      some space for jbd2 internal information.
++ *
++ * The function will be
++ * called when the transaction that this handle is part of has been
++ * committed to disk with the original callback data struct and the
++ * error status of the journal as parameters.  There is no guarantee of
++ * ordering between handles within a single transaction, nor between
++ * callbacks registered on the same handle.
++ *
++ * The caller is responsible for allocating the journal_callback struct.
++ * This is to allow the caller to add as much extra data to the callback
++ * as needed, but reduce the overhead of multiple allocations.  The caller
++ * allocated struct must start with a struct journal_callback at offset 0,
++ * and has the caller-specific data afterwards.
++ */
++void jbd2_journal_callback_set(handle_t *handle,
++                      void (*func)(struct journal_callback *jcb, int error),
++                      struct journal_callback *jcb)
++{
++        spin_lock(&handle->h_transaction->t_jcb_lock);
++        list_add_tail(&jcb->jcb_list, &handle->h_jcb);
++        spin_unlock(&handle->h_transaction->t_jcb_lock);
++        jcb->jcb_func = func;
++}
++
++/**
+  * int jbd2_journal_stop() - complete a transaction
+  * @handle: tranaction to complete.
+  *
+@@ -1423,6 +1456,11 @@
+ 			wake_up(&journal->j_wait_transaction_locked);
+ 	}
+ 
++        /* Move callbacks from the handle to the transaction. */
++        spin_lock(&transaction->t_jcb_lock);
++        list_splice(&handle->h_jcb, &transaction->t_jcb);
++        spin_unlock(&transaction->t_jcb_lock);
++
+ 	/*
+ 	 * If the handle is marked SYNC, we need to set another commit
+ 	 * going!  We also want to force a commit if the current
+diff -u -r debian-2.6.26/fs/namespace.c debian-2.6.26_lustre.1.8.2/fs/namespace.c
+--- debian-2.6.26/fs/namespace.c	2009-12-26 09:14:56.000000000 +0100
++++ debian-2.6.26_lustre.1.8.2/fs/namespace.c	2010-02-17 14:43:07.000000000 +0100
+@@ -1660,6 +1660,7 @@
+ 
+ 	return do_add_mount(mnt, nd, mnt_flags, NULL);
+ }
++EXPORT_SYMBOL(set_fs_pwd);
+ 
+ /*
+  * add a mount into a namespace's mount tree
+diff -u -r debian-2.6.26/include/linux/blkdev.h debian-2.6.26_lustre.1.8.2/include/linux/blkdev.h
+--- debian-2.6.26/include/linux/blkdev.h	2009-12-26 09:14:55.000000000 +0100
++++ debian-2.6.26_lustre.1.8.2/include/linux/blkdev.h	2010-02-18 07:44:31.000000000 +0100
+@@ -806,7 +806,7 @@
+ #define MAX_PHYS_SEGMENTS 128
+ #define MAX_HW_SEGMENTS 128
+ #define SAFE_MAX_SECTORS 255
+-#define BLK_DEF_MAX_SECTORS 1024
++#define BLK_DEF_MAX_SECTORS 2048
+ 
+ #define MAX_SEGMENT_SIZE	65536
+ 
+diff -u -r debian-2.6.26/include/linux/dcache.h debian-2.6.26_lustre.1.8.2/include/linux/dcache.h
+--- debian-2.6.26/include/linux/dcache.h	2008-07-13 23:51:29.000000000 +0200
++++ debian-2.6.26_lustre.1.8.2/include/linux/dcache.h	2010-02-18 07:46:08.000000000 +0100
+@@ -173,6 +173,7 @@
+ 
+ #define DCACHE_REFERENCED	0x0008  /* Recently used, don't discard. */
+ #define DCACHE_UNHASHED		0x0010	
++#define DCACHE_LUSTRE_INVALID   0x0040  /* Lustre invalidated */
+ 
+ #define DCACHE_INOTIFY_PARENT_WATCHED	0x0020 /* Parent inode is watched */
+ 
+@@ -250,6 +251,7 @@
+  * This adds the entry to the hash queues.
+  */
+ extern void d_rehash(struct dentry *);
++extern void d_rehash_cond(struct dentry *, int lock);
+ 
+ /**
+  * d_add - add dentry to hash queues
+@@ -285,6 +287,7 @@
+ 
+ /* used for rename() and baskets */
+ extern void d_move(struct dentry *, struct dentry *);
++extern void d_move_locked(struct dentry *, struct dentry *);
+ 
+ /* appendix may either be NULL or be used for transname suffixes */
+ extern struct dentry * d_lookup(struct dentry *, struct qstr *);
+diff -u -r debian-2.6.26/include/linux/fs.h debian-2.6.26_lustre.1.8.2/include/linux/fs.h
+--- debian-2.6.26/include/linux/fs.h	2008-07-13 23:51:29.000000000 +0200
++++ debian-2.6.26_lustre.1.8.2/include/linux/fs.h	2010-02-18 07:57:56.000000000 +0100
+@@ -1832,6 +1832,10 @@
+ extern void submit_bio(int, struct bio *);
+ extern int bdev_read_only(struct block_device *);
+ #endif
++#define HAVE_CLEAR_RDONLY_ON_PUT
++extern void dev_set_rdonly(struct block_device *bdev);
++extern int dev_check_rdonly(struct block_device *bdev);
++extern void dev_clear_rdonly(struct block_device *bdev);
+ extern int set_blocksize(struct block_device *, int);
+ extern int sb_set_blocksize(struct super_block *, int);
+ extern int sb_min_blocksize(struct super_block *, int);
+@@ -1930,6 +1934,7 @@
+ 
+ extern const struct file_operations generic_ro_fops;
+ 
++extern rwlock_t file_systems_lock;
+ #define special_file(m) (S_ISCHR(m)||S_ISBLK(m)||S_ISFIFO(m)||S_ISSOCK(m))
+ 
+ extern int vfs_readlink(struct dentry *, char __user *, int, const char *);
+diff -u -r debian-2.6.26/include/linux/jbd2.h debian-2.6.26_lustre.1.8.2/include/linux/jbd2.h
+--- debian-2.6.26/include/linux/jbd2.h	2008-07-13 23:51:29.000000000 +0200
++++ debian-2.6.26_lustre.1.8.2/include/linux/jbd2.h	2010-02-18 08:08:30.000000000 +0100
+@@ -379,6 +379,27 @@
+ 	bit_spin_unlock(BH_JournalHead, &bh->b_state);
+ }
+ 
++#define HAVE_JOURNAL_CALLBACK_STATUS
++/**
++ *   struct journal_callback - Base structure for callback information.
++ *   @jcb_list: list information for other callbacks attached to the same handle.
++ *   @jcb_func: Function to call with this callback structure.
++ *
++ *   This struct is a 'seed' structure for a using with your own callback
++ *   structs. If you are using callbacks you must allocate one of these
++ *   or another struct of your own definition which has this struct
++ *   as it's first element and pass it to journal_callback_set().
++ *
++ *   This is used internally by jbd2 to maintain callback information.
++ *
++ *   See journal_callback_set for more information.
++ **/
++struct journal_callback {
++        struct list_head jcb_list;              /* t_jcb_lock */
++        void (*jcb_func)(struct journal_callback *jcb, int error);
++        /* user data goes here */
++};
++
+ struct jbd2_revoke_table_s;
+ 
+ /**
+@@ -387,6 +408,7 @@
+  * @h_transaction: Which compound transaction is this update a part of?
+  * @h_buffer_credits: Number of remaining buffers we are allowed to dirty.
+  * @h_ref: Reference count on this handle
++ * @h_jcb: List of application registered callbacks for this handle.
+  * @h_err: Field for caller's use to track errors through large fs operations
+  * @h_sync: flag for sync-on-close
+  * @h_jdata: flag to force data journaling
+@@ -412,6 +434,13 @@
+ 	/* operations */
+ 	int			h_err;
+ 
++        /*
++         * List of application registered callbacks for this handle. The
++         * function(s) will be called after the transaction that this handle is
++         * part of has been committed to disk. [t_jcb_lock]
++         */
++        struct list_head        h_jcb;
++
+ 	/* Flags [no locking] */
+ 	unsigned int	h_sync:		1;	/* sync-on-close */
+ 	unsigned int	h_jdata:	1;	/* force data journaling */
+@@ -467,6 +496,9 @@
+  *    j_state_lock
+  *    ->j_list_lock			(journal_unmap_buffer)
+  *
++ *    t_handle_lock
++ *    ->t_jcb_lock
++ *
+  */
+ 
+ struct transaction_s
+@@ -613,6 +645,15 @@
+ 	 */
+ 	int t_handle_count;
+ 
++        /*
++         * Protects the callback list
++         */
++        spinlock_t              t_jcb_lock;
++        /*
++         * List of registered callback functions for this transaction.
++         * Called when the transaction is committed. [t_jcb_lock]
++         */
++        struct list_head        t_jcb;
+ };
+ 
+ struct transaction_run_stats_s {
+@@ -1016,6 +1057,9 @@
+ extern int	 jbd2_journal_flush (journal_t *);
+ extern void	 jbd2_journal_lock_updates (journal_t *);
+ extern void	 jbd2_journal_unlock_updates (journal_t *);
++extern void      jbd2_journal_callback_set(handle_t *handle,
++                                      void (*fn)(struct journal_callback *,int),
++                                      struct journal_callback *jcb);
+ 
+ extern journal_t * jbd2_journal_init_dev(struct block_device *bdev,
+ 				struct block_device *fs_dev,
+diff -u -r debian-2.6.26/include/linux/mm.h debian-2.6.26_lustre.1.8.2/include/linux/mm.h
+--- debian-2.6.26/include/linux/mm.h	2009-12-26 09:14:57.000000000 +0100
++++ debian-2.6.26_lustre.1.8.2/include/linux/mm.h	2010-02-18 08:10:11.000000000 +0100
+@@ -564,6 +564,8 @@
+ {
+ 	return __va(page_to_pfn(page) << PAGE_SHIFT);
+ }
++/* truncate.c */
++extern void truncate_complete_page(struct address_space *mapping,struct page *);
+ 
+ #if defined(CONFIG_HIGHMEM) && !defined(WANT_PAGE_VIRTUAL)
+ #define HASHED_PAGE_VIRTUAL
+diff -u -r debian-2.6.26/include/scsi/sd.h debian-2.6.26_lustre.1.8.2/include/scsi/sd.h
+--- debian-2.6.26/include/scsi/sd.h	2008-07-13 23:51:29.000000000 +0200
++++ debian-2.6.26_lustre.1.8.2/include/scsi/sd.h	2010-02-17 14:18:52.000000000 +0100
+@@ -31,6 +31,47 @@
+  */
+ #define SD_BUF_SIZE		512
+ 
++#if (defined(CONFIG_SD_IOSTATS) && defined(CONFIG_PROC_FS))
++typedef struct {
++        unsigned long long iostat_size;
++        unsigned long long iostat_count;
++} iostat_counter_t;
++
++#define IOSTAT_NCOUNTERS 16
++typedef struct {
++        iostat_counter_t        iostat_read_histogram[IOSTAT_NCOUNTERS];
++        iostat_counter_t        iostat_write_histogram[IOSTAT_NCOUNTERS];
++        struct timeval          iostat_timeval;
++
++        /* queue depth: how well the pipe is filled up */
++        unsigned long long      iostat_queue_ticks[IOSTAT_NCOUNTERS];
++        unsigned long long      iostat_queue_ticks_sum;
++        unsigned long           iostat_queue_depth;
++        unsigned long           iostat_queue_stamp;
++
++        /* seeks: how linear the traffic is */
++        unsigned long long      iostat_next_sector;
++        unsigned long long      iostat_seek_sectors;
++        unsigned long long      iostat_seeks;
++        unsigned long long      iostat_sectors;
++        unsigned long long      iostat_reqs;
++        unsigned long           iostat_read_reqs;
++        unsigned long           iostat_write_reqs;
++
++        /* process time: how long it takes to process requests */
++        unsigned long           iostat_rtime[IOSTAT_NCOUNTERS];
++        unsigned long           iostat_wtime[IOSTAT_NCOUNTERS];
++
++        /* queue time: how long process spent in elevator's queue */
++        unsigned long           iostat_rtime_in_queue[IOSTAT_NCOUNTERS];
++        unsigned long           iostat_wtime_in_queue[IOSTAT_NCOUNTERS];
++
++        /* must be the last field, as it's used to know size to be memset'ed */
++        spinlock_t              iostat_lock;
++} ____cacheline_aligned_in_smp iostat_stats_t;
++#endif
++
++
+ struct scsi_disk {
+ 	struct scsi_driver *driver;	/* always &sd_template */
+ 	struct scsi_device *device;
+@@ -45,6 +86,9 @@
+ 	unsigned	WCE : 1;	/* state of disk WCE bit */
+ 	unsigned	RCD : 1;	/* state of disk RCD bit, unused */
+ 	unsigned	DPOFUA : 1;	/* state of disk DPOFUA bit */
++#if (defined(CONFIG_SD_IOSTATS) && defined(CONFIG_PROC_FS))
++        iostat_stats_t  *stats;         /* scsi disk statistics */
++#endif
+ };
+ #define to_scsi_disk(obj) container_of(obj,struct scsi_disk,dev)
+ 
+diff -u -r debian-2.6.26/kernel/sched.c debian-2.6.26_lustre.1.8.2/kernel/sched.c
+--- debian-2.6.26/kernel/sched.c	2009-12-26 09:14:56.000000000 +0100
++++ debian-2.6.26_lustre.1.8.2/kernel/sched.c	2010-02-18 08:11:02.000000000 +0100
+@@ -5477,6 +5477,7 @@
+ 
+ 	show_stack(p, NULL);
+ }
++EXPORT_SYMBOL(sched_show_task);
+ 
+ void show_state_filter(unsigned long state_filter)
+ {
+diff -u -r debian-2.6.26/mm/truncate.c debian-2.6.26_lustre.1.8.2/mm/truncate.c
+--- debian-2.6.26/mm/truncate.c	2008-07-13 23:51:29.000000000 +0200
++++ debian-2.6.26_lustre.1.8.2/mm/truncate.c	2010-02-18 08:12:58.000000000 +0100
+@@ -92,7 +92,7 @@
+  * its lock, b) when a concurrent invalidate_mapping_pages got there first and
+  * c) when tmpfs swizzles a page between a tmpfs inode and swapper_space.
+  */
+-static void
++void
+ truncate_complete_page(struct address_space *mapping, struct page *page)
+ {
+ 	if (page->mapping != mapping)
+@@ -108,6 +108,7 @@
+ 	ClearPageMappedToDisk(page);
+ 	page_cache_release(page);	/* pagecache ref */
+ }
++EXPORT_SYMBOL_GPL(truncate_complete_page);
+ 
+ /*
+  * This is for invalidate_mapping_pages().  That function can be called at
+diff -u -r debian-2.6.26/security/security.c debian-2.6.26_lustre.1.8.2/security/security.c
+--- debian-2.6.26/security/security.c	2009-12-26 09:14:57.000000000 +0100
++++ debian-2.6.26_lustre.1.8.2/security/security.c	2010-02-18 08:13:38.000000000 +0100
+@@ -406,6 +406,7 @@
+ 		return 0;
+ 	return security_ops->inode_unlink(dir, dentry);
+ }
++EXPORT_SYMBOL(security_inode_unlink);
+ 
+ int security_inode_symlink(struct inode *dir, struct dentry *dentry,
+ 			    const char *old_name)
diff --git a/ldiskfs/kernel_patches/series/ldiskfs-2.6.26-vanilla.series b/ldiskfs/kernel_patches/series/ldiskfs-2.6.26-vanilla.series
new file mode 100644
index 0000000..9ced5da
--- /dev/null
+++ b/ldiskfs/kernel_patches/series/ldiskfs-2.6.26-vanilla.series
@@ -0,0 +1 @@
+debian-2.6.26.diff

-- 
Lustre Debian Packaging 



More information about the Pkg-lustre-svn-commit mailing list