new helper: file_inode(file)
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
diff --git a/include/linux/fsnotify.h b/include/linux/fsnotify.h
index 0fbfb46..a78680a 100644
--- a/include/linux/fsnotify.h
+++ b/include/linux/fsnotify.h
@@ -244,7 +244,7 @@
static inline void fsnotify_close(struct file *file)
{
struct path *path = &file->f_path;
- struct inode *inode = file->f_path.dentry->d_inode;
+ struct inode *inode = file_inode(file);
fmode_t mode = file->f_mode;
__u32 mask = (mode & FMODE_WRITE) ? FS_CLOSE_WRITE : FS_CLOSE_NOWRITE;