mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-30 03:27:44 -04:00
untangle fsnotify_d_instantiate() a bit
First of all, don't bother calling it if inode is NULL - that makes inode argument unused. Moreover, do it *before* dropping ->d_lock, not right after that (and don't bother grabbing ->d_lock in it, of course). Signed-off-by: Al Viro <[email protected]>
This commit is contained in:
parent
34d0d19dc0
commit
27f203f655
3 changed files with 4 additions and 17 deletions
|
|
@ -1750,8 +1750,9 @@ static void __d_instantiate(struct dentry *dentry, struct inode *inode)
|
|||
raw_write_seqcount_begin(&dentry->d_seq);
|
||||
__d_set_inode_and_type(dentry, inode, add_flags);
|
||||
raw_write_seqcount_end(&dentry->d_seq);
|
||||
if (inode)
|
||||
__fsnotify_d_instantiate(dentry);
|
||||
spin_unlock(&dentry->d_lock);
|
||||
fsnotify_d_instantiate(dentry, inode);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Reference in a new issue