diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2015-04-26 18:48:49 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2015-04-26 20:22:07 -0400 |
commit | 9ec3a646fe09970f801ab15e0f1694060b9f19af (patch) | |
tree | 697058ca7e1671eda180a3ccc62445686fbc1a31 /fs/nfs/inode.c | |
parent | c8b3fd0ce313443731e8fd6d5a541085eb465f99 (diff) | |
parent | 3cab989afd8d8d1bc3d99fef0e7ed87c31e7b647 (diff) |
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs
Pull fourth vfs update from Al Viro:
"d_inode() annotations from David Howells (sat in for-next since before
the beginning of merge window) + four assorted fixes"
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs:
RCU pathwalk breakage when running into a symlink overmounting something
fix I_DIO_WAKEUP definition
direct-io: only inc/dec inode->i_dio_count for file systems
fs/9p: fix readdir()
VFS: assorted d_backing_inode() annotations
VFS: fs/inode.c helpers: d_inode() annotations
VFS: fs/cachefiles: d_backing_inode() annotations
VFS: fs library helpers: d_inode() annotations
VFS: assorted weird filesystems: d_inode() annotations
VFS: normal filesystems (and lustre): d_inode() annotations
VFS: security/: d_inode() annotations
VFS: security/: d_backing_inode() annotations
VFS: net/: d_inode() annotations
VFS: net/unix: d_backing_inode() annotations
VFS: kernel/: d_inode() annotations
VFS: audit: d_backing_inode() annotations
VFS: Fix up some ->d_inode accesses in the chelsio driver
VFS: Cachefiles should perform fs modifications on the top layer only
VFS: AF_UNIX sockets should call mknod on the top layer only
Diffstat (limited to 'fs/nfs/inode.c')
-rw-r--r-- | fs/nfs/inode.c | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/fs/nfs/inode.c b/fs/nfs/inode.c index d42dff6d5e98..3689e95da79a 100644 --- a/fs/nfs/inode.c +++ b/fs/nfs/inode.c | |||
@@ -495,7 +495,7 @@ EXPORT_SYMBOL_GPL(nfs_fhget); | |||
495 | int | 495 | int |
496 | nfs_setattr(struct dentry *dentry, struct iattr *attr) | 496 | nfs_setattr(struct dentry *dentry, struct iattr *attr) |
497 | { | 497 | { |
498 | struct inode *inode = dentry->d_inode; | 498 | struct inode *inode = d_inode(dentry); |
499 | struct nfs_fattr *fattr; | 499 | struct nfs_fattr *fattr; |
500 | int error = -ENOMEM; | 500 | int error = -ENOMEM; |
501 | 501 | ||
@@ -621,7 +621,7 @@ static void nfs_request_parent_use_readdirplus(struct dentry *dentry) | |||
621 | struct dentry *parent; | 621 | struct dentry *parent; |
622 | 622 | ||
623 | parent = dget_parent(dentry); | 623 | parent = dget_parent(dentry); |
624 | nfs_force_use_readdirplus(parent->d_inode); | 624 | nfs_force_use_readdirplus(d_inode(parent)); |
625 | dput(parent); | 625 | dput(parent); |
626 | } | 626 | } |
627 | 627 | ||
@@ -637,7 +637,7 @@ static bool nfs_need_revalidate_inode(struct inode *inode) | |||
637 | 637 | ||
638 | int nfs_getattr(struct vfsmount *mnt, struct dentry *dentry, struct kstat *stat) | 638 | int nfs_getattr(struct vfsmount *mnt, struct dentry *dentry, struct kstat *stat) |
639 | { | 639 | { |
640 | struct inode *inode = dentry->d_inode; | 640 | struct inode *inode = d_inode(dentry); |
641 | int need_atime = NFS_I(inode)->cache_validity & NFS_INO_INVALID_ATIME; | 641 | int need_atime = NFS_I(inode)->cache_validity & NFS_INO_INVALID_ATIME; |
642 | int err = 0; | 642 | int err = 0; |
643 | 643 | ||
@@ -708,7 +708,7 @@ static struct nfs_lock_context *__nfs_find_lock_context(struct nfs_open_context | |||
708 | struct nfs_lock_context *nfs_get_lock_context(struct nfs_open_context *ctx) | 708 | struct nfs_lock_context *nfs_get_lock_context(struct nfs_open_context *ctx) |
709 | { | 709 | { |
710 | struct nfs_lock_context *res, *new = NULL; | 710 | struct nfs_lock_context *res, *new = NULL; |
711 | struct inode *inode = ctx->dentry->d_inode; | 711 | struct inode *inode = d_inode(ctx->dentry); |
712 | 712 | ||
713 | spin_lock(&inode->i_lock); | 713 | spin_lock(&inode->i_lock); |
714 | res = __nfs_find_lock_context(ctx); | 714 | res = __nfs_find_lock_context(ctx); |
@@ -736,7 +736,7 @@ EXPORT_SYMBOL_GPL(nfs_get_lock_context); | |||
736 | void nfs_put_lock_context(struct nfs_lock_context *l_ctx) | 736 | void nfs_put_lock_context(struct nfs_lock_context *l_ctx) |
737 | { | 737 | { |
738 | struct nfs_open_context *ctx = l_ctx->open_context; | 738 | struct nfs_open_context *ctx = l_ctx->open_context; |
739 | struct inode *inode = ctx->dentry->d_inode; | 739 | struct inode *inode = d_inode(ctx->dentry); |
740 | 740 | ||
741 | if (!atomic_dec_and_lock(&l_ctx->count, &inode->i_lock)) | 741 | if (!atomic_dec_and_lock(&l_ctx->count, &inode->i_lock)) |
742 | return; | 742 | return; |
@@ -763,7 +763,7 @@ void nfs_close_context(struct nfs_open_context *ctx, int is_sync) | |||
763 | return; | 763 | return; |
764 | if (!is_sync) | 764 | if (!is_sync) |
765 | return; | 765 | return; |
766 | inode = ctx->dentry->d_inode; | 766 | inode = d_inode(ctx->dentry); |
767 | if (!list_empty(&NFS_I(inode)->open_files)) | 767 | if (!list_empty(&NFS_I(inode)->open_files)) |
768 | return; | 768 | return; |
769 | server = NFS_SERVER(inode); | 769 | server = NFS_SERVER(inode); |
@@ -810,7 +810,7 @@ EXPORT_SYMBOL_GPL(get_nfs_open_context); | |||
810 | 810 | ||
811 | static void __put_nfs_open_context(struct nfs_open_context *ctx, int is_sync) | 811 | static void __put_nfs_open_context(struct nfs_open_context *ctx, int is_sync) |
812 | { | 812 | { |
813 | struct inode *inode = ctx->dentry->d_inode; | 813 | struct inode *inode = d_inode(ctx->dentry); |
814 | struct super_block *sb = ctx->dentry->d_sb; | 814 | struct super_block *sb = ctx->dentry->d_sb; |
815 | 815 | ||
816 | if (!list_empty(&ctx->list)) { | 816 | if (!list_empty(&ctx->list)) { |
@@ -842,7 +842,7 @@ EXPORT_SYMBOL_GPL(put_nfs_open_context); | |||
842 | */ | 842 | */ |
843 | void nfs_inode_attach_open_context(struct nfs_open_context *ctx) | 843 | void nfs_inode_attach_open_context(struct nfs_open_context *ctx) |
844 | { | 844 | { |
845 | struct inode *inode = ctx->dentry->d_inode; | 845 | struct inode *inode = d_inode(ctx->dentry); |
846 | struct nfs_inode *nfsi = NFS_I(inode); | 846 | struct nfs_inode *nfsi = NFS_I(inode); |
847 | 847 | ||
848 | spin_lock(&inode->i_lock); | 848 | spin_lock(&inode->i_lock); |
@@ -885,7 +885,7 @@ static void nfs_file_clear_open_context(struct file *filp) | |||
885 | struct nfs_open_context *ctx = nfs_file_open_context(filp); | 885 | struct nfs_open_context *ctx = nfs_file_open_context(filp); |
886 | 886 | ||
887 | if (ctx) { | 887 | if (ctx) { |
888 | struct inode *inode = ctx->dentry->d_inode; | 888 | struct inode *inode = d_inode(ctx->dentry); |
889 | 889 | ||
890 | filp->private_data = NULL; | 890 | filp->private_data = NULL; |
891 | spin_lock(&inode->i_lock); | 891 | spin_lock(&inode->i_lock); |