summaryrefslogtreecommitdiffstats
path: root/fs/coda/cnode.c
diff options
context:
space:
mode:
authorAl Viro <viro@zeniv.linux.org.uk>2012-01-10 11:11:49 -0500
committerAl Viro <viro@zeniv.linux.org.uk>2012-01-10 11:13:16 -0500
commitf4947fbce208990266920d51837e4e7ba9779db1 (patch)
treea541edc5de897ce03f54d83c1a1c8147ce22b605 /fs/coda/cnode.c
parent0b2c4e39c014219ef73f05ab580c284bf8e6af0a (diff)
downloadop-kernel-dev-f4947fbce208990266920d51837e4e7ba9779db1.zip
op-kernel-dev-f4947fbce208990266920d51837e4e7ba9779db1.tar.gz
coda: switch coda_cnode_make() to sane API as well, clean coda_lookup()
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'fs/coda/cnode.c')
-rw-r--r--fs/coda/cnode.c17
1 files changed, 7 insertions, 10 deletions
diff --git a/fs/coda/cnode.c b/fs/coda/cnode.c
index 8af67c9..911cf30 100644
--- a/fs/coda/cnode.c
+++ b/fs/coda/cnode.c
@@ -88,24 +88,21 @@ struct inode * coda_iget(struct super_block * sb, struct CodaFid * fid,
- link the two up if this is needed
- fill in the attributes
*/
-int coda_cnode_make(struct inode **inode, struct CodaFid *fid, struct super_block *sb)
+struct inode *coda_cnode_make(struct CodaFid *fid, struct super_block *sb)
{
struct coda_vattr attr;
+ struct inode *inode;
int error;
/* We get inode numbers from Venus -- see venus source */
error = venus_getattr(sb, fid, &attr);
- if ( error ) {
- *inode = NULL;
- return error;
- }
+ if (error)
+ return ERR_PTR(error);
- *inode = coda_iget(sb, fid, &attr);
- if ( IS_ERR(*inode) ) {
+ inode = coda_iget(sb, fid, &attr);
+ if (IS_ERR(inode))
printk("coda_cnode_make: coda_iget failed\n");
- return PTR_ERR(*inode);
- }
- return 0;
+ return inode;
}
OpenPOWER on IntegriCloud