diff options
author | Al Viro <viro@zeniv.linux.org.uk> | 2013-01-23 17:07:38 -0500 |
---|---|---|
committer | Al Viro <viro@zeniv.linux.org.uk> | 2013-02-22 23:31:31 -0500 |
commit | 496ad9aa8ef448058e36ca7a787c61f2e63f0f54 (patch) | |
tree | 8f4abde793cd7db5bb8fde6d27ebcacd0e54379a /fs/nfs/dir.c | |
parent | 57eccb830f1cc93d4b506ba306d8dfa685e0c88f (diff) |
new helper: file_inode(file)
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'fs/nfs/dir.c')
-rw-r--r-- | fs/nfs/dir.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/fs/nfs/dir.c b/fs/nfs/dir.c index 1b2d7eb93796..a8bd28cde7e2 100644 --- a/fs/nfs/dir.c +++ b/fs/nfs/dir.c | |||
@@ -281,7 +281,7 @@ int nfs_readdir_search_for_cookie(struct nfs_cache_array *array, nfs_readdir_des | |||
281 | 281 | ||
282 | for (i = 0; i < array->size; i++) { | 282 | for (i = 0; i < array->size; i++) { |
283 | if (array->array[i].cookie == *desc->dir_cookie) { | 283 | if (array->array[i].cookie == *desc->dir_cookie) { |
284 | struct nfs_inode *nfsi = NFS_I(desc->file->f_path.dentry->d_inode); | 284 | struct nfs_inode *nfsi = NFS_I(file_inode(desc->file)); |
285 | struct nfs_open_dir_context *ctx = desc->file->private_data; | 285 | struct nfs_open_dir_context *ctx = desc->file->private_data; |
286 | 286 | ||
287 | new_pos = desc->current_index + i; | 287 | new_pos = desc->current_index + i; |
@@ -629,7 +629,7 @@ out: | |||
629 | static | 629 | static |
630 | int nfs_readdir_filler(nfs_readdir_descriptor_t *desc, struct page* page) | 630 | int nfs_readdir_filler(nfs_readdir_descriptor_t *desc, struct page* page) |
631 | { | 631 | { |
632 | struct inode *inode = desc->file->f_path.dentry->d_inode; | 632 | struct inode *inode = file_inode(desc->file); |
633 | int ret; | 633 | int ret; |
634 | 634 | ||
635 | ret = nfs_readdir_xdr_to_array(desc, page, inode); | 635 | ret = nfs_readdir_xdr_to_array(desc, page, inode); |
@@ -660,7 +660,7 @@ void cache_page_release(nfs_readdir_descriptor_t *desc) | |||
660 | static | 660 | static |
661 | struct page *get_cache_page(nfs_readdir_descriptor_t *desc) | 661 | struct page *get_cache_page(nfs_readdir_descriptor_t *desc) |
662 | { | 662 | { |
663 | return read_cache_page(desc->file->f_path.dentry->d_inode->i_mapping, | 663 | return read_cache_page(file_inode(desc->file)->i_mapping, |
664 | desc->page_index, (filler_t *)nfs_readdir_filler, desc); | 664 | desc->page_index, (filler_t *)nfs_readdir_filler, desc); |
665 | } | 665 | } |
666 | 666 | ||
@@ -764,7 +764,7 @@ int uncached_readdir(nfs_readdir_descriptor_t *desc, void *dirent, | |||
764 | { | 764 | { |
765 | struct page *page = NULL; | 765 | struct page *page = NULL; |
766 | int status; | 766 | int status; |
767 | struct inode *inode = desc->file->f_path.dentry->d_inode; | 767 | struct inode *inode = file_inode(desc->file); |
768 | struct nfs_open_dir_context *ctx = desc->file->private_data; | 768 | struct nfs_open_dir_context *ctx = desc->file->private_data; |
769 | 769 | ||
770 | dfprintk(DIRCACHE, "NFS: uncached_readdir() searching for cookie %Lu\n", | 770 | dfprintk(DIRCACHE, "NFS: uncached_readdir() searching for cookie %Lu\n", |