20 Jul, 2011

1 commit


16 Jul, 2011

1 commit

  • Instead of creating our own kthread (dlm_astd) to deliver
    callbacks for all lockspaces, use a per-lockspace workqueue
    to deliver the callbacks. This eliminates complications and
    slowdowns from many lockspaces sharing the same thread.

    Signed-off-by: David Teigland

    David Teigland
     

11 Mar, 2011

1 commit

  • Change how callbacks are recorded for locks. Previously, information
    about multiple callbacks was combined into a couple of variables that
    indicated what the end result should be. In some situations, we
    could not tell from this combined state what the exact sequence of
    callbacks were, and would end up either delivering the callbacks in
    the wrong order, or suppress redundant callbacks incorrectly. This
    new approach records all the data for each callback, leaving no
    uncertainty about what needs to be delivered.

    Signed-off-by: David Teigland

    David Teigland
     

25 Feb, 2010

1 commit

  • When both blocking and completion callbacks are queued for lock,
    the dlm would always deliver the completion callback (cast) first.
    In some cases the blocking callback (bast) is queued before the
    cast, though, and should be delivered first. This patch keeps
    track of the order in which they were queued and delivers them
    in that order.

    This patch also keeps track of the granted mode in the last cast
    and eliminates the following bast if the bast mode is compatible
    with the preceding cast mode. This happens when a remotely mastered
    lock is demoted, e.g. EX->NL, in which case the local node queues
    a cast immediately after sending the demote message. In this way
    a cast can be queued for a mode, e.g. NL, that makes an in-transit
    bast extraneous.

    Signed-off-by: David Teigland

    David Teigland
     

24 Dec, 2008

4 commits

  • fs/dlm/ast.c: In function 'dlm_astd':
    fs/dlm/ast.c:64: warning: 'bastmode' may be used uninitialized in this function

    Cleans code up.

    Signed-off-by: Andrew Morton
    Signed-off-by: David Teigland

    Andrew Morton
     
  • The lkb bastmode value is set in the context of processing the
    lock, and read by the dlm_astd thread. Because it's accessed
    in these two separate contexts, the writing/reading ought to
    be done under a lock. This is simple to do by setting it and
    reading it when the lkb is added to and removed from dlm_astd's
    callback list which is properly locked.

    Signed-off-by: David Teigland

    David Teigland
     
  • Just before delivering a blocking callback (bast), the dlm_astd
    thread checks again that the granted mode of the lkb actually
    blocks the mode requested by the bast. The idea behind this was
    originally that the granted mode may have changed since the bast
    was queued, making the callback now unnecessary. Reasons for
    removing this extra check are:
    - dlm_astd doesn't lock the rsb before reading the lkb grmode, so
    it's not technically safe (this removes the long standing FIXME)
    - after running some tests, it doesn't appear the check ever actually
    eliminates a bast
    - delivering an unnecessary blocking callback isn't a bad thing and
    can happen anyway

    Signed-off-by: David Teigland

    David Teigland
     
  • This is a one-liner to use cond_resched() rather than schedule()
    in the ast delivery loop. It should not be necessary to schedule
    every time, so this will save some cpu time while continuing to
    allow scheduling when required.

    Signed-off-by: Steven Whitehouse
    Signed-off-by: David Teigland

    Steven Whitehouse
     

06 Feb, 2008

1 commit


01 May, 2007

1 commit


24 Aug, 2006

1 commit

  • The down-conversion optimization was resulting in the lkb flags being
    cleared because the stub message reply had no flags value set. Copy the
    current flags into the stub message so they'll be copied back into the lkb
    as part of processing the fake reply. Also add an assertion to catch this
    error more directly if it exists elsewhere.

    Signed-off-by: David Teigland
    Signed-off-by: Steven Whitehouse

    David Teigland
     

13 Jul, 2006

1 commit

  • This changes the way the dlm handles user locks. The core dlm is now
    aware of user locks so they can be dealt with more efficiently. There is
    no more dlm_device module which previously managed its own duplicate copy
    of every user lock.

    Signed-off-by: Patrick Caulfield
    Signed-off-by: David Teigland
    Signed-off-by: Steven Whitehouse

    David Teigland
     

20 Jan, 2006

1 commit


18 Jan, 2006

1 commit

  • This is the core of the distributed lock manager which is required
    to use GFS2 as a cluster filesystem. It is also used by CLVM and
    can be used as a standalone lock manager independantly of either
    of these two projects.

    It implements VAX-style locking modes.

    Signed-off-by: David Teigland
    Signed-off-by: Steve Whitehouse

    David Teigland