• William A. Adamson's avatar
    [PATCH] nfs4 lease: add a lock manager copy lock callback · 8f8d338e
    William A. Adamson authored
    The following patches provide an interface to the lease subsystem in the
    current VFS locking code.  NFSv4 delegations and Samba op-locks share most
    architecture features.  The version 4 NFS server delegation implementation
    should use leases to co-ordinate behavior between local, Samba, and NFS
    access.
    
    
    The main design points are
    
    - Seperate the fcntl interface from the file_lock FL_LEASE processing in
      fcntl_setlease, creating __setlease() called by fcntl_setlease()
    
    - Add new lock_manager callbacks to enable lease properties to be set,
      leases to be broken, and leases to be cleaned up: with default callbacks
      preserving the current fcntl_setlease properties.
    
    - Add a new interface, setlease() which also calls __setlease(), and
      remove_lease() for kernel lease managers (e.g.  the v4 NFS server)
    
    
    This patch:
    
    Add a lock manager copy lock callback to locks_copy_lock() so that nfsd can
    set lease properties.
    Signed-off-by: default avatarAndy Adamson <andros@citi.umich.edu>
    Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
    Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
    8f8d338e
locks.c 51.9 KB