Skip to content

Commit

Permalink
audit: convert audit watches to use fsnotify instead of inotify
Browse files Browse the repository at this point in the history
Audit currently uses inotify to pin inodes in core and to detect when
watched inodes are deleted or unmounted.  This patch uses fsnotify instead
of inotify.

Signed-off-by: Eric Paris <eparis@redhat.com>
  • Loading branch information
eparis committed Jul 28, 2010
1 parent ae7b8f4 commit e9fd702
Show file tree
Hide file tree
Showing 2 changed files with 152 additions and 61 deletions.
5 changes: 4 additions & 1 deletion include/linux/fsnotify_backend.h
Original file line number Diff line number Diff line change
Expand Up @@ -58,9 +58,12 @@
FS_MOVED_FROM | FS_MOVED_TO | FS_CREATE |\
FS_DELETE)

#define FS_MOVE (FS_MOVED_FROM | FS_MOVED_TO)

/* listeners that hard code group numbers near the top */
#define DNOTIFY_GROUP_NUM UINT_MAX
#define INOTIFY_GROUP_NUM (DNOTIFY_GROUP_NUM-1)
#define AUDIT_WATCH_GROUP_NUM (DNOTIFY_GROUP_NUM-1)
#define INOTIFY_GROUP_NUM (AUDIT_WATCH_GROUP_NUM-1)

struct fsnotify_group;
struct fsnotify_event;
Expand Down
Loading

0 comments on commit e9fd702

Please sign in to comment.