• Miklos Szeredi's avatar
    vfs: retry last component if opening stale dentry · 16b1c1cd
    Miklos Szeredi authored
    NFS optimizes away d_revalidates for last component of open.  This means that
    open itself can find the dentry stale.
    
    This patch allows the filesystem to return EOPENSTALE and the VFS will retry the
    lookup on just the last component if possible.
    
    If the lookup was done using RCU mode, including the last component, then this
    is not possible since the parent dentry is lost.  In this case fall back to
    non-RCU lookup.  Currently this is not used since NFS will always leave RCU
    mode.
    Signed-off-by: 's avatarMiklos Szeredi <mszeredi@suse.cz>
    Signed-off-by: 's avatarAl Viro <viro@zeniv.linux.org.uk>
    16b1c1cd
namei.c 86.1 KB