vfs: split generic_forget_inode() so that hugetlbfs does not have to copy it
authorJan Kara <jack@suse.cz>
Fri, 18 Sep 2009 20:05:44 +0000 (13:05 -0700)
committerAl Viro <viro@zeniv.linux.org.uk>
Thu, 24 Sep 2009 11:47:25 +0000 (07:47 -0400)
commit22fe404218156328a27e66349b1175cd0baa4990
treef03f8eb0b346a6950815212a5fa86c6b7e65bd16
parentaf0d9ae811d11de8a01d6bc922c5e062be01bd7f
vfs: split generic_forget_inode() so that hugetlbfs does not have to copy it

Hugetlbfs needs to do special things instead of truncate_inode_pages().
 Currently, it copied generic_forget_inode() except for
truncate_inode_pages() call which is asking for trouble (the code there
isn't trivial).  So create a separate function generic_detach_inode()
which does all the list magic done in generic_forget_inode() and call
it from hugetlbfs_forget_inode().

Signed-off-by: Jan Kara <jack@suse.cz>
Cc: Al Viro <viro@zeniv.linux.org.uk>
Cc: Christoph Hellwig <hch@lst.de>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
fs/hugetlbfs/inode.c
fs/inode.c
include/linux/fs.h