• Al Viro's avatar
    nfsd/create race fixes, infrastructure · 261bca86
    Al Viro authored
    new helpers - insert_inode_locked() and insert_inode_locked4().
    Hash new inode, making sure that there's no such inode in icache
    already.  If there is and it does not end up unhashed (as would
    happen if we have nfsd trying to resolve a bogus fhandle), fail.
    Otherwise insert our inode into hash and succeed.
    
    In either case have i_state set to new+locked; cleanup ends up
    being simpler with such calling conventions.
    Signed-off-by: default avatarAl Viro <viro@zeniv.linux.org.uk>
    261bca86
inode.c 40.1 KB