From: OGAWA Hirofumi <hirofumi@mail.parknet.co.jp>
To: John McCutchan <john@johnmccutchan.com>,
Robert Love <rlove@rlove.org>, Eric Paris <eparis@redhat.com>
Cc: linux-kernel@vger.kernel.org, linux-fsdevel@vger.kernel.org
Subject: Race inotify_rm_watch vs umount
Date: Fri, 10 Jun 2011 20:20:55 +0900 [thread overview]
Message-ID: <87r572nd9k.fsf@devron.myhome.or.jp> (raw)
Hi,
I'm looking the race inotify_rm_watch() vs umount(). This race become the
cause of Oops. You can see the oops at
https://bugzilla.kernel.org/show_bug.cgi?id=22602
So, what race?
umount inotify_rm_watch
... fsnotify_destroy_mark()
fsnotify_destroy_inode_mark()
/* removed from i_fsnotify_marks */
generic_shutdown_super()
fsnotify_unmount_inodes()
put_super()
iput()
iput_final()
/* this is after put_super() */
Like above, inotify doesn't guarantee to call final iput() before
put_super(). With this violation, FS driver can oops.
Well, so, what are requested for inotify? We can't simply take
sb->s_umount in inotify_rm_watch()?
Any ideas?
Thanks.
--
OGAWA Hirofumi <hirofumi@mail.parknet.co.jp>
next reply other threads:[~2011-06-10 11:21 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-06-10 11:20 OGAWA Hirofumi [this message]
2011-06-10 13:46 ` Eric Paris
2011-06-10 14:35 ` Al Viro
[not found] ` <CAGHUO11rNGU9VMAPQNdXtpQeAixFX6zxJc-tWur1McqbpYpYpQ@mail.gmail.com>
2012-03-06 21:09 ` Joseph Salisbury
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87r572nd9k.fsf@devron.myhome.or.jp \
--to=hirofumi@mail.parknet.co.jp \
--cc=eparis@redhat.com \
--cc=john@johnmccutchan.com \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=rlove@rlove.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Powered by JetHome