cachefiles: vfs_mkdir() might succeed leaving dentry negative unhashed
authorAl Viro <viro@zeniv.linux.org.uk>
Fri, 11 May 2018 02:59:45 +0000 (22:59 -0400)
committerAl Viro <viro@zeniv.linux.org.uk>
Mon, 21 May 2018 18:30:10 +0000 (14:30 -0400)
commit9c3e9025a3f7ed25c99a0add8af65431c8043800
treed8f892f5750d1aea00dcef9d9f7ea1719f11a6ce
parent7b745a4e4051e1bbce40e0b1c2cf636c70583aa4
cachefiles: vfs_mkdir() might succeed leaving dentry negative unhashed

That can (and does, on some filesystems) happen - ->mkdir() (and thus
vfs_mkdir()) can legitimately leave its argument negative and just
unhash it, counting upon the lookup to pick the object we'd created
next time we try to look at that name.

Some vfs_mkdir() callers forget about that possibility...

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
fs/cachefiles/namei.c