kernel_optimize_test/fs
Miklos Szeredi 0ef97dcfce nfs: don't open in ->d_revalidate
NFSv4 can't do reliable opens in d_revalidate, since it cannot know whether a
mount needs to be followed or not.  It does check d_mountpoint() on the dentry,
which can result in a weird error if the VFS found that the mount does not in
fact need to be followed, e.g.:

  # mount --bind /mnt/nfs /mnt/nfs-clone
  # echo something > /mnt/nfs/tmp/bar
  # echo x > /tmp/file
  # mount --bind /tmp/file /mnt/nfs-clone/tmp/bar
  # cat  /mnt/nfs/tmp/bar
  cat: /mnt/nfs/tmp/bar: Not a directory

Which should, by any sane filesystem, result in "something" being printed.

So instead do the open in f_op->open() and in the unlikely case that the cached
dentry turned out to be invalid, drop the dentry and return EOPENSTALE to let
the VFS retry.

Signed-off-by: Miklos Szeredi <mszeredi@suse.cz>
CC: Trond Myklebust <Trond.Myklebust@netapp.com>
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
2012-06-01 12:12:02 -04:00
..
9p kill v9fs_dentry_from_dir_inode() 2012-05-29 23:28:34 -04:00
adfs
affs affs: bury unused macros 2012-05-29 23:28:34 -04:00
afs
autofs4
befs
bfs
btrfs Btrfs: move over to use ->update_time 2012-06-01 12:07:52 -04:00
cachefiles
ceph ceph: move encode_fh to new API 2012-05-29 23:28:33 -04:00
cifs Merge branch 'for-next' of git://git.samba.org/sfrench/cifs-2.6 2012-05-29 12:42:10 -07:00
coda
configfs
cramfs
debugfs
devpts
dlm
ecryptfs get rid of pointless allocations and copying in ecryptfs_follow_link() 2012-05-29 23:28:40 -04:00
efs
exofs
exportfs ->encode_fh() API change 2012-05-29 23:28:33 -04:00
ext2
ext3
ext4
fat ->encode_fh() API change 2012-05-29 23:28:33 -04:00
freevxfs
fscache
fuse fs: introduce inode operation ->update_time 2012-06-01 12:07:25 -04:00
gfs2 ->encode_fh() API change 2012-05-29 23:28:33 -04:00
hfs
hfsplus
hostfs
hpfs hpfs: assorted endianness annotations 2012-05-29 23:28:39 -04:00
hppfs
hugetlbfs
isofs ->encode_fh() API change 2012-05-29 23:28:33 -04:00
jbd
jbd2
jffs2 jffs2: get rid of jffs2_sync_super 2012-05-30 21:04:52 -04:00
jfs
lockd
logfs
minix
ncpfs fs: introduce inode operation ->update_time 2012-06-01 12:07:25 -04:00
nfs nfs: don't open in ->d_revalidate 2012-06-01 12:12:02 -04:00
nfs_common
nfsd
nilfs2 ->encode_fh() API change 2012-05-29 23:28:33 -04:00
nls
notify fsnotify: remove unused parameter from send_to_group() 2012-05-30 21:04:53 -04:00
ntfs fs: introduce inode operation ->update_time 2012-06-01 12:07:25 -04:00
ocfs2 ocfs: simplify symlink handling 2012-05-29 23:28:40 -04:00
omfs
openpromfs
proc
pstore
qnx4
qnx6
quota
ramfs
reiserfs reiserfs: get rid of resierfs_sync_super 2012-06-01 10:37:36 -04:00
romfs
squashfs
sysfs
sysv
ubifs ubifs: use generic_fillattr() 2012-05-29 23:28:32 -04:00
udf ->encode_fh() API change 2012-05-29 23:28:33 -04:00
ufs
xfs fs: introduce inode operation ->update_time 2012-06-01 12:07:25 -04:00
aio.c switch aio and shm to do_mmap_pgoff(), make do_mmap() static 2012-06-01 10:37:17 -04:00
anon_inodes.c
attr.c vfs: increment iversion when a file is truncated 2012-05-30 21:04:53 -04:00
bad_inode.c
binfmt_aout.c
binfmt_elf_fdpic.c
binfmt_elf.c binfmt_elf: switch elf_map() to vm_mmap/vm_munmap 2012-05-30 21:04:55 -04:00
binfmt_em86.c
binfmt_flat.c binfmt_flat: use vm_munmap, we are missing ->mmap_sem there 2012-05-30 21:04:56 -04:00
binfmt_misc.c
binfmt_script.c
binfmt_som.c
bio-integrity.c
bio.c
block_dev.c
buffer.c fs: Move bh_cachep to the __read_mostly section 2012-05-30 21:04:52 -04:00
char_dev.c
compat_binfmt_elf.c
compat_ioctl.c
compat.c switch readdir/getdents to fget_light/fput_light 2012-05-29 23:28:29 -04:00
dcache.c vfs: remove unused __d_splice_alias argument 2012-05-30 21:04:54 -04:00
dcookies.c
direct-io.c
drop_caches.c
eventfd.c
eventpoll.c
exec.c split ->file_mmap() into ->mmap_addr()/->mmap_file() 2012-05-31 13:11:54 -04:00
fcntl.c switch fcntl to fget_raw_light/fput_light 2012-05-29 23:28:30 -04:00
fhandle.c
fifo.c
file_table.c brlocks/lglocks: API cleanups 2012-05-29 23:28:41 -04:00
file.c
filesystems.c
fs_struct.c
fs-writeback.c
generic_acl.c
inode.c fs: introduce inode operation ->update_time 2012-06-01 12:07:25 -04:00
internal.h vfs: split __dentry_open() 2012-06-01 12:12:00 -04:00
ioctl.c
ioprio.c
Kconfig
Kconfig.binfmt
libfs.c
locks.c switch flock to fget_light/fput_light 2012-05-29 23:28:31 -04:00
Makefile
mbcache.c
mount.h
mpage.c
namei.c vfs: retry last component if opening stale dentry 2012-06-01 12:12:01 -04:00
namespace.c vfs: umount_tree() might be called on subtree that had never made it 2012-05-30 21:04:55 -04:00
no-block.c
open.c vfs: nameidata_to_filp(): don't throw away file on error 2012-06-01 12:12:01 -04:00
pipe.c fs: introduce inode operation ->update_time 2012-06-01 12:07:25 -04:00
pnode.c brlocks/lglocks: API cleanups 2012-05-29 23:28:41 -04:00
pnode.h
posix_acl.c
proc_namespace.c brlocks/lglocks: API cleanups 2012-05-29 23:28:41 -04:00
read_write.c
read_write.h
readdir.c switch readdir/getdents to fget_light/fput_light 2012-05-29 23:28:29 -04:00
select.c
seq_file.c
signalfd.c switch signalfd4() to fget_light/fput_light 2012-05-29 23:28:30 -04:00
splice.c fs: introduce inode operation ->update_time 2012-06-01 12:07:25 -04:00
stack.c
stat.c
statfs.c switch statfs to fget_light/fput_light 2012-05-29 23:28:31 -04:00
super.c
sync.c switch do_fsync() to fget_light() 2012-05-29 23:28:29 -04:00
timerfd.c
utimes.c switch utimes() to fget_light/fput_light 2012-05-29 23:28:32 -04:00
xattr_acl.c
xattr.c switch xattr syscalls to fget_light/fput_light 2012-05-29 23:28:30 -04:00