On Mon, Aug 21, 2006 at 08:37:38AM -0500, Eric Anderson wrote:
On 08/21/06 08:21, Tor Egge wrote:
The deadlock indicates that one or more of IN_CHANGE, IN_MODIFIED or
IN_UPDATE was set on the inode, indicating a write operation
(e.g. VOP_WRITE(), VOP_RENAME(), VOP_CREATE(), VOP_REMOVE(), VOP_LINK(),
VOP_SYMLINK(), VOP_SETATTR(), VOP_MKDIR(), VOP_RMDIR(), VOP_MKNOD()) that
not protected by vn_start_write() or vn_start_secondary_write().
The most common "write" operation was probably VOP_GETATTR().
ufs_itimes(), called from ufs_getattr(), might set the IN_MODIFIED inode
if IN_ACCESS is set on the inode even if neither IN_CHANGE nor IN_UPDATE is
set, transitioning the inode flags into a state where ufs_inactive() calls
blocking variant of vn_start_secondary_write().
calling ufs_itimes() with only a shared vnode lock might cause unsafe
to the inode flags. Setting of IN_ACCESS at the end of ffs_read() and
ffs_extread() might also be unsafe. If DIRECTIO is enabled then O_DIRECT
might not even attempt to set the IN_ACCESS flag.
Does this mean that setting the noatime flag on mount would dodge this?