cvs commit: src/sys/ufs/ufs dirhash.h ufs_dirhash.c

Jeff Roberson jeff at FreeBSD.org
Fri Apr 11 09:48:13 UTC 2008


jeff        2008-04-11 09:48:12 UTC

  FreeBSD src repository

  Modified files:
    sys/ufs/ufs          dirhash.h ufs_dirhash.c 
  Log:
   - Use a lockmgr lock rather than a mtx to protect dirhash.  This lock
     may be held for the duration of the various dirhash operations which
     avoids many complex unlock/lock/revalidate sequences.
   - Permit shared locks on lookup.  To protect the ip->i_dirhash pointer we
     use the vnode interlock in the shared case.  Callers holding the
     exclusive vnode lock can run without fear of concurrent modification to
     i_dirhash.
   - Hold an exclusive dirhash lock when creating the dirhash structure for
     the first time or when re-creating a dirhash structure which has been
     recycled.
  
  Tested by:      kris, pho
  
  Revision  Changes    Path
  1.6       +2 -1      src/sys/ufs/ufs/dirhash.h
  1.24      +289 -227  src/sys/ufs/ufs/ufs_dirhash.c


More information about the cvs-src mailing list