linux-uconsole/fs/notify
Miklos Szeredi a9680ece8e fsnotify: don't BUG in fsnotify_destroy_mark()
commit fed474857e upstream.

Removing the parent of a watched file results in "kernel BUG at
fs/notify/mark.c:139".

To reproduce

  add "-w /tmp/audit/dir/watched_file" to audit.rules
  rm -rf /tmp/audit/dir

This is caused by fsnotify_destroy_mark() being called without an
extra reference taken by the caller.

Reported by Francesco Cosoleto here:

  https://bugzilla.novell.com/show_bug.cgi?id=689860

Fix by removing the BUG_ON and adding a comment about not accessing mark after
the iput.

Signed-off-by: Miklos Szeredi <mszeredi@suse.cz>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2012-01-25 17:24:49 -08:00
..
dnotify fanotify: use both marks when possible 2010-07-28 10:18:55 -04:00
fanotify Fix common misspellings 2011-03-31 11:26:23 -03:00
inotify Merge branch 'for-linus2' of git://git.profusion.mobi/users/lucas/linux-2.6 2011-04-07 11:14:49 -07:00
fsnotify.c fs: dcache per-inode inode alias locking 2011-01-07 17:50:31 +11:00
fsnotify.h fsnotify: remove global fsnotify groups lists 2010-07-28 10:18:54 -04:00
group.c fsnotify: remove global fsnotify groups lists 2010-07-28 10:18:54 -04:00
inode_mark.c fs: rename inode_lock to inode_hash_lock 2011-03-24 21:17:51 -04:00
Kconfig fanotify: allow fanotify to be built 2010-10-28 17:22:13 -04:00
Makefile fsnotify: vfsmount marks generic functions 2010-07-28 09:58:57 -04:00
mark.c fsnotify: don't BUG in fsnotify_destroy_mark() 2012-01-25 17:24:49 -08:00
notification.c Revert "fsnotify: store struct file not struct path" 2010-08-12 14:23:04 -07:00
vfsmount_mark.c fs: rename inode_lock to inode_hash_lock 2011-03-24 21:17:51 -04:00