iget: stop FreeVXFS from using iget() and read_inode()

Stop the FreeVXFS filesystem from using iget() and read_inode().  Replace
vxfs_read_inode() with vxfs_iget(), and call that instead of iget().
vxfs_iget() then uses iget_locked() directly and returns a proper error code
instead of an inode in the event of an error.

vxfs_fill_super() returns any error incurred when getting the root inode
instead of EINVAL.

[akpm@linux-foundation.org: coding-style fixes]
Signed-off-by: David Howells <dhowells@redhat.com>
Acked-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
This commit is contained in:
David Howells
2008-02-07 00:15:39 -08:00
committed by Linus Torvalds
parent 17f95a7b44
commit d0b079483d
4 changed files with 39 additions and 22 deletions

View File

@@ -213,10 +213,10 @@ vxfs_lookup(struct inode *dip, struct dentry *dp, struct nameidata *nd)
lock_kernel();
ino = vxfs_inode_by_name(dip, dp);
if (ino) {
ip = iget(dip->i_sb, ino);
if (!ip) {
ip = vxfs_iget(dip->i_sb, ino);
if (IS_ERR(ip)) {
unlock_kernel();
return ERR_PTR(-EACCES);
return ERR_CAST(ip);
}
}
unlock_kernel();