[Pkg-lustre-svn-commit] r371 - in /trunk/debian/patches: 00list bug11880-flock-recov.dpatch bug12609-make_group_upcall_default.dpatch bug13632-no_namespace_lock.dpatch bug13696-lru_resize_mount_opts+perf_test.dpatch

pwinnertz-guest at users.alioth.debian.org pwinnertz-guest at users.alioth.debian.org
Fri Oct 12 15:17:59 UTC 2007


Author: pwinnertz-guest
Date: Fri Oct 12 15:17:59 2007
New Revision: 371

URL: http://svn.debian.org/wsvn/pkg-lustre/?sc=1&rev=371
Log:
Make patches work :)

Modified:
    trunk/debian/patches/00list
    trunk/debian/patches/bug11880-flock-recov.dpatch
    trunk/debian/patches/bug12609-make_group_upcall_default.dpatch
    trunk/debian/patches/bug13632-no_namespace_lock.dpatch
    trunk/debian/patches/bug13696-lru_resize_mount_opts+perf_test.dpatch

Modified: trunk/debian/patches/00list
URL: http://svn.debian.org/wsvn/pkg-lustre/trunk/debian/patches/00list?rev=371&op=diff
==============================================================================
--- trunk/debian/patches/00list (original)
+++ trunk/debian/patches/00list Fri Oct 12 15:17:59 2007
@@ -1,6 +1,3 @@
-bash_completion.dpatch
-lustre_manpage.dpatch
-
 # patches
 page-size-undef-fixes.dpatch
 inode-no-i_blksize-2.6.20.dpatch
@@ -13,11 +10,13 @@
 no_default_debugging.dpatch
 no-m64.dpatch
 autogen.sh.dpatch
-tex2pdf.dpatch
 2.6.21-sysctl.dpatch
 bug13438-fix-mballoc-bogus-BUGON.dpatch
 
 # Debian patches
+bash_completion.dpatch
+lustre_manpage.dpatch
+tex2pdf.dpatch
 liblustre-makefile.dpatch
 lustre_config.dpatch
 fix-2.6.15-versioncheck.dpatch
@@ -26,7 +25,7 @@
 #Work needing patches
 #autogen-run.dpatch
 #quota-configure.dpatch
-#bug5491-posix.dpatch
+bug5491-posix.dpatch
 bug11880-flock-recov.dpatch
 bug12411-build_patchless-client-packages.dpatch
 bug12609-make_group_upcall_default.dpatch

Modified: trunk/debian/patches/bug11880-flock-recov.dpatch
URL: http://svn.debian.org/wsvn/pkg-lustre/trunk/debian/patches/bug11880-flock-recov.dpatch?rev=371&op=diff
==============================================================================
--- trunk/debian/patches/bug11880-flock-recov.dpatch (original)
+++ trunk/debian/patches/bug11880-flock-recov.dpatch Fri Oct 12 15:17:59 2007
@@ -5,10 +5,10 @@
 ## DP: Patch from upstream bugzilla (bug 11880)
 
 @DPATCH@
-diff -u -p -r1.13 ldlm_flock.c
---- lustre-1.6.3/lustre/ldlm/ldlm_flock.c	10 Feb 2007 06:31:56 -0000	1.13
-+++ lustre-1.6.3/lustre/ldlm/ldlm_flock.c	13 Jun 2007 03:00:06 -0000
-@@ -88,7 +88,10 @@ ldlm_flock_destroy(struct ldlm_lock *loc
+diff -urNad lustre-1.6.3~/lustre/ldlm/ldlm_flock.c lustre-1.6.3/lustre/ldlm/ldlm_flock.c
+--- lustre-1.6.3~/lustre/ldlm/ldlm_flock.c	2007-10-12 17:12:37.000000000 +0200
++++ lustre-1.6.3/lustre/ldlm/ldlm_flock.c	2007-10-12 17:12:37.000000000 +0200
+@@ -88,7 +88,10 @@
          if (flags == LDLM_FL_WAIT_NOREPROC) {
                  /* client side - set a flag to prevent sending a CANCEL */
                  lock->l_flags |= LDLM_FL_LOCAL_ONLY | LDLM_FL_CBPENDING;
@@ -20,7 +20,7 @@
          }
  
          ldlm_lock_destroy_nolock(lock);
-@@ -137,6 +140,7 @@ ldlm_process_flock_lock(struct ldlm_lock
+@@ -137,6 +140,7 @@
          int local = ns->ns_client;
          int added = (mode == LCK_NL);
          int overlaps = 0;
@@ -28,7 +28,7 @@
          ENTRY;
  
          CDEBUG(D_DLMTRACE, "flags %#x pid %u mode %u start "LPU64" end "LPU64
-@@ -155,6 +159,7 @@ ldlm_process_flock_lock(struct ldlm_lock
+@@ -155,6 +159,7 @@
                  req->l_blocking_ast = ldlm_flock_blocking_ast;
          }
  
@@ -36,34 +36,7 @@
          if ((*flags == LDLM_FL_WAIT_NOREPROC) || (mode == LCK_NL)) {
                  /* This loop determines where this processes locks start
                   * in the resource lr_granted list. */
-@@ -334,15 +339,21 @@ ldlm_process_flock_lock(struct ldlm_lock
-                 /* XXX - if ldlm_lock_new() can sleep we should
-                  * release the ns_lock, allocate the new lock,
-                  * and restart processing this lock. */
--                new2 = ldlm_lock_create(ns, NULL, res->lr_name, LDLM_FLOCK,
-+                if (!new2) {
-+                        unlock_res_and_lock(req);
-+                        new2 = ldlm_lock_create(ns, NULL, res->lr_name, LDLM_FLOCK,
-                                         lock->l_granted_mode, NULL, NULL, NULL,
-                                         NULL, 0);
--                if (!new2) {
--                        ldlm_flock_destroy(req, lock->l_granted_mode, *flags);
--                        *err = -ENOLCK;
--                        RETURN(LDLM_ITER_STOP);
-+                        lock_res_and_lock(req);
-+                        if (!new2) {
-+                                ldlm_flock_destroy(req, lock->l_granted_mode, *flags);
-+                                *err = -ENOLCK;
-+                                RETURN(LDLM_ITER_STOP);
-+                        }
-+                        goto reprocess;
-                 }
- 
-+                splitted = 1;
-                 new2->l_granted_mode = lock->l_granted_mode;
-                 new2->l_policy_data.l_flock.pid =
-                         new->l_policy_data.l_flock.pid;
-@@ -360,8 +371,9 @@ ldlm_process_flock_lock(struct ldlm_lock
+@@ -367,8 +372,9 @@
                                   &new2->l_export->exp_ldlm_data.led_held_locks);
                          spin_unlock(&new2->l_export->exp_ldlm_data.led_lock);
                  }
@@ -75,9 +48,9 @@
  
                  /* insert new2 at lock */
                  ldlm_resource_add_lock(res, ownlocks, new2);
-@@ -369,6 +381,10 @@ ldlm_process_flock_lock(struct ldlm_lock
-                 break;
-         }
+@@ -380,6 +386,10 @@
+         if (splitted == 0 && new2 != NULL)
+                 ldlm_lock_destroy_nolock(new2);
  
 +        /* if new2 is created but never used, destroy it*/
 +        if (splitted == 0 && new2 != NULL)
@@ -86,7 +59,7 @@
          /* At this point we're granting the lock request. */
          req->l_granted_mode = req->l_req_mode;
  
-@@ -398,9 +414,9 @@ restart:
+@@ -409,9 +419,9 @@
                                  ldlm_reprocess_queue(res, &res->lr_waiting,
                                                       &rpc_list);
  
@@ -99,7 +72,7 @@
                                  if (rc == -ERESTART)
                                          GOTO(restart, -ERESTART);
                         }
-@@ -500,7 +516,7 @@ granted:
+@@ -511,7 +521,7 @@
  
          LDLM_DEBUG(lock, "client-side enqueue granted");
          ns = lock->l_resource->lr_namespace;
@@ -108,18 +81,7 @@
  
          /* take lock off the deadlock detection waitq. */
          list_del_init(&lock->l_flock_waitq);
-@@ -524,8 +540,8 @@ granted:
-                         cfs_flock_set_type(getlk, F_UNLCK);
-                 }
-                 cfs_flock_set_pid(getlk, (pid_t)lock->l_policy_data.l_flock.pid);
--                cfs_flock_set_start(getlk, (off_t)lock->l_policy_data.l_flock.start);
--                cfs_flock_set_end(getlk, (off_t)lock->l_policy_data.l_flock.end);
-+                cfs_flock_set_start(getlk, (loff_t)lock->l_policy_data.l_flock.start);
-+                cfs_flock_set_end(getlk, (loff_t)lock->l_policy_data.l_flock.end);
-         } else {
-                 int noreproc = LDLM_FL_WAIT_NOREPROC;
- 
-@@ -535,7 +551,7 @@ granted:
+@@ -546,7 +556,7 @@
                  if (flags == 0)
                          cfs_waitq_signal(&lock->l_waitq);
          }
@@ -128,10 +90,10 @@
          RETURN(0);
  }
  EXPORT_SYMBOL(ldlm_flock_completion_ast);
-diff -u -p -r1.16 ldlm_internal.h
---- ./lustre/ldlm/ldlm_internal.h	10 Feb 2007 06:31:56 -0000	1.16
-+++ ./lustre/ldlm/ldlm_internal.h	13 Jun 2007 03:00:06 -0000
-@@ -26,7 +26,9 @@ ldlm_lock_create(struct ldlm_namespace *
+diff -urNad lustre-1.6.3~/lustre/ldlm/ldlm_internal.h lustre-1.6.3/lustre/ldlm/ldlm_internal.h
+--- lustre-1.6.3~/lustre/ldlm/ldlm_internal.h	2007-10-12 17:12:20.000000000 +0200
++++ lustre-1.6.3/lustre/ldlm/ldlm_internal.h	2007-10-12 17:12:37.000000000 +0200
+@@ -70,7 +70,9 @@
  ldlm_error_t ldlm_lock_enqueue(struct ldlm_namespace *, struct ldlm_lock **,
                                 void *cookie, int *flags);
  void ldlm_lock_addref_internal(struct ldlm_lock *, __u32 mode);
@@ -141,14 +103,10 @@
  void ldlm_add_ast_work_item(struct ldlm_lock *lock, struct ldlm_lock *new,
                                  struct list_head *work_list);
  int ldlm_reprocess_queue(struct ldlm_resource *res, struct list_head *queue,
-Index: ldlm/ldlm_lock.c
-===================================================================
-RCS file: /cvsroot/cfs/lustre-core/ldlm/ldlm_lock.c,v
-retrieving revision 1.159
-diff -u -p -r1.159 ldlm_lock.c
---- lustre-1.6.3/lustre/ldlm/ldlm_lock.c	10 Feb 2007 06:31:56 -0000	1.159
-+++ lustre-1.6.3/lustre/ldlm/ldlm_lock.c	13 Jun 2007 03:00:06 -0000
-@@ -556,15 +556,12 @@ void ldlm_lock_addref_internal(struct ld
+diff -urNad lustre-1.6.3~/lustre/ldlm/ldlm_lock.c lustre-1.6.3/lustre/ldlm/ldlm_lock.c
+--- lustre-1.6.3~/lustre/ldlm/ldlm_lock.c	2007-10-12 17:12:20.000000000 +0200
++++ lustre-1.6.3/lustre/ldlm/ldlm_lock.c	2007-10-12 17:13:40.000000000 +0200
+@@ -578,15 +578,12 @@
          unlock_res_and_lock(lock);
  }
  
@@ -169,27 +127,7 @@
          LDLM_DEBUG(lock, "ldlm_lock_decref(%s)", ldlm_lockname[mode]);
          if (mode & (LCK_NL | LCK_CR | LCK_PR)) {
                  LASSERT(lock->l_readers > 0);
-@@ -575,6 +572,19 @@ void ldlm_lock_decref_internal(struct ld
-                 lock->l_writers--;
-         }
- 
-+        LDLM_LOCK_PUT(lock);    /* matches the ldlm_lock_get in addref */
-+}
-+void ldlm_lock_decref_internal(struct ldlm_lock *lock, __u32 mode)
-+{
-+        struct ldlm_namespace *ns;
-+        ENTRY;
-+
-+        lock_res_and_lock(lock);
-+
-+        ns = lock->l_resource->lr_namespace;
-+
-+        ldlm_lock_decref_internal_nolock(lock, mode);
-+
-         if (lock->l_flags & LDLM_FL_LOCAL &&
-             !lock->l_readers && !lock->l_writers) {
-                 /* If this is a local lock on a server namespace and this was
-@@ -616,8 +626,6 @@ void ldlm_lock_decref_internal(struct ld
+@@ -652,8 +649,6 @@
                  unlock_res_and_lock(lock);
          }
  
@@ -197,3 +135,4 @@
 -
          EXIT;
  }
+ 

Modified: trunk/debian/patches/bug12609-make_group_upcall_default.dpatch
URL: http://svn.debian.org/wsvn/pkg-lustre/trunk/debian/patches/bug12609-make_group_upcall_default.dpatch?rev=371&op=diff
==============================================================================
--- trunk/debian/patches/bug12609-make_group_upcall_default.dpatch (original)
+++ trunk/debian/patches/bug12609-make_group_upcall_default.dpatch Fri Oct 12 15:17:59 2007
@@ -65,22 +65,6 @@
 --- lustre-1.6.3/lustre/tests/cfg/local.sh	23 Mar 2007 15:23:57 -0000	1.17
 +++ lustre-1.6.3/lustre/tests/cfg/local.sh	20 Sep 2007 03:25:50 -0000
 @@ -45,6 +45,8 @@ MOUNTOPT=""
-     MOUNTOPT=$MOUNTOPT" --param lov.stripesize=$STRIPE_BYTES"
- [ "x$STRIPES_PER_OBJ" != "x" ] &&
-     MOUNTOPT=$MOUNTOPT" --param lov.stripecount=$STRIPES_PER_OBJ"
-+[ "x$LUSTRE" != "x" ] &&
-+    MOUNTOPT=$MOUNTOPT" --param mdt.group_upcall=$LUSTRE/utils/l_getgroups"
- MDS_MKFS_OPTS="--mgs --mdt --fsname=$FSNAME --device-size=$MDSSIZE --param sys.timeout=$TIMEOUT $MKFSOPT $MOUNTOPT $MDSOPT"
- 
- MKFSOPT=""
-Index: lustre/tests/cfg/lov.sh
-===================================================================
-RCS file: /cvsroot/cfs/lustre-core/tests/cfg/lov.sh,v
-retrieving revision 1.2
-diff -u -p -r1.2 lov.sh
---- lustre-1.6.3/lustre/tests/cfg/lov.sh	10 Feb 2007 06:33:30 -0000	1.2
-+++ lustre-1.6.3/lustre/tests/cfg/lov.sh	20 Sep 2007 03:25:50 -0000
-@@ -39,6 +39,8 @@ MOUNTOPT=""
      MOUNTOPT=$MOUNTOPT" --param lov.stripesize=$STRIPE_BYTES"
  [ "x$STRIPES_PER_OBJ" != "x" ] &&
      MOUNTOPT=$MOUNTOPT" --param lov.stripecount=$STRIPES_PER_OBJ"

Modified: trunk/debian/patches/bug13632-no_namespace_lock.dpatch
URL: http://svn.debian.org/wsvn/pkg-lustre/trunk/debian/patches/bug13632-no_namespace_lock.dpatch?rev=371&op=diff
==============================================================================
--- trunk/debian/patches/bug13632-no_namespace_lock.dpatch (original)
+++ trunk/debian/patches/bug13632-no_namespace_lock.dpatch Fri Oct 12 15:17:59 2007
@@ -5,14 +5,10 @@
 ## DP: Patch from upstream bugzilla (bug13632)
 
 @DPATCH@
-Index: include/lustre_dlm.h
-===================================================================
-RCS file: /cvsroot/cfs/lustre-core/include/lustre_dlm.h,v
-retrieving revision 1.3.6.8
-diff -u -p -r1.3.6.8 lustre_dlm.h
---- lustre-1.6.3/lustre/include/lustre_dlm.h	15 Sep 2007 13:01:54 -0000	1.3.6.8
-+++ lustre-1.6.3/lustre/include/lustre_dlm.h	19 Sep 2007 07:19:39 -0000
-@@ -654,6 +654,12 @@ struct ldlm_namespace *ldlm_namespace_ne
+diff -urNad lustre-1.6.3~/lustre/include/lustre_dlm.h lustre-1.6.3/lustre/include/lustre_dlm.h
+--- lustre-1.6.3~/lustre/include/lustre_dlm.h	2007-10-12 16:52:07.000000000 +0200
++++ lustre-1.6.3/lustre/include/lustre_dlm.h	2007-10-12 16:52:18.000000000 +0200
+@@ -635,6 +635,12 @@
                                            ldlm_appetite_t apt);
  int ldlm_namespace_cleanup(struct ldlm_namespace *ns, int flags);
  int ldlm_namespace_free(struct ldlm_namespace *ns, int force);
@@ -25,14 +21,10 @@
  int ldlm_proc_setup(void);
  #ifdef LPROCFS
  void ldlm_proc_cleanup(void);
-Index: ldlm/ldlm_pool.c
-===================================================================
-RCS file: /cvsroot/cfs/lustre-core/ldlm/Attic/ldlm_pool.c,v
-retrieving revision 1.1.14.5
-diff -u -p -r1.1.14.5 ldlm_pool.c
---- lustre-1.6.3/lustre/ldlm/ldlm_pool.c	14 Sep 2007 16:14:11 -0000	1.1.14.5
-+++ lustre-1.6.3/lustre/ldlm/ldlm_pool.c	19 Sep 2007 07:19:40 -0000
-@@ -723,8 +723,8 @@ EXPORT_SYMBOL(ldlm_pools_wakeup);
+diff -urNad lustre-1.6.3~/lustre/ldlm/ldlm_pool.c lustre-1.6.3/lustre/ldlm/ldlm_pool.c
+--- lustre-1.6.3~/lustre/ldlm/ldlm_pool.c	2007-10-12 16:52:07.000000000 +0200
++++ lustre-1.6.3/lustre/ldlm/ldlm_pool.c	2007-10-12 16:59:25.000000000 +0200
+@@ -723,37 +723,53 @@
  static int ldlm_pools_shrink(ldlm_side_t client, int nr, 
                               unsigned int gfp_mask)
  {
@@ -42,21 +34,23 @@
  
          if (nr != 0 && !(gfp_mask & __GFP_FS))
                  return -1;
-@@ -732,28 +732,42 @@ static int ldlm_pools_shrink(ldlm_side_t
+ 
          CDEBUG(D_DLMTRACE, "request to shrink %d %s locks from all pools\n",
                 nr, client == LDLM_NAMESPACE_CLIENT ? "client" : "server");
- 
+-
 -        if (down_trylock(ldlm_namespace_lock(client)))
 -                return nr != 0 ? -1 : 0;
 -
++        
 +        /* Find out how many resources we may release. */
 +        mutex_down(ldlm_namespace_lock(client));
          list_for_each_entry(ns, ldlm_namespace_list(client), ns_list_chain)
                  total += ldlm_pool_granted(&ns->ns_pool);
 +        mutex_up(ldlm_namespace_lock(client));
  
--        if (nr == 0) {
+-        if (nr == 0 || total == 0) {
 -                mutex_up(ldlm_namespace_lock(client));
++
 +        if (nr == 0)
                  return total;
 -        }
@@ -66,7 +60,7 @@
 -                struct ldlm_pool *pl = &ns->ns_pool;
 +        /* Shrink at least ldlm_namespace_nr(client) namespaces. */
 +        for (nr_ns = atomic_read(ldlm_namespace_nr(client)); 
-+             nr_ns > 0; nr_ns--) 
++            nr_ns > 0; nr_ns--) 
 +        {
                  int cancel, nr_locks;
  
@@ -84,19 +78,20 @@
 +                ldlm_namespace_get(ns);
 +                ldlm_namespace_move(ns, client);
 +                mutex_up(ldlm_namespace_lock(client));
-+                
++
                  nr_locks = ldlm_pool_granted(&ns->ns_pool);
                  cancel = 1 + nr_locks * nr / total;
 -                ldlm_pool_shrink(pl, cancel, gfp_mask);
 +                ldlm_pool_shrink(&ns->ns_pool, cancel, gfp_mask);
                  cached += ldlm_pool_granted(&ns->ns_pool);
 +                ldlm_namespace_put(ns, 1);
++
          }
 -        mutex_up(ldlm_namespace_lock(client));
          return cached;
  }
  
-@@ -771,7 +785,7 @@ void ldlm_pools_recalc(ldlm_side_t clien
+@@ -771,7 +787,7 @@
  {
          __u32 nr_l = 0, nr_p = 0, l;
          struct ldlm_namespace *ns;
@@ -105,7 +100,7 @@
  
          /* Check all modest namespaces. */
          mutex_down(ldlm_namespace_lock(client));
-@@ -791,15 +805,9 @@ void ldlm_pools_recalc(ldlm_side_t clien
+@@ -791,15 +807,9 @@
                          nr_l += l;
                          nr_p++;
                  }
@@ -122,7 +117,7 @@
          if (nr_l >= 2 * (LDLM_POOL_HOST_L / 3)) {
                  CWARN("Modest pools eat out 2/3 of locks limit. %d of %lu. "
                        "Upgrade server!\n", nr_l, LDLM_POOL_HOST_L);
-@@ -827,14 +835,34 @@ void ldlm_pools_recalc(ldlm_side_t clien
+@@ -827,14 +837,34 @@
                          }
                          ldlm_pool_setup(&ns->ns_pool, l);
                  }
@@ -158,14 +153,10 @@
  }
  EXPORT_SYMBOL(ldlm_pools_recalc);
  
-Index: ldlm/ldlm_resource.c
-===================================================================
-RCS file: /cvsroot/cfs/lustre-core/ldlm/ldlm_resource.c,v
-retrieving revision 1.99.32.10
-diff -u -p -r1.99.32.10 ldlm_resource.c
---- lustre-1.6.3/lustre/ldlm/ldlm_resource.c	15 Sep 2007 13:01:54 -0000	1.99.32.10
-+++ lustre-1.6.3/lustre/ldlm/ldlm_resource.c	19 Sep 2007 07:19:46 -0000
-@@ -557,6 +557,51 @@ int ldlm_namespace_free(struct ldlm_name
+diff -urNad lustre-1.6.3~/lustre/ldlm/ldlm_resource.c lustre-1.6.3/lustre/ldlm/ldlm_resource.c
+--- lustre-1.6.3~/lustre/ldlm/ldlm_resource.c	2007-10-12 16:52:07.000000000 +0200
++++ lustre-1.6.3/lustre/ldlm/ldlm_resource.c	2007-10-12 16:52:18.000000000 +0200
+@@ -533,6 +533,51 @@
          return ELDLM_OK;
  }
  
@@ -217,7 +208,7 @@
  static __u32 ldlm_hash_fn(struct ldlm_resource *parent, struct ldlm_res_id name)
  {
          __u32 hash = 0;
-@@ -655,7 +700,7 @@ ldlm_resource_add(struct ldlm_namespace 
+@@ -631,7 +676,7 @@
          bucket = ns->ns_hash + hash;
          list_add(&res->lr_hash, bucket);
          ns->ns_resources++;
@@ -226,7 +217,7 @@
  
          if (parent == NULL) {
                  list_add(&res->lr_childof, &ns->ns_root_list);
-@@ -752,7 +797,9 @@ void __ldlm_resource_putref_final(struct
+@@ -728,7 +773,9 @@
                  LBUG();
          }
  

Modified: trunk/debian/patches/bug13696-lru_resize_mount_opts+perf_test.dpatch
URL: http://svn.debian.org/wsvn/pkg-lustre/trunk/debian/patches/bug13696-lru_resize_mount_opts%2Bperf_test.dpatch?rev=371&op=diff
==============================================================================
--- trunk/debian/patches/bug13696-lru_resize_mount_opts+perf_test.dpatch (original)
+++ trunk/debian/patches/bug13696-lru_resize_mount_opts+perf_test.dpatch Fri Oct 12 15:17:59 2007
@@ -5,30 +5,23 @@
 ## DP: Patch from upstream bugzilla (bug13696)
 
 @DPATCH@
-Index: llite/llite_internal.h
-===================================================================
-RCS file: /cvsroot/cfs/lustre-core/llite/llite_internal.h,v
-retrieving revision 1.68.2.13
-diff -u -p -r1.68.2.13 llite_internal.h
---- lustre-1.6.3/lustre/llite/llite_internal.h	19 Sep 2007 20:22:25 -0000	1.68.2.13
-+++ lustre-1.6.3/lustre/llite/llite_internal.h	23 Sep 2007 12:15:11 -0000
-@@ -215,6 +215,7 @@ enum stats_track_type {
- #define LL_SBI_ACL              0x10 /* support ACL */
+diff -urNad lustre-1.6.3~/lustre/llite/llite_internal.h lustre-1.6.3/lustre/llite/llite_internal.h
+--- lustre-1.6.3~/lustre/llite/llite_internal.h	2007-10-12 17:00:55.000000000 +0200
++++ lustre-1.6.3/lustre/llite/llite_internal.h	2007-10-12 17:03:30.000000000 +0200
+@@ -213,6 +213,8 @@
  #define LL_SBI_JOIN             0x20 /* support JOIN */
  #define LL_SBI_LOCALFLOCK       0x40 /* Local flocks support by kernel */
+ #define LL_SBI_LLITE_CHECKSUM  0x100 /* checksum each page in memory */
 +#define LL_SBI_LRU_RESIZE       0x80 /* support lru resize */
++
  
- /* default value for ll_sb_info->contention_time */
- #define SBI_DEFAULT_CONTENTION_SECONDS     60
-Index: llite/llite_lib.c
-===================================================================
-RCS file: /cvsroot/cfs/lustre-core/llite/llite_lib.c,v
-retrieving revision 1.134.2.30
-diff -u -p -r1.134.2.30 llite_lib.c
---- lustre-1.6.3/lustre/llite/llite_lib.c	14 Sep 2007 21:58:43 -0000	1.134.2.30
-+++ lustre-1.6.3/lustre/llite/llite_lib.c	23 Sep 2007 12:15:11 -0000
-@@ -90,6 +90,10 @@ static struct ll_sb_info *ll_init_sbi(vo
-         sbi->ll_flags |= LL_SBI_CHECKSUM;
+ struct ll_sb_info {
+         struct list_head          ll_list;
+diff -urNad lustre-1.6.3~/lustre/llite/llite_lib.c lustre-1.6.3/lustre/llite/llite_lib.c
+--- lustre-1.6.3~/lustre/llite/llite_lib.c	2007-10-12 17:00:55.000000000 +0200
++++ lustre-1.6.3/lustre/llite/llite_lib.c	2007-10-12 17:01:14.000000000 +0200
+@@ -93,6 +93,10 @@
+         sbi->ll_flags |= LL_SBI_LLITE_CHECKSUM;
  #endif
  
 +#ifdef HAVE_LRU_RESIZE_SUPPORT
@@ -38,9 +31,9 @@
  #ifdef HAVE_EXPORT___IGET
          INIT_LIST_HEAD(&sbi->ll_deathrow);
          spin_lock_init(&sbi->ll_deathrow_lock);
-@@ -163,7 +167,8 @@ static int client_common_fill_super(stru
+@@ -166,7 +170,8 @@
                  OBD_CONNECT_JOIN | OBD_CONNECT_ATTRFID | OBD_CONNECT_NODEVOH |
-                 OBD_CONNECT_CANCELSET | OBD_CONNECT_AT;
+                 OBD_CONNECT_CANCELSET;
  #ifdef HAVE_LRU_RESIZE_SUPPORT
 -        data->ocd_connect_flags |= OBD_CONNECT_LRU_RESIZE;
 +        if (sbi->ll_flags & LL_SBI_LRU_RESIZE)
@@ -48,9 +41,9 @@
  #endif
  #ifdef CONFIG_FS_POSIX_ACL
          data->ocd_connect_flags |= OBD_CONNECT_ACL;
-@@ -267,7 +272,8 @@ static int client_common_fill_super(stru
-                 OBD_CONNECT_SRVLOCK | OBD_CONNECT_CANCELSET | OBD_CONNECT_AT;
- 
+@@ -269,7 +274,8 @@
+                 OBD_CONNECT_REQPORTAL | OBD_CONNECT_BRW_SIZE | 
+                 OBD_CONNECT_CANCELSET;
  #ifdef HAVE_LRU_RESIZE_SUPPORT
 -        data->ocd_connect_flags |= OBD_CONNECT_LRU_RESIZE;
 +        if (sbi->ll_flags & LL_SBI_LRU_RESIZE)
@@ -58,7 +51,7 @@
  #endif
  
          CDEBUG(D_RPCTRACE, "ocd_connect_flags: "LPX64" ocd_version: %d "
-@@ -714,6 +720,16 @@ static int ll_options(char *options, int
+@@ -717,6 +723,16 @@
                          goto next;
                  }
  
@@ -75,44 +68,21 @@
                  LCONSOLE_ERROR_MSG(0x152, "Unknown option '%s', won't mount.\n",
                                     s1);
                  RETURN(-EINVAL);
-Index: tests/sanity.sh
-===================================================================
-RCS file: /cvsroot/cfs/lustre-core/tests/sanity.sh,v
-retrieving revision 1.100.6.54
-diff -u -p -r1.100.6.54 sanity.sh
---- lustre-1.6.3/lustre/tests/sanity.sh	20 Sep 2007 12:15:45 -0000	1.100.6.54
-+++ lustre-1.6.3/lustre/tests/sanity.sh	23 Sep 2007 12:15:14 -0000
-@@ -4231,7 +4231,7 @@ lru_resize_test_init()
- 	return 0
+diff -urNad lustre-1.6.3~/lustre/tests/sanity.sh lustre-1.6.3/lustre/tests/sanity.sh
+--- lustre-1.6.3~/lustre/tests/sanity.sh	2007-10-12 17:01:13.000000000 +0200
++++ lustre-1.6.3/lustre/tests/sanity.sh	2007-10-12 17:09:00.000000000 +0200
+@@ -4225,7 +4225,7 @@
  }
+ run_test 123 "verify statahead work"
  
 -test_124() {
 +test_124a() {
-         lru_resize_test_init || return 0
-         cleanup -f || error "failed to unmount"
-         setup
-@@ -4244,7 +4244,7 @@ test_124() {
-         disable_pool_shrink mdc
- 
-         NR=2000
--        mkdir $DIR/$tdir
-+        mkdir $DIR/$tdir > /dev/null 2>&1
- 
-         LRU_SIZE=`cat $NSDIR/lru_size`
- 
-@@ -4283,15 +4283,63 @@ enough to cancel $LRU_SIZE_B lock(s)"
-         [ $LRU_SIZE_B -ge $LRU_SIZE_A ] || {
-                 error "No locks dropped in "$((SLEEP+SLEEP_ADD))"s. LRU size: $LRU_SIZE_A"
-                 lru_resize_enable
-+                unlinkmany $DIR/$tdir/f $NR
-                 return
-         }
- 
-         log "Dropped "$((LRU_SIZE_B-LRU_SIZE_A))" locks in "$((SLEEP+SLEEP_ADD))"s"
-         lru_resize_enable
+ 	[ -z "`grep lru_resize $LPROC/mdc/*/connect_flags`" ] && \
+                skip "no lru resize on server" && return 0
+         cancel_lru_locks mdc
+@@ -4290,7 +4290,54 @@
          log "unlink $NR files at $DIR/$tdir"
--        unlinkmany $DIR/$tdir/f $NR > /dev/null 2>&1
-+        unlinkmany $DIR/$tdir/f $NR
+         unlinkmany $DIR/$tdir/f $NR
  }
 -run_test 124 "lru resize ======================================="
 +run_test 124a "lru resize ======================================="
@@ -164,5 +134,5 @@
 +}
 +run_test 124b "lru resize (performance test) ======================="
  
- test_125() { # 13358
- 	mkdir -p $DIR/d125 || error "mkdir failed"
+ TMPDIR=$OLDTMPDIR
+ TMP=$OLDTMP




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