aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/inotify.h
diff options
context:
space:
mode:
authorEric Paris <eparis@redhat.com>2010-07-28 10:18:37 -0400
committerEric Paris <eparis@redhat.com>2010-07-28 10:18:49 -0400
commitf874e1ac21d7708464dc656a10312542c54719f1 (patch)
treebe47a1f5333208647e016f1861eaf21fb963478b /include/linux/inotify.h
parent8c1934c8d70b22ca8333b216aec6c7d09fdbd6a6 (diff)
inotify: force inotify and fsnotify use same bits
inotify uses bits called IN_* and fsnotify uses bits called FS_*. These need to line up. This patch adds build time checks to make sure noone can change these bits so they are not the same. Signed-off-by: Eric Paris <eparis@redhat.com>
Diffstat (limited to 'include/linux/inotify.h')
-rw-r--r--include/linux/inotify.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/include/linux/inotify.h b/include/linux/inotify.h
index b74f2ef2c368..d33041e2a42a 100644
--- a/include/linux/inotify.h
+++ b/include/linux/inotify.h
@@ -73,6 +73,15 @@ struct inotify_event {
73#ifdef __KERNEL__ 73#ifdef __KERNEL__
74#include <linux/sysctl.h> 74#include <linux/sysctl.h>
75extern struct ctl_table inotify_table[]; /* for sysctl */ 75extern struct ctl_table inotify_table[]; /* for sysctl */
76
77#define ALL_INOTIFY_BITS (IN_ACCESS | IN_MODIFY | IN_ATTRIB | IN_CLOSE_WRITE | \
78 IN_CLOSE_NOWRITE | IN_OPEN | IN_MOVED_FROM | \
79 IN_MOVED_TO | IN_CREATE | IN_DELETE | \
80 IN_DELETE_SELF | IN_MOVE_SELF | IN_UNMOUNT | \
81 IN_Q_OVERFLOW | IN_IGNORED | IN_ONLYDIR | \
82 IN_DONT_FOLLOW | IN_EXCL_UNLINK | IN_MASK_ADD | \
83 IN_ISDIR | IN_ONESHOT)
84
76#endif 85#endif
77 86
78#endif /* _LINUX_INOTIFY_H */ 87#endif /* _LINUX_INOTIFY_H */