Whamcloud - gitweb
Add llite file flag to allow skipping the locking for file read/write ops.
authoradilger <adilger>
Mon, 3 Jun 2002 22:18:57 +0000 (22:18 +0000)
committeradilger <adilger>
Mon, 3 Jun 2002 22:18:57 +0000 (22:18 +0000)
commitdcbdb7dab02f7057df5d4957f62c0eeac95da617
treeff915687265bbef554a6487750be7ca761090037
parent0cc869934a2649250c3ebd5096043868f216f81e
Add llite file flag to allow skipping the locking for file read/write ops.

The ioctl LL_IOC_SETFLAGS and LL_IOC_CLRFLAGS can be used to set and clear
the LL_FILE_IGNORE_LOCK flag on a file, and LL_IOC_GETFLAGS can be used to
retrieve the current flags value.  These values are defined in lustre_lite.h.

Also add a small optimization - we do not update the file atime on reads if
it would not change the actual atime value (i.e. do not update this field
more often than once per second).  We also avoid updating the atime on R/O
mounted filesystems or if the "noatime" mount option is used.
lustre/include/linux/lustre_lite.h
lustre/llite/file.c