Re: [PATCH 12/30] IGET: Stop EXT3 from using iget() and read_inode()

2007-10-02 Thread David Howells
Jan Kara <[EMAIL PROTECTED]> wrote: > But if you 'goto out' in some branches, we loose the ext3_warning() > which we probably don't want. Ugh. Okay, I need to rework the changes to that function. > > return ERR_PTR(-EACCES); > Wouldn't here -EIO be more appropriate? I w

Re: [PATCH 07/30] IGET: Stop BEFS from using iget() and read_inode()

2007-10-02 Thread David Howells
Dave Kleikamp <[EMAIL PROTECTED]> wrote: > Of course, the cast is unnecessary, The cast is necessary as the argument is a const pointer and the return type is not. > and I'm sure you meant to return error: Oops. Yes, I changed my mind and renamed the argument to be 'error', but forgot to chang

Re: [PATCH 13/30] IGET: Stop EXT4 from using iget() and read_inode()

2007-10-02 Thread David Howells
Jan Kara <[EMAIL PROTECTED]> wrote: > Same comments as for ext3 - I think you reversed ext4_test_bit() test > and also the warning won't be issued in some cases which is wrong. Same replies as for ext3 too. Blech. You should find altered patches landing in your inbox if you'd care to inspect

[PATCH 00/32] Remove iget() and read_inode() [try #2]

2007-10-04 Thread David Howells
Hi Christoph, Al, Here's a set of patches that remove all calls to iget() and all read_inode() functions. They should be removed for two reasons: firstly they don't lend themselves to good error handling, and secondly their presence is a temptation for code outside a filesystem to call iget() t

[PATCH 03/32] IGET: Introduce a function to register iget failure [try #2]

2007-10-04 Thread David Howells
Introduce a function to register failure in an inode construction path. This includes marking the inode under construction as bad, unlocking it and releasing it. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- Documentation/filesystems/porting | 18 +- fs/bad_i

[PATCH 02/32] Convert ERR_PTR(PTR_ERR(p)) instances to ERR_CAST(p) [try #2]

2007-10-04 Thread David Howells
Convert instances of ERR_PTR(PTR_ERR(p)) to ERR_CAST(p) using: perl -spi -e 's/ERR_PTR[(]PTR_ERR[(](.*)[)][)]/ERR_CAST(\1)/' `grep -rl 'ERR_PTR[(]*PTR_ERR' fs crypto net security` Signed-off-by: David Howells <[EMAIL PROTECTED]> --- crypto/cbc.c

[PATCH 01/32] Add an ERR_CAST() macro to complement ERR_PTR and co. [try #2]

2007-10-04 Thread David Howells
Add an ERR_CAST() macro to complement ERR_PTR and co. for the purposes of casting an error entyped as one pointer type to an error of another pointer type whilst making it explicit as to what is going on. This provides a replacement for the ERR_PTR(PTR_ERR(p)) construct. Signed-off-by: David

[PATCH 05/32] IGET: Use iget_failed() in GFS2 [try #2]

2007-10-04 Thread David Howells
Use iget_failed() in GFS2 to kill a failed inode. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/gfs2/inode.c |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/fs/gfs2/inode.c b/fs/gfs2/inode.c index 34f7bcd..498844f 100644 --- a/fs/gfs2/inode.c +++ b/f

[PATCH 04/32] IGET: Use iget_failed() in AFS [try #2]

2007-10-04 Thread David Howells
Use iget_failed() in AFS to kill a failed inode. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/afs/inode.c |5 + 1 files changed, 1 insertions(+), 4 deletions(-) diff --git a/fs/afs/inode.c b/fs/afs/inode.c index d196840..ca9b02f 100644 --- a/fs/afs/inode.c +++ b/

[PATCH 06/32] IGET: Mark iget() and read_inode() as being obsolete [try #2]

2007-10-04 Thread David Howells
sb, ino); if (IS_ERR(inode)) { ret = PTR_ERR(inode); goto error; } Signed-off-by: David Howells <[EMAIL PROTECTED]> --- Documentation/filesystems/Exporting |5 - Documentation/filesystems/Locking |3 --- Documentation/filesystems/vfs

[PATCH 08/32] IGET: Stop autofs from using iget() and read_inode() [try #2]

2007-10-04 Thread David Howells
Stop the autofs filesystem from using iget() and read_inode(). Replace autofs_read_inode() with autofs_iget(), and call that instead of iget(). autofs_iget() then uses iget_locked() directly and returns a proper error code instead of an inode in the event of an error. Signed-off-by: David

[PATCH 09/32] IGET: Stop BEFS from using iget() and read_inode() [try #2]

2007-10-04 Thread David Howells
incurred when getting the root inode instead of EINVAL. Signed-off-by: David Howells <[EMAIL PROTECTED]> Acked-by: Will Dyson <[EMAIL PROTECTED]> --- fs/befs/linuxvfs.c | 39 +-- 1 files changed, 25 insertions(+), 14 deletions(-) diff --g

[PATCH 10/32] IGET: Stop BFS from using iget() and read_inode() [try #2]

2007-10-04 Thread David Howells
incurred when getting the root inode instead of EINVAL. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/bfs/bfs.h |2 ++ fs/bfs/dir.c |6 +++--- fs/bfs/inode.c | 32 ++-- 3 files changed, 27 insertions(+), 13 deletions(-) diff --git a/fs/bfs/b

[PATCH 07/32] IGET: Stop AFFS from using iget() and read_inode() [try #2]

2007-10-04 Thread David Howells
incurred when getting the root inode instead of EINVAL. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/affs/affs.h |2 +- fs/affs/amigaffs.c |6 -- fs/affs/inode.c| 20 +--- fs/affs/namei.c| 10 -- fs/affs/super.c

[PATCH 11/32] IGET: Stop CIFS from using iget() and read_inode() [try #2]

2007-10-04 Thread David Howells
error incurred when getting the root inode instead of ENOMEM. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/cifs/cifsfs.c |8 fs/cifs/cifsfs.h |1 + fs/cifs/inode.c | 35 ++- 3 files changed, 31 insertions(+), 13 deletions(-)

[PATCH 12/32] IGET: Stop EFS from using iget() and read_inode() [try #2]

2007-10-04 Thread David Howells
incurred when getting the root inode instead of EACCES. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/efs/inode.c | 25 + fs/efs/namei.c | 23 --- fs/efs/super.c | 18 -- include/linux/efs_fs.h

[PATCH 13/32] IGET: Stop EXT2 from using iget() and read_inode() [try #2]

2007-10-04 Thread David Howells
incurred when getting the root inode instead of EINVAL. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/ext2/ext2.h |2 +- fs/ext2/inode.c | 30 ++ fs/ext2/namei.c | 12 ++-- fs/ext2/super.c | 32 ++-- 4

[PATCH 14/32] IGET: Stop EXT3 from using iget() and read_inode() [try #2]

2007-10-04 Thread David Howells
incurred when getting the root inode instead of EINVAL. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/ext3/ialloc.c| 58 --- fs/ext3/inode.c | 25 +++- fs/ext3/namei.c

[PATCH 15/32] IGET: Stop EXT4 from using iget() and read_inode() [try #2]

2007-10-04 Thread David Howells
incurred when getting the root inode instead of EINVAL. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/ext4/ialloc.c| 58 --- fs/ext4/inode.c | 25 +++- fs/ext4/namei.c

[PATCH 16/32] IGET: Stop FAT from using iget() and read_inode() [try #2]

2007-10-04 Thread David Howells
Stop the FAT filesystem from using iget() and read_inode(). Replace the call to iget() with a call to ilookup(). Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/fat/inode.c |6 ++ 1 files changed, 2 insertions(+), 4 deletions(-) diff --git a/fs/fat/inode.c b/fs/fat/i

[PATCH 17/32] IGET: Stop FreeVXFS from using iget() and read_inode() [try #2]

2007-10-04 Thread David Howells
error incurred when getting the root inode instead of EINVAL. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/freevxfs/vxfs_extern.h |2 +- fs/freevxfs/vxfs_inode.c | 45 + fs/freevxfs/vxfs_lookup.c |6 +++--- fs/freevxfs/vxfs_s

[PATCH 18/32] IGET: Stop FUSE from using iget() and read_inode() [try #2]

2007-10-04 Thread David Howells
Stop the FUSE filesystem from using read_inode(), which it doesn't use anyway. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/fuse/inode.c |6 -- 1 files changed, 0 insertions(+), 6 deletions(-) diff --git a/fs/fuse/inode.c b/fs/fuse/inode.c index 5448f62..2986654 1

[PATCH 19/32] IGET: Stop HFSPLUS from using iget() and read_inode() [try #2]

2007-10-04 Thread David Howells
() returns any error incurred when getting the root inode. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/hfsplus/btree.c |6 -- fs/hfsplus/dir.c|6 +++--- fs/hfsplus/hfsplus_fs.h |3 +++ fs/hfsplus/super.c

[PATCH 20/32] IGET: Stop ISOFS from using read_inode() [try #2]

2007-10-04 Thread David Howells
Stop the ISOFS filesystem from using read_inode(). Make isofs_read_inode() return an error code, and make isofs_iget() pass it on. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/isofs/inode.c | 25 + 1 files changed, 17 insertions(+), 8 deletions(-)

[PATCH 21/32] IGET: Stop JFFS2 from using iget() and read_inode() [try #2]

2007-10-04 Thread David Howells
any error incurred when getting the root inode instead of EINVAL. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/jffs2/dir.c |6 +++-- fs/jffs2/fs.c | 56 --- fs/jffs2/os-linux.h |2 +- fs/jffs2/super.c|

[PATCH 22/32] IGET: Stop JFS from using iget() and read_inode() [try #2]

2007-10-04 Thread David Howells
incurred when getting the root inode instead of EINVAL. Signed-off-by: David Howells <[EMAIL PROTECTED]> Acked-by: Dave Kleikamp <[EMAIL PROTECTED]> --- fs/jfs/inode.c | 20 fs/jfs/jfs_inode.h |2 +- fs/jfs/namei.c | 34 ++

[PATCH 23/32] IGET: Stop the MINIX filesystem from using iget() and read_inode() [try #2]

2007-10-04 Thread David Howells
error incurred when getting the root inode instead of EINVAL. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/minix/inode.c | 43 +-- fs/minix/minix.h |1 + fs/minix/namei.c |7 +++ 3 files changed, 33 insertions(+), 18 del

[PATCH 24/32] IGET: Stop PROCFS from using iget() and read_inode() [try #2]

2007-10-04 Thread David Howells
Stop the PROCFS filesystem from using iget() and read_inode(). Merge procfs_read_inode() into procfs_get_inode(), and have that call iget_locked() instead of iget(). Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/proc/inode.c

[PATCH 25/32] IGET: Stop QNX4 from using iget() and read_inode() [try #2]

2007-10-04 Thread David Howells
incurred when getting the root inode instead of EINVAL. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/qnx4/inode.c | 45 ++--- fs/qnx4/namei.c |8 +--- include/linux/qnx4_fs.h |1 + 3 files changed, 36 inse

[PATCH 26/32] IGET: Stop ROMFS from using iget() and read_inode() [try #2]

2007-10-04 Thread David Howells
error incurred when getting the root inode instead of EINVAL. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/romfs/inode.c | 45 +++-- 1 files changed, 31 insertions(+), 14 deletions(-) diff --git a/fs/romfs/inode.c b/fs/romfs/inode.c

[PATCH 27/32] IGET: Stop the SYSV filesystem from using iget() and read_inode() [try #2]

2007-10-04 Thread David Howells
Stop the SYSV filesystem from using iget() and read_inode(). Replace sysv_read_inode() with sysv_iget(), and call that instead of iget(). sysv_iget() then uses iget_locked() directly and returns a proper error code instead of an inode in the event of an error. Signed-off-by: David Howells

[PATCH 28/32] IGET: Stop UFS from using iget() and read_inode() [try #2]

2007-10-04 Thread David Howells
incurred when getting the root inode instead of EINVAL. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/ufs/inode.c | 34 -- fs/ufs/namei.c |6 +++--- fs/ufs/super.c | 14 +- include/linux/ufs_fs.h |2 +- 4

[PATCH 29/32] IGET: Stop OPENPROMFS from using iget() and read_inode() [try #2]

2007-10-04 Thread David Howells
. openpromfs_fill_super() returns any error incurred when getting the root inode instead of ENOMEM (not that it currently incurs any other error). Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/openpromfs/inode.c | 45 ++--- 1 files changed, 30 inse

[PATCH 32/32] IGET: Remove iget() and the read_inode() super op as being obsolete [try #2]

2007-10-04 Thread David Howells
() to find an inode by number in a filesystem from code outside that filesystem. iget_locked() should be used instead. A new function is added (iget_failed) that is to be called to mark an inode as bad, unlock it and release it should the get routine fail. Signed-off-by: David Howells <[EM

[PATCH 31/32] IGET: Stop HPPFS from using iget() and read_inode() [try #2]

2007-10-04 Thread David Howells
f the inode goes away. (*) hppfs_iget() should perhaps subsume init_inode() and hppfs_read_inode(). (*) It would appear that all hppfs inodes are the same inode because iget() was being called with inode number 0, which forms the lookup key. Signed-off-by: David Howells <[EMAIL P

[PATCH 30/32] IGET: Stop HOSTFS from using iget() and read_inode() [try #2]

2007-10-04 Thread David Howells
inode number 0 - which forms the lookup key. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/hostfs/hostfs_kern.c | 58 --- 1 files changed, 39 insertions(+), 19 deletions(-) diff --git a/fs/hostfs/hostfs_kern.c b/fs/hostfs/hostfs_kern.c

Re: [PATCH 00/32] Remove iget() and read_inode() [try #2]

2007-10-05 Thread David Howells
David Howells <[EMAIL PROTECTED]> wrote: > A tarball of the patches can be retrieved from: > > http://people.redhat.com/~dhowells/iget-remove.tar.bz2 I've updated that to actually reflect this set of patches and not the old set. David - To unsubscribe from this

Re: [PATCH 06/32] IGET: Mark iget() and read_inode() as being obsolete [try #2]

2007-10-05 Thread David Howells
David Howells <[EMAIL PROTECTED]> wrote: > > Why do you move it out of line? > > Because otherwise every file that gets compiled that includes linux/fs.h will > emit a warning that the implementation of that function is deprecated. Or, rather, that read_inode() is de

Re: [PATCH 06/32] IGET: Mark iget() and read_inode() as being obsolete [try #2]

2007-10-05 Thread David Howells
Christoph Hellwig <[EMAIL PROTECTED]> wrote: > Why do you move it out of line? Because otherwise every file that gets compiled that includes linux/fs.h will emit a warning that the implementation of that function is deprecated. David - To unsubscribe from this list: send the line "unsubscribe li

Re: [PATCH 01/32] Add an ERR_CAST() macro to complement ERR_PTR and co. [try #2]

2007-10-05 Thread David Howells
Christoph Hellwig <[EMAIL PROTECTED]> wrote: > I don't like this one very much, I'd rather take the variant Linus > outline in his last post on that topic.. I'd rather not take that variant. David - To unsubscribe from this list: send the line "unsubscribe linux-fsdevel" in the body of a message

Re: [PATCH 01/32] Add an ERR_CAST() macro to complement ERR_PTR and co. [try #2]

2007-10-05 Thread David Howells
Sam Ravnborg <[EMAIL PROTECTED]> wrote: > One like one variant, another like another variant. > Both fails to say why. It's shorter, more compact, and of course requires the least amount of change (especially as I can automate it with a command line perl script). David - To unsubscribe from this

[PATCH 01/31] Add an ERR_CAST() macro to complement ERR_PTR and co. [try #3]

2007-10-10 Thread David Howells
Add an ERR_CAST() macro to complement ERR_PTR and co. for the purposes of casting an error entyped as one pointer type to an error of another pointer type whilst making it explicit as to what is going on. This provides a replacement for the ERR_PTR(PTR_ERR(p)) construct. Signed-off-by: David

[PATCH 02/31] Convert ERR_PTR(PTR_ERR(p)) instances to ERR_CAST(p) [try #3]

2007-10-10 Thread David Howells
Convert instances of ERR_PTR(PTR_ERR(p)) to ERR_CAST(p) using: perl -spi -e 's/ERR_PTR[(]PTR_ERR[(](.*)[)][)]/ERR_CAST(\1)/' `grep -rl 'ERR_PTR[(]*PTR_ERR' fs crypto net security` Signed-off-by: David Howells <[EMAIL PROTECTED]> --- crypto/cbc.c

[PATCH 03/31] IGET: Introduce a function to register iget failure [try #3]

2007-10-10 Thread David Howells
Introduce a function to register failure in an inode construction path. This includes marking the inode under construction as bad, unlocking it and releasing it. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- Documentation/filesystems/porting | 18 +- fs/bad_i

[PATCH 04/31] IGET: Use iget_failed() in AFS [try #3]

2007-10-10 Thread David Howells
Use iget_failed() in AFS to kill a failed inode. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/afs/inode.c |5 + 1 files changed, 1 insertions(+), 4 deletions(-) diff --git a/fs/afs/inode.c b/fs/afs/inode.c index d196840..ca9b02f 100644 --- a/fs/afs/inode.c +++ b/

[PATCH 00/31] Remove iget() and read_inode() [try #3]

2007-10-10 Thread David Howells
Hi Christoph, Al, Here's a set of patches that remove all calls to iget() and all read_inode() functions. They should be removed for two reasons: firstly they don't lend themselves to good error handling, and secondly their presence is a temptation for code outside a filesystem to call iget() t

[PATCH 05/31] IGET: Use iget_failed() in GFS2 [try #3]

2007-10-10 Thread David Howells
Use iget_failed() in GFS2 to kill a failed inode. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/gfs2/inode.c |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/fs/gfs2/inode.c b/fs/gfs2/inode.c index 34f7bcd..498844f 100644 --- a/fs/gfs2/inode.c +++ b/f

[PATCH 06/31] IGET: Stop AFFS from using iget() and read_inode() [try #3]

2007-10-10 Thread David Howells
incurred when getting the root inode instead of EINVAL. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/affs/affs.h |2 +- fs/affs/amigaffs.c |6 -- fs/affs/inode.c| 20 +--- fs/affs/namei.c| 10 -- fs/affs/super.c

[PATCH 07/31] IGET: Stop autofs from using iget() and read_inode() [try #3]

2007-10-10 Thread David Howells
Stop the autofs filesystem from using iget() and read_inode(). Replace autofs_read_inode() with autofs_iget(), and call that instead of iget(). autofs_iget() then uses iget_locked() directly and returns a proper error code instead of an inode in the event of an error. Signed-off-by: David

[PATCH 08/31] IGET: Stop BEFS from using iget() and read_inode() [try #3]

2007-10-10 Thread David Howells
incurred when getting the root inode instead of EINVAL. Signed-off-by: David Howells <[EMAIL PROTECTED]> Acked-by: Will Dyson <[EMAIL PROTECTED]> --- fs/befs/linuxvfs.c | 39 +-- 1 files changed, 25 insertions(+), 14 deletions(-) diff --g

[PATCH 09/31] IGET: Stop BFS from using iget() and read_inode() [try #3]

2007-10-10 Thread David Howells
incurred when getting the root inode instead of EINVAL. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/bfs/bfs.h |2 ++ fs/bfs/dir.c |6 +++--- fs/bfs/inode.c | 32 ++-- 3 files changed, 27 insertions(+), 13 deletions(-) diff --git a/fs/bfs/b

[PATCH 10/31] IGET: Stop CIFS from using iget() and read_inode() [try #3]

2007-10-10 Thread David Howells
error incurred when getting the root inode instead of ENOMEM. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/cifs/cifsfs.c |8 fs/cifs/cifsfs.h |1 + fs/cifs/inode.c | 35 ++- 3 files changed, 31 insertions(+), 13 deletions(-)

[PATCH 11/31] IGET: Stop EFS from using iget() and read_inode() [try #3]

2007-10-10 Thread David Howells
incurred when getting the root inode instead of EACCES. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/efs/inode.c | 25 + fs/efs/namei.c | 23 --- fs/efs/super.c | 18 -- include/linux/efs_fs.h

[PATCH 12/31] IGET: Stop EXT2 from using iget() and read_inode() [try #3]

2007-10-10 Thread David Howells
incurred when getting the root inode instead of EINVAL. Signed-off-by: David Howells <[EMAIL PROTECTED]> Acked-by: "Theodore Ts'o" <[EMAIL PROTECTED]> --- fs/ext2/ext2.h |2 +- fs/ext2/inode.c | 30 ++ fs/ext2/namei.c | 12 ++---

[PATCH 13/31] IGET: Stop EXT3 from using iget() and read_inode() [try #3]

2007-10-10 Thread David Howells
incurred when getting the root inode instead of EINVAL. Signed-off-by: David Howells <[EMAIL PROTECTED]> Acked-by: "Theodore Ts'o" <[EMAIL PROTECTED]> Acked-by: Jan Kara <[EMAIL PROTECTED]> --- fs/ext3/ialloc.c| 58 ---

[PATCH 14/31] IGET: Stop EXT4 from using iget() and read_inode() [try #3]

2007-10-10 Thread David Howells
incurred when getting the root inode instead of EINVAL. Signed-off-by: David Howells <[EMAIL PROTECTED]> Acked-by: "Theodore Ts'o" <[EMAIL PROTECTED]> Acked-by: Jan Kara <[EMAIL PROTECTED]> --- fs/ext4/ialloc.c| 58 ---

[PATCH 15/31] IGET: Stop FAT from using iget() and read_inode() [try #3]

2007-10-10 Thread David Howells
Stop the FAT filesystem from using iget() and read_inode(). Replace the call to iget() with a call to ilookup(). Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/fat/inode.c |6 ++ 1 files changed, 2 insertions(+), 4 deletions(-) diff --git a/fs/fat/inode.c b/fs/fat/i

[PATCH 16/31] IGET: Stop FreeVXFS from using iget() and read_inode() [try #3]

2007-10-10 Thread David Howells
error incurred when getting the root inode instead of EINVAL. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/freevxfs/vxfs_extern.h |2 +- fs/freevxfs/vxfs_inode.c | 45 + fs/freevxfs/vxfs_lookup.c |6 +++--- fs/freevxfs/vxfs_s

[PATCH 17/31] IGET: Stop FUSE from using iget() and read_inode() [try #3]

2007-10-10 Thread David Howells
Stop the FUSE filesystem from using read_inode(), which it doesn't use anyway. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/fuse/inode.c |6 -- 1 files changed, 0 insertions(+), 6 deletions(-) diff --git a/fs/fuse/inode.c b/fs/fuse/inode.c index 5448f62..2986654 1

[PATCH 18/31] IGET: Stop HFSPLUS from using iget() and read_inode() [try #3]

2007-10-10 Thread David Howells
() returns any error incurred when getting the root inode. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/hfsplus/btree.c |6 -- fs/hfsplus/dir.c|6 +++--- fs/hfsplus/hfsplus_fs.h |3 +++ fs/hfsplus/super.c

[PATCH 19/31] IGET: Stop ISOFS from using read_inode() [try #3]

2007-10-10 Thread David Howells
Stop the ISOFS filesystem from using read_inode(). Make isofs_read_inode() return an error code, and make isofs_iget() pass it on. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/isofs/inode.c | 25 + 1 files changed, 17 insertions(+), 8 deletions(-)

[PATCH 20/31] IGET: Stop JFFS2 from using iget() and read_inode() [try #3]

2007-10-10 Thread David Howells
any error incurred when getting the root inode instead of EINVAL. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/jffs2/dir.c |6 +++-- fs/jffs2/fs.c | 56 --- fs/jffs2/os-linux.h |2 +- fs/jffs2/super.c|

[PATCH 21/31] IGET: Stop JFS from using iget() and read_inode() [try #3]

2007-10-10 Thread David Howells
incurred when getting the root inode instead of EINVAL. Signed-off-by: David Howells <[EMAIL PROTECTED]> Acked-by: Dave Kleikamp <[EMAIL PROTECTED]> --- fs/jfs/inode.c | 20 fs/jfs/jfs_inode.h |2 +- fs/jfs/namei.c | 34 ++

[PATCH 22/31] IGET: Stop the MINIX filesystem from using iget() and read_inode() [try #3]

2007-10-10 Thread David Howells
error incurred when getting the root inode instead of EINVAL. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/minix/inode.c | 43 +-- fs/minix/minix.h |1 + fs/minix/namei.c |7 +++ 3 files changed, 33 insertions(+), 18 del

[PATCH 24/31] IGET: Stop QNX4 from using iget() and read_inode() [try #3]

2007-10-10 Thread David Howells
incurred when getting the root inode instead of EINVAL. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/qnx4/inode.c | 45 ++--- fs/qnx4/namei.c |8 +--- include/linux/qnx4_fs.h |1 + 3 files changed, 36 inse

[PATCH 23/31] IGET: Stop PROCFS from using iget() and read_inode() [try #3]

2007-10-10 Thread David Howells
Stop the PROCFS filesystem from using iget() and read_inode(). Merge procfs_read_inode() into procfs_get_inode(), and have that call iget_locked() instead of iget(). Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/proc/inode.c

[PATCH 26/31] IGET: Stop the SYSV filesystem from using iget() and read_inode() [try #3]

2007-10-10 Thread David Howells
Stop the SYSV filesystem from using iget() and read_inode(). Replace sysv_read_inode() with sysv_iget(), and call that instead of iget(). sysv_iget() then uses iget_locked() directly and returns a proper error code instead of an inode in the event of an error. Signed-off-by: David Howells

[PATCH 25/31] IGET: Stop ROMFS from using iget() and read_inode() [try #3]

2007-10-10 Thread David Howells
error incurred when getting the root inode instead of EINVAL. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/romfs/inode.c | 45 +++-- 1 files changed, 31 insertions(+), 14 deletions(-) diff --git a/fs/romfs/inode.c b/fs/romfs/inode.c

[PATCH 27/31] IGET: Stop UFS from using iget() and read_inode() [try #3]

2007-10-10 Thread David Howells
incurred when getting the root inode instead of EINVAL. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/ufs/inode.c | 34 -- fs/ufs/namei.c |6 +++--- fs/ufs/super.c | 14 +- include/linux/ufs_fs.h |2 +- 4

[PATCH 28/31] IGET: Stop OPENPROMFS from using iget() and read_inode() [try #3]

2007-10-10 Thread David Howells
. openpromfs_fill_super() returns any error incurred when getting the root inode instead of ENOMEM (not that it currently incurs any other error). Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/openpromfs/inode.c | 45 ++--- 1 files changed, 30 inse

[PATCH 29/31] IGET: Stop HOSTFS from using iget() and read_inode() [try #3]

2007-10-10 Thread David Howells
inode number 0 - which forms the lookup key. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/hostfs/hostfs_kern.c | 58 --- 1 files changed, 39 insertions(+), 19 deletions(-) diff --git a/fs/hostfs/hostfs_kern.c b/fs/hostfs/hostfs_kern.c

[PATCH 30/31] IGET: Stop HPPFS from using iget() and read_inode() [try #3]

2007-10-10 Thread David Howells
f the inode goes away. (*) hppfs_iget() should perhaps subsume init_inode() and hppfs_read_inode(). (*) It would appear that all hppfs inodes are the same inode because iget() was being called with inode number 0, which forms the lookup key. Signed-off-by: David Howells <[EMAIL P

[PATCH 31/31] IGET: Remove iget() and the read_inode() super op as being obsolete [try #3]

2007-10-10 Thread David Howells
R(inode)) { ret = PTR_ERR(inode); goto error; } Note that is_bad_inode() does not need to be called. The error returned by thingyfs_iget() should render it unnecessary. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- Documentation/filesystems/Exp

Re: [PATCH 09/31] IGET: Stop BFS from using iget() and read_inode() [try #3]

2007-10-11 Thread David Howells
Roel Kluin <[EMAIL PROTECTED]> wrote: > > + if (IS_ERR(inode)) > > + return ERR_PTR(-ENOMEM); > > + if (!(inode->i_state & I_NEW)) > > + return inode; > > Don't you have to unlock_new_inode(inode) before returning? In the first case, no because an OOM error was returned r

[PATCH 25/31] IGET: Stop ROMFS from using iget() and read_inode() [try #4]

2007-10-12 Thread David Howells
error incurred when getting the root inode instead of EINVAL. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/romfs/inode.c | 45 +++-- 1 files changed, 31 insertions(+), 14 deletions(-) diff --git a/fs/romfs/inode.c b/fs/romfs/inode.c

[PATCH 24/31] IGET: Stop QNX4 from using iget() and read_inode() [try #4]

2007-10-12 Thread David Howells
incurred when getting the root inode instead of EINVAL. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/qnx4/inode.c | 45 ++--- fs/qnx4/namei.c |8 +--- include/linux/qnx4_fs.h |1 + 3 files changed, 36 inse

[PATCH 22/31] IGET: Stop the MINIX filesystem from using iget() and read_inode() [try #4]

2007-10-12 Thread David Howells
error incurred when getting the root inode instead of EINVAL. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/minix/inode.c | 43 +-- fs/minix/minix.h |1 + fs/minix/namei.c |7 +++ 3 files changed, 33 insertions(+), 18 del

[PATCH 16/31] IGET: Stop FreeVXFS from using iget() and read_inode() [try #4]

2007-10-12 Thread David Howells
error incurred when getting the root inode instead of EINVAL. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/freevxfs/vxfs_extern.h |2 +- fs/freevxfs/vxfs_inode.c | 45 + fs/freevxfs/vxfs_lookup.c |6 +++--- fs/freevxfs/vxfs_s

[PATCH 15/31] IGET: Stop FAT from using iget() and read_inode() [try #4]

2007-10-12 Thread David Howells
Stop the FAT filesystem from using iget() and read_inode(). Replace the call to iget() with a call to ilookup(). Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/fat/inode.c |6 ++ 1 files changed, 2 insertions(+), 4 deletions(-) diff --git a/fs/fat/inode.c b/fs/fat/i

[PATCH 13/31] IGET: Stop EXT3 from using iget() and read_inode() [try #4]

2007-10-12 Thread David Howells
incurred when getting the root inode instead of EINVAL. Signed-off-by: David Howells <[EMAIL PROTECTED]> Acked-by: "Theodore Ts'o" <[EMAIL PROTECTED]> Acked-by: Jan Kara <[EMAIL PROTECTED]> --- fs/ext3/ialloc.c| 58 ---

[PATCH 08/31] IGET: Stop BEFS from using iget() and read_inode() [try #4]

2007-10-12 Thread David Howells
incurred when getting the root inode instead of EINVAL. Signed-off-by: David Howells <[EMAIL PROTECTED]> Acked-by: Will Dyson <[EMAIL PROTECTED]> --- fs/befs/linuxvfs.c | 39 +-- 1 files changed, 25 insertions(+), 14 deletions(-) diff --g

[PATCH 04/31] IGET: Use iget_failed() in AFS [try #4]

2007-10-12 Thread David Howells
Use iget_failed() in AFS to kill a failed inode. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/afs/inode.c |5 + 1 files changed, 1 insertions(+), 4 deletions(-) diff --git a/fs/afs/inode.c b/fs/afs/inode.c index d196840..ca9b02f 100644 --- a/fs/afs/inode.c +++ b/

[PATCH 03/31] IGET: Introduce a function to register iget failure [try #4]

2007-10-12 Thread David Howells
Introduce a function to register failure in an inode construction path. This includes marking the inode under construction as bad, unlocking it and releasing it. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- Documentation/filesystems/porting | 18 +- fs/bad_i

[PATCH 02/31] Convert ERR_PTR(PTR_ERR(p)) instances to ERR_CAST(p) [try #4]

2007-10-12 Thread David Howells
Convert instances of ERR_PTR(PTR_ERR(p)) to ERR_CAST(p) using: perl -spi -e 's/ERR_PTR[(]PTR_ERR[(](.*)[)][)]/ERR_CAST(\1)/' `grep -rl 'ERR_PTR[(]*PTR_ERR' fs crypto net security` Signed-off-by: David Howells <[EMAIL PROTECTED]> --- crypto/cbc.c

[PATCH 01/31] Add an ERR_CAST() macro to complement ERR_PTR and co. [try #4]

2007-10-12 Thread David Howells
Add an ERR_CAST() macro to complement ERR_PTR and co. for the purposes of casting an error entyped as one pointer type to an error of another pointer type whilst making it explicit as to what is going on. This provides a replacement for the ERR_PTR(PTR_ERR(p)) construct. Signed-off-by: David

[PATCH 00/31] Remove iget() and read_inode() [try #4]

2007-10-12 Thread David Howells
Hi Linus, Here's a set of patches that remove all calls to iget() and all read_inode() functions. They should be removed for two reasons: firstly they don't lend themselves to good error handling, and secondly their presence is a temptation for code outside a filesystem to call iget() to access

[PATCH 31/31] IGET: Remove iget() and the read_inode() super op as being obsolete [try #4]

2007-10-12 Thread David Howells
R(inode)) { ret = PTR_ERR(inode); goto error; } Note that is_bad_inode() does not need to be called. The error returned by thingyfs_iget() should render it unnecessary. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- Documentation/filesystems/Exp

[PATCH 30/31] IGET: Stop HPPFS from using iget() and read_inode() [try #4]

2007-10-12 Thread David Howells
f the inode goes away. (*) hppfs_iget() should perhaps subsume init_inode() and hppfs_read_inode(). (*) It would appear that all hppfs inodes are the same inode because iget() was being called with inode number 0, which forms the lookup key. Signed-off-by: David Howells <[EMAIL P

[PATCH 28/31] IGET: Stop OPENPROMFS from using iget() and read_inode() [try #4]

2007-10-12 Thread David Howells
. openpromfs_fill_super() returns any error incurred when getting the root inode instead of ENOMEM (not that it currently incurs any other error). Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/openpromfs/inode.c | 45 ++--- 1 files changed, 30 inse

[PATCH 27/31] IGET: Stop UFS from using iget() and read_inode() [try #4]

2007-10-12 Thread David Howells
incurred when getting the root inode instead of EINVAL. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/ufs/inode.c | 34 -- fs/ufs/namei.c |6 +++--- fs/ufs/super.c | 14 +- include/linux/ufs_fs.h |2 +- 4

[PATCH 26/31] IGET: Stop the SYSV filesystem from using iget() and read_inode() [try #4]

2007-10-12 Thread David Howells
Stop the SYSV filesystem from using iget() and read_inode(). Replace sysv_read_inode() with sysv_iget(), and call that instead of iget(). sysv_iget() then uses iget_locked() directly and returns a proper error code instead of an inode in the event of an error. Signed-off-by: David Howells

[PATCH 23/31] IGET: Stop PROCFS from using iget() and read_inode() [try #4]

2007-10-12 Thread David Howells
Stop the PROCFS filesystem from using iget() and read_inode(). Merge procfs_read_inode() into procfs_get_inode(), and have that call iget_locked() instead of iget(). Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/proc/inode.c

[PATCH 20/31] IGET: Stop JFFS2 from using iget() and read_inode() [try #4]

2007-10-12 Thread David Howells
any error incurred when getting the root inode instead of EINVAL. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/jffs2/dir.c |6 +++-- fs/jffs2/fs.c | 56 --- fs/jffs2/os-linux.h |2 +- fs/jffs2/super.c|

[PATCH 19/31] IGET: Stop ISOFS from using read_inode() [try #4]

2007-10-12 Thread David Howells
Stop the ISOFS filesystem from using read_inode(). Make isofs_read_inode() return an error code, and make isofs_iget() pass it on. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/isofs/inode.c | 25 + 1 files changed, 17 insertions(+), 8 deletions(-)

[PATCH 18/31] IGET: Stop HFSPLUS from using iget() and read_inode() [try #4]

2007-10-12 Thread David Howells
() returns any error incurred when getting the root inode. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/hfsplus/btree.c |6 -- fs/hfsplus/dir.c|6 +++--- fs/hfsplus/hfsplus_fs.h |3 +++ fs/hfsplus/super.c

[PATCH 17/31] IGET: Stop FUSE from using iget() and read_inode() [try #4]

2007-10-12 Thread David Howells
Stop the FUSE filesystem from using read_inode(), which it doesn't use anyway. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/fuse/inode.c |6 -- 1 files changed, 0 insertions(+), 6 deletions(-) diff --git a/fs/fuse/inode.c b/fs/fuse/inode.c index 5448f62..2986654 1

[PATCH 11/31] IGET: Stop EFS from using iget() and read_inode() [try #4]

2007-10-12 Thread David Howells
incurred when getting the root inode instead of EACCES. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/efs/inode.c | 25 + fs/efs/namei.c | 23 --- fs/efs/super.c | 18 -- include/linux/efs_fs.h

[PATCH 10/31] IGET: Stop CIFS from using iget() and read_inode() [try #4]

2007-10-12 Thread David Howells
error incurred when getting the root inode instead of ENOMEM. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/cifs/cifsfs.c |8 fs/cifs/cifsfs.h |1 + fs/cifs/inode.c | 35 ++- 3 files changed, 31 insertions(+), 13 deletions(-)

[PATCH 09/31] IGET: Stop BFS from using iget() and read_inode() [try #4]

2007-10-12 Thread David Howells
incurred when getting the root inode instead of EINVAL. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/bfs/bfs.h |2 ++ fs/bfs/dir.c |6 +++--- fs/bfs/inode.c | 32 ++-- 3 files changed, 27 insertions(+), 13 deletions(-) diff --git a/fs/bfs/b

[PATCH 06/31] IGET: Stop AFFS from using iget() and read_inode() [try #4]

2007-10-12 Thread David Howells
incurred when getting the root inode instead of EINVAL. Signed-off-by: David Howells <[EMAIL PROTECTED]> --- fs/affs/affs.h |2 +- fs/affs/amigaffs.c |6 -- fs/affs/inode.c| 20 +--- fs/affs/namei.c| 10 -- fs/affs/super.c

<    1   2   3   4   5   6   >