diff options
author | Christoph Hellwig <hch@lst.de> | 2008-08-11 09:49:04 -0400 |
---|---|---|
committer | Al Viro <viro@zeniv.linux.org.uk> | 2008-10-23 05:13:01 -0400 |
commit | 440037287c5ebb07033ab927ca16bb68c291d309 (patch) | |
tree | c4be3843ea87a777c2647f471895917005d8068f /fs/dcache.c | |
parent | 4ea3ada2955e4519befa98ff55dd62d6dfbd1705 (diff) |
[PATCH] switch all filesystems over to d_obtain_alias
Switch all users of d_alloc_anon to d_obtain_alias.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'fs/dcache.c')
-rw-r--r-- | fs/dcache.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/fs/dcache.c b/fs/dcache.c index 46fc78206782..d45ff7f5ecc2 100644 --- a/fs/dcache.c +++ b/fs/dcache.c | |||
@@ -1187,17 +1187,17 @@ struct dentry * d_alloc_anon(struct inode *inode) | |||
1187 | * allocating a new one. | 1187 | * allocating a new one. |
1188 | * | 1188 | * |
1189 | * On successful return, the reference to the inode has been transferred | 1189 | * On successful return, the reference to the inode has been transferred |
1190 | * to the dentry. If %NULL is returned (indicating kmalloc failure), | 1190 | * to the dentry. In case of an error the reference on the inode is released. |
1191 | * the reference on the inode has been released. To make it easier | 1191 | * To make it easier to use in export operations a %NULL or IS_ERR inode may |
1192 | * to use in export operations a NULL or IS_ERR inode may be passed in | 1192 | * be passed in and will be the error will be propagate to the return value, |
1193 | * and will be casted to the corresponding NULL or IS_ERR dentry. | 1193 | * with a %NULL @inode replaced by ERR_PTR(-ESTALE). |
1194 | */ | 1194 | */ |
1195 | struct dentry *d_obtain_alias(struct inode *inode) | 1195 | struct dentry *d_obtain_alias(struct inode *inode) |
1196 | { | 1196 | { |
1197 | struct dentry *dentry; | 1197 | struct dentry *dentry; |
1198 | 1198 | ||
1199 | if (!inode) | 1199 | if (!inode) |
1200 | return NULL; | 1200 | return ERR_PTR(-ESTALE); |
1201 | if (IS_ERR(inode)) | 1201 | if (IS_ERR(inode)) |
1202 | return ERR_CAST(inode); | 1202 | return ERR_CAST(inode); |
1203 | 1203 | ||