From 2be3c79046cf90d75d436708a4e0898c7a1f9d51 Mon Sep 17 00:00:00 2001 From: Christoph Hellwig Date: Tue, 20 Feb 2007 13:58:11 -0800 Subject: [PATCH] affs: implement ->drop_inode affs wants to truncate the inode when the last user goes away, currently it does that through a potentially racy i_count check in ->put_inode. But we already have a method that's called just after the we dropped the last reference, ->drop_inode. This patch implements affs_drop_inode to take advantage of this. Signed-off-by: Christoph Hellwig Cc: Roman Zippel Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- fs/affs/affs.h | 1 + 1 file changed, 1 insertion(+) (limited to 'fs/affs/affs.h') diff --git a/fs/affs/affs.h b/fs/affs/affs.h index 7db2d287e9f..232c6949368 100644 --- a/fs/affs/affs.h +++ b/fs/affs/affs.h @@ -171,6 +171,7 @@ extern unsigned long affs_parent_ino(struct inode *dir); extern struct inode *affs_new_inode(struct inode *dir); extern int affs_notify_change(struct dentry *dentry, struct iattr *attr); extern void affs_put_inode(struct inode *inode); +extern void affs_drop_inode(struct inode *inode); extern void affs_delete_inode(struct inode *inode); extern void affs_clear_inode(struct inode *inode); extern void affs_read_inode(struct inode *inode); -- cgit v1.2.2