aboutsummaryrefslogtreecommitdiffstats
path: root/fs
diff options
context:
space:
mode:
authorAl Viro <viro@zeniv.linux.org.uk>2014-10-12 22:24:21 -0400
committerAl Viro <viro@zeniv.linux.org.uk>2014-11-19 13:01:20 -0500
commit41d28bca2da4bd75a8915c1ccf2cacf7f4a2e531 (patch)
tree1a3d658ecfe4375e0ca4f837f6c7f8397efdefba /fs
parentb5ae6b15bd73e35b129408755a0804287a87e041 (diff)
switch d_materialise_unique() users to d_splice_alias()
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'fs')
-rw-r--r--fs/9p/vfs_inode.c2
-rw-r--r--fs/btrfs/inode.c2
-rw-r--r--fs/ceph/inode.c2
-rw-r--r--fs/cifs/readdir.c2
-rw-r--r--fs/fuse/dir.c4
-rw-r--r--fs/kernfs/dir.c2
-rw-r--r--fs/nfs/dir.c4
-rw-r--r--fs/nfs/getroot.c2
8 files changed, 10 insertions, 10 deletions
diff --git a/fs/9p/vfs_inode.c b/fs/9p/vfs_inode.c
index 296482fc77a9..9ee5343d4884 100644
--- a/fs/9p/vfs_inode.c
+++ b/fs/9p/vfs_inode.c
@@ -832,7 +832,7 @@ struct dentry *v9fs_vfs_lookup(struct inode *dir, struct dentry *dentry,
832 * moved b under k and client parallely did a lookup for 832 * moved b under k and client parallely did a lookup for
833 * k/b. 833 * k/b.
834 */ 834 */
835 res = d_materialise_unique(dentry, inode); 835 res = d_splice_alias(inode, dentry);
836 if (!res) 836 if (!res)
837 v9fs_fid_add(dentry, fid); 837 v9fs_fid_add(dentry, fid);
838 else if (!IS_ERR(res)) 838 else if (!IS_ERR(res))
diff --git a/fs/btrfs/inode.c b/fs/btrfs/inode.c
index d23362f4464e..ff0dcc016b71 100644
--- a/fs/btrfs/inode.c
+++ b/fs/btrfs/inode.c
@@ -5303,7 +5303,7 @@ static struct dentry *btrfs_lookup(struct inode *dir, struct dentry *dentry,
5303 return ERR_CAST(inode); 5303 return ERR_CAST(inode);
5304 } 5304 }
5305 5305
5306 return d_materialise_unique(dentry, inode); 5306 return d_splice_alias(inode, dentry);
5307} 5307}
5308 5308
5309unsigned char btrfs_filetype_table[] = { 5309unsigned char btrfs_filetype_table[] = {
diff --git a/fs/ceph/inode.c b/fs/ceph/inode.c
index 7a1df90c7771..90ec8e32c138 100644
--- a/fs/ceph/inode.c
+++ b/fs/ceph/inode.c
@@ -967,7 +967,7 @@ static struct dentry *splice_dentry(struct dentry *dn, struct inode *in,
967 /* dn must be unhashed */ 967 /* dn must be unhashed */
968 if (!d_unhashed(dn)) 968 if (!d_unhashed(dn))
969 d_drop(dn); 969 d_drop(dn);
970 realdn = d_materialise_unique(dn, in); 970 realdn = d_splice_alias(in, dn);
971 if (IS_ERR(realdn)) { 971 if (IS_ERR(realdn)) {
972 pr_err("splice_dentry error %ld %p inode %p ino %llx.%llx\n", 972 pr_err("splice_dentry error %ld %p inode %p ino %llx.%llx\n",
973 PTR_ERR(realdn), dn, in, ceph_vinop(in)); 973 PTR_ERR(realdn), dn, in, ceph_vinop(in));
diff --git a/fs/cifs/readdir.c b/fs/cifs/readdir.c
index 8fd2a95860ba..586e3d3b204e 100644
--- a/fs/cifs/readdir.c
+++ b/fs/cifs/readdir.c
@@ -123,7 +123,7 @@ cifs_prime_dcache(struct dentry *parent, struct qstr *name,
123 if (!inode) 123 if (!inode)
124 goto out; 124 goto out;
125 125
126 alias = d_materialise_unique(dentry, inode); 126 alias = d_splice_alias(inode, dentry);
127 if (alias && !IS_ERR(alias)) 127 if (alias && !IS_ERR(alias))
128 dput(alias); 128 dput(alias);
129out: 129out:
diff --git a/fs/fuse/dir.c b/fs/fuse/dir.c
index dbab798f5caf..df562cc87763 100644
--- a/fs/fuse/dir.c
+++ b/fs/fuse/dir.c
@@ -372,7 +372,7 @@ static struct dentry *fuse_lookup(struct inode *dir, struct dentry *entry,
372 if (inode && get_node_id(inode) == FUSE_ROOT_ID) 372 if (inode && get_node_id(inode) == FUSE_ROOT_ID)
373 goto out_iput; 373 goto out_iput;
374 374
375 newent = d_materialise_unique(entry, inode); 375 newent = d_splice_alias(inode, entry);
376 err = PTR_ERR(newent); 376 err = PTR_ERR(newent);
377 if (IS_ERR(newent)) 377 if (IS_ERR(newent))
378 goto out_err; 378 goto out_err;
@@ -1320,7 +1320,7 @@ static int fuse_direntplus_link(struct file *file,
1320 if (!inode) 1320 if (!inode)
1321 goto out; 1321 goto out;
1322 1322
1323 alias = d_materialise_unique(dentry, inode); 1323 alias = d_splice_alias(inode, dentry);
1324 err = PTR_ERR(alias); 1324 err = PTR_ERR(alias);
1325 if (IS_ERR(alias)) 1325 if (IS_ERR(alias))
1326 goto out; 1326 goto out;
diff --git a/fs/kernfs/dir.c b/fs/kernfs/dir.c
index 1c771931bb60..37989f02a226 100644
--- a/fs/kernfs/dir.c
+++ b/fs/kernfs/dir.c
@@ -807,7 +807,7 @@ static struct dentry *kernfs_iop_lookup(struct inode *dir,
807 } 807 }
808 808
809 /* instantiate and hash dentry */ 809 /* instantiate and hash dentry */
810 ret = d_materialise_unique(dentry, inode); 810 ret = d_splice_alias(inode, dentry);
811 out_unlock: 811 out_unlock:
812 mutex_unlock(&kernfs_mutex); 812 mutex_unlock(&kernfs_mutex);
813 return ret; 813 return ret;
diff --git a/fs/nfs/dir.c b/fs/nfs/dir.c
index 06e8cfcbb670..44d7d0c7e376 100644
--- a/fs/nfs/dir.c
+++ b/fs/nfs/dir.c
@@ -499,7 +499,7 @@ void nfs_prime_dcache(struct dentry *parent, struct nfs_entry *entry)
499 if (IS_ERR(inode)) 499 if (IS_ERR(inode))
500 goto out; 500 goto out;
501 501
502 alias = d_materialise_unique(dentry, inode); 502 alias = d_splice_alias(inode, dentry);
503 if (IS_ERR(alias)) 503 if (IS_ERR(alias))
504 goto out; 504 goto out;
505 else if (alias) { 505 else if (alias) {
@@ -1393,7 +1393,7 @@ struct dentry *nfs_lookup(struct inode *dir, struct dentry * dentry, unsigned in
1393 nfs_advise_use_readdirplus(dir); 1393 nfs_advise_use_readdirplus(dir);
1394 1394
1395no_entry: 1395no_entry:
1396 res = d_materialise_unique(dentry, inode); 1396 res = d_splice_alias(inode, dentry);
1397 if (res != NULL) { 1397 if (res != NULL) {
1398 if (IS_ERR(res)) 1398 if (IS_ERR(res))
1399 goto out_unblock_sillyrename; 1399 goto out_unblock_sillyrename;
diff --git a/fs/nfs/getroot.c b/fs/nfs/getroot.c
index ebc6a0add5ae..9ac3846cb59e 100644
--- a/fs/nfs/getroot.c
+++ b/fs/nfs/getroot.c
@@ -51,7 +51,7 @@ static int nfs_superblock_set_dummy_root(struct super_block *sb, struct inode *i
51 /* 51 /*
52 * Ensure that this dentry is invisible to d_find_alias(). 52 * Ensure that this dentry is invisible to d_find_alias().
53 * Otherwise, it may be spliced into the tree by 53 * Otherwise, it may be spliced into the tree by
54 * d_materialise_unique if a parent directory from the same 54 * d_splice_alias if a parent directory from the same
55 * filesystem gets mounted at a later time. 55 * filesystem gets mounted at a later time.
56 * This again causes shrink_dcache_for_umount_subtree() to 56 * This again causes shrink_dcache_for_umount_subtree() to
57 * Oops, since the test for IS_ROOT() will fail. 57 * Oops, since the test for IS_ROOT() will fail.