forked from luck/tmp_suning_uos_patched
vfs: turn generic_drop_inode() into static inline
Once upon a time it used to be much bigger, but these days there's no point whatsoever keeping it in fs/inode.c, especially since it's not even needed as initializer for ->drop_inode() - it's the default and leaving ->drop_inode NULL will do just as well. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
This commit is contained in:
parent
e28e832c3e
commit
9bcb4b733c
11
fs/inode.c
11
fs/inode.c
|
@ -1368,17 +1368,6 @@ int generic_delete_inode(struct inode *inode)
|
|||
}
|
||||
EXPORT_SYMBOL(generic_delete_inode);
|
||||
|
||||
/*
|
||||
* Normal UNIX filesystem behaviour: delete the
|
||||
* inode when the usage count drops to zero, and
|
||||
* i_nlink is zero.
|
||||
*/
|
||||
int generic_drop_inode(struct inode *inode)
|
||||
{
|
||||
return !inode->i_nlink || inode_unhashed(inode);
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(generic_drop_inode);
|
||||
|
||||
/*
|
||||
* Called when we're dropping the last reference
|
||||
* to an inode.
|
||||
|
|
|
@ -2305,7 +2305,10 @@ extern struct inode * igrab(struct inode *);
|
|||
extern ino_t iunique(struct super_block *, ino_t);
|
||||
extern int inode_needs_sync(struct inode *inode);
|
||||
extern int generic_delete_inode(struct inode *inode);
|
||||
extern int generic_drop_inode(struct inode *inode);
|
||||
static inline int generic_drop_inode(struct inode *inode)
|
||||
{
|
||||
return !inode->i_nlink || inode_unhashed(inode);
|
||||
}
|
||||
|
||||
extern struct inode *ilookup5_nowait(struct super_block *sb,
|
||||
unsigned long hashval, int (*test)(struct inode *, void *),
|
||||
|
|
Loading…
Reference in New Issue
Block a user