1. 15 5月, 2012 1 次提交
  2. 03 5月, 2012 1 次提交
    • D
      dlm: fixes for nodir mode · 4875647a
      David Teigland 提交于
      The "nodir" mode (statically assign master nodes instead
      of using the resource directory) has always been highly
      experimental, and never seriously used.  This commit
      fixes a number of problems, making nodir much more usable.
      
      - Major change to recovery: recover all locks and restart
        all in-progress operations after recovery.  In some
        cases it's not possible to know which in-progess locks
        to recover, so recover all.  (Most require recovery
        in nodir mode anyway since rehashing changes most
        master nodes.)
      
      - Change the way nodir mode is enabled, from a command
        line mount arg passed through gfs2, into a sysfs
        file managed by dlm_controld, consistent with the
        other config settings.
      
      - Allow recovering MSTCPY locks on an rsb that has not
        yet been turned into a master copy.
      
      - Ignore RCOM_LOCK and RCOM_LOCK_REPLY recovery messages
        from a previous, aborted recovery cycle.  Base this
        on the local recovery status not being in the state
        where any nodes should be sending LOCK messages for the
        current recovery cycle.
      
      - Hold rsb lock around dlm_purge_mstcpy_locks() because it
        may run concurrently with dlm_recover_master_copy().
      
      - Maintain highbast on process-copy lkb's (in addition to
        the master as is usual), because the lkb can switch
        back and forth between being a master and being a
        process copy as the master node changes in recovery.
      
      - When recovering MSTCPY locks, flag rsb's that have
        non-empty convert or waiting queues for granting
        at the end of recovery.  (Rename flag from LOCKS_PURGED
        to RECOVER_GRANT and similar for the recovery function,
        because it's not only resources with purged locks
        that need grant a grant attempt.)
      
      - Replace a couple of unnecessary assertion panics with
        error messages.
      Signed-off-by: NDavid Teigland <teigland@redhat.com>
      4875647a
  3. 27 4月, 2012 5 次提交
  4. 24 4月, 2012 1 次提交
  5. 06 4月, 2012 1 次提交
    • S
      simple_open: automatically convert to simple_open() · 234e3405
      Stephen Boyd 提交于
      Many users of debugfs copy the implementation of default_open() when
      they want to support a custom read/write function op.  This leads to a
      proliferation of the default_open() implementation across the entire
      tree.
      
      Now that the common implementation has been consolidated into libfs we
      can replace all the users of this function with simple_open().
      
      This replacement was done with the following semantic patch:
      
      <smpl>
      @ open @
      identifier open_f != simple_open;
      identifier i, f;
      @@
      -int open_f(struct inode *i, struct file *f)
      -{
      (
      -if (i->i_private)
      -f->private_data = i->i_private;
      |
      -f->private_data = i->i_private;
      )
      -return 0;
      -}
      
      @ has_open depends on open @
      identifier fops;
      identifier open.open_f;
      @@
      struct file_operations fops = {
      ...
      -.open = open_f,
      +.open = simple_open,
      ...
      };
      </smpl>
      
      [akpm@linux-foundation.org: checkpatch fixes]
      Signed-off-by: NStephen Boyd <sboyd@codeaurora.org>
      Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
      Cc: Al Viro <viro@zeniv.linux.org.uk>
      Cc: Julia Lawall <Julia.Lawall@lip6.fr>
      Acked-by: NIngo Molnar <mingo@elte.hu>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      234e3405
  6. 21 3月, 2012 1 次提交
  7. 09 3月, 2012 2 次提交
  8. 04 1月, 2012 3 次提交
    • D
      dlm: add recovery callbacks · 60f98d18
      David Teigland 提交于
      These new callbacks notify the dlm user about lock recovery.
      GFS2, and possibly others, need to be aware of when the dlm
      will be doing lock recovery for a failed lockspace member.
      
      In the past, this coordination has been done between dlm and
      file system daemons in userspace, which then direct their
      kernel counterparts.  These callbacks allow the same
      coordination directly, and more simply.
      Signed-off-by: NDavid Teigland <teigland@redhat.com>
      60f98d18
    • D
      dlm: add node slots and generation · 757a4271
      David Teigland 提交于
      Slot numbers are assigned to nodes when they join the lockspace.
      The slot number chosen is the minimum unused value starting at 1.
      Once a node is assigned a slot, that slot number will not change
      while the node remains a lockspace member.  If the node leaves
      and rejoins it can be assigned a new slot number.
      
      A new generation number is also added to a lockspace.  It is
      set and incremented during each recovery along with the slot
      collection/assignment.
      
      The slot numbers will be passed to gfs2 which will use them as
      journal id's.
      Signed-off-by: NDavid Teigland <teigland@redhat.com>
      757a4271
    • D
      dlm: move recovery barrier calls · f95a34c6
      David Teigland 提交于
      Put all the calls to recovery barriers in the same function
      to clarify where they each happen.  Should not change any behavior.
      Also modify some recovery debug lines to make them consistent.
      Signed-off-by: NDavid Teigland <teigland@redhat.com>
      f95a34c6
  9. 23 11月, 2011 1 次提交
  10. 19 11月, 2011 1 次提交
  11. 21 7月, 2011 1 次提交
    • J
      locks: rename lock-manager ops · 8fb47a4f
      J. Bruce Fields 提交于
      Both the filesystem and the lock manager can associate operations with a
      lock.  Confusingly, one of them (fl_release_private) actually has the
      same name in both operation structures.
      
      It would save some confusion to give the lock-manager ops different
      names.
      Signed-off-by: NJ. Bruce Fields <bfields@redhat.com>
      8fb47a4f
  12. 20 7月, 2011 1 次提交
  13. 16 7月, 2011 1 次提交
  14. 15 7月, 2011 1 次提交
  15. 13 7月, 2011 1 次提交
    • D
      dlm: improve rsb searches · 3881ac04
      David Teigland 提交于
      By pre-allocating rsb structs before searching the hash
      table, they can be inserted immediately.  This avoids
      always having to repeat the search when adding the struct
      to hash list.
      
      This also adds space to the rsb struct for a max resource
      name, so an rsb allocation can be used by any request.
      The constant size also allows us to finally use a slab
      for the rsb structs.
      Signed-off-by: NDavid Teigland <teigland@redhat.com>
      3881ac04
  16. 11 7月, 2011 3 次提交
  17. 07 7月, 2011 1 次提交
  18. 02 7月, 2011 1 次提交
  19. 01 7月, 2011 1 次提交
  20. 26 5月, 2011 1 次提交
    • M
      dlm: Drop __TIME__ usage · 75ce481e
      Michal Marek 提交于
      The kernel already prints its build timestamp during boot, no need to
      repeat it in random drivers and produce different object files each
      time.
      
      Cc: Christine Caulfield <ccaulfie@redhat.com>
      Cc: David Teigland <teigland@redhat.com>
      Cc: cluster-devel@redhat.com
      Signed-off-by: NMichal Marek <mmarek@suse.cz>
      75ce481e
  21. 23 5月, 2011 1 次提交
    • D
      dlm: make plock operation killable · 901025d2
      David Teigland 提交于
      Allow processes blocked on plock requests to be interrupted
      when they are killed.  This leaves the problem of cleaning
      up the lock state in userspace.  This has three parts:
      
      1. Add a flag to unlock operations sent to userspace
      indicating the file is being closed.  Userspace will
      then look for and clear any waiting plock operations that
      were abandoned by an interrupted process.
      
      2. Queue an unlock-close operation (like in 1) to clean up
      userspace from an interrupted plock request.  This is needed
      because the vfs will not send a cleanup-unlock if it sees no
      locks on the file, which it won't if the interrupted operation
      was the only one.
      
      3. Do not use replies from userspace for unlock-close operations
      because they are unnecessary (they are just cleaning up for the
      process which did not make an unlock call).  This also simplifies
      the new unlock-close generated from point 2.
      Signed-off-by: NDavid Teigland <teigland@redhat.com>
      901025d2
  22. 05 4月, 2011 1 次提交
  23. 02 4月, 2011 1 次提交
  24. 31 3月, 2011 1 次提交
  25. 28 3月, 2011 1 次提交
  26. 11 3月, 2011 3 次提交
  27. 12 2月, 2011 1 次提交
  28. 17 1月, 2011 1 次提交
    • N
      dlm: Make DLM depend on CONFIGFS_FS · 86c747d2
      Nicholas Bellinger 提交于
      This patch fixes the following kconfig error after changing
      CONFIGFS_FS -> select SYSFS:
      
      fs/sysfs/Kconfig:1:error: recursive dependency detected!
      fs/sysfs/Kconfig:1:	symbol SYSFS is selected by CONFIGFS_FS
      fs/configfs/Kconfig:1:	symbol CONFIGFS_FS is selected by DLM
      fs/dlm/Kconfig:1:	symbol DLM depends on SYSFS
      Signed-off-by: NNicholas A. Bellinger <nab@linux-iscsi.org>
      Cc: Joel Becker <jlbec@evilplan.org>
      Cc: Randy Dunlap <randy.dunlap@oracle.com>
      Cc: Stephen Rothwell <sfr@canb.auug.org.au>
      Cc: James Bottomley <James.Bottomley@suse.de>
      86c747d2
  29. 14 12月, 2010 1 次提交