]> bbs.cooldavid.org Git - net-next-2.6.git/blobdiff - fs/open.c
kbuild: fix oldnoconfig to do the right thing
[net-next-2.6.git] / fs / open.c
index 0d1fa3dc0efb53f0f42051d4dde9ac4a4503c876..630715f9f73d0e9ae4370a339eb5163a8bb55ca0 100644 (file)
--- a/fs/open.c
+++ b/fs/open.c
@@ -29,6 +29,7 @@
 #include <linux/falloc.h>
 #include <linux/fs_struct.h>
 #include <linux/ima.h>
+#include <linux/dnotify.h>
 
 #include "internal.h"
 
@@ -887,7 +888,7 @@ long do_sys_open(int dfd, const char __user *filename, int flags, int mode)
                                put_unused_fd(fd);
                                fd = PTR_ERR(f);
                        } else {
-                               fsnotify_open(f->f_path.dentry);
+                               fsnotify_open(f);
                                fd_install(fd, f);
                        }
                }
@@ -1030,7 +1031,9 @@ EXPORT_SYMBOL(generic_file_open);
 
 /*
  * This is used by subsystems that don't want seekable
- * file descriptors
+ * file descriptors. The function is not supposed to ever fail, the only
+ * reason it returns an 'int' and not 'void' is so that it can be plugged
+ * directly into file_operations structure.
  */
 int nonseekable_open(struct inode *inode, struct file *filp)
 {