aboutsummaryrefslogtreecommitdiffstats
path: root/fs/affs/amigaffs.c
diff options
context:
space:
mode:
authorDavid Howells <dhowells@redhat.com>2008-02-07 00:15:29 -0800
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2008-02-07 08:42:27 -0800
commit210f855963ba5edc4c7150754a79709a7c8a0d3c (patch)
tree10f5030c3b0eec9e1afe9923d28a99f548f14db4 /fs/affs/amigaffs.c
parent69840b0d065a031a2e5b3fcc3f30560229e312da (diff)
downloadkernel_goldelico_gta04-210f855963ba5edc4c7150754a79709a7c8a0d3c.zip
kernel_goldelico_gta04-210f855963ba5edc4c7150754a79709a7c8a0d3c.tar.gz
kernel_goldelico_gta04-210f855963ba5edc4c7150754a79709a7c8a0d3c.tar.bz2
iget: stop AFFS from using iget() and read_inode()
Stop the AFFS filesystem from using iget() and read_inode(). Replace affs_read_inode() with affs_iget(), and call that instead of iget(). affs_iget() then uses iget_locked() directly and returns a proper error code instead of an inode in the event of an error. affs_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> Cc: Roman Zippel <zippel@linux-m68k.org> 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>
Diffstat (limited to 'fs/affs/amigaffs.c')
-rw-r--r--fs/affs/amigaffs.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/fs/affs/amigaffs.c b/fs/affs/amigaffs.c
index f4de4b9..8055730 100644
--- a/fs/affs/amigaffs.c
+++ b/fs/affs/amigaffs.c
@@ -170,9 +170,11 @@ affs_remove_link(struct dentry *dentry)
if (!link_bh)
goto done;
- dir = iget(sb, be32_to_cpu(AFFS_TAIL(sb, link_bh)->parent));
- if (!dir)
+ dir = affs_iget(sb, be32_to_cpu(AFFS_TAIL(sb, link_bh)->parent));
+ if (IS_ERR(dir)) {
+ retval = PTR_ERR(dir);
goto done;
+ }
affs_lock_dir(dir);
affs_fix_dcache(dentry, link_ino);