From: Ted Ts'o <tytso@mit.edu>
To: Jan Kara <jack@suse.cz>
Cc: Andy Lutomirski <luto@amacapital.net>,
Andreas Dilger <adilger@dilger.ca>,
linux-kernel@vger.kernel.org, linux-mm@kvack.org,
linux-fsdevel@vger.kernel.org, linux-ext4@vger.kernel.org
Subject: Re: [PATCH] mm: Improve cmtime update on shared writable mmaps
Date: Wed, 2 Nov 2011 11:19:03 -0400 [thread overview]
Message-ID: <20111102151903.GA15045@thunk.org> (raw)
In-Reply-To: <20111102150200.GC31575@quack.suse.cz>
On Wed, Nov 02, 2011 at 04:02:00PM +0100, Jan Kara wrote:
> That's a good question. Locking of i_flags was always kind of unclear to
> me. They are certainly read without any locks and in the couple of places
> where setting can actually race VFS uses i_mutex for serialization which is
> kind of overkill (and unusable from page fault due to locking constraints).
> Probably using atomic bitops for setting i_flags would be needed.
Adding a set of inode_{test,set,clear}_flag() inline functions, and
then converting accesses of i_flags to use them would be a great
cleanup task. It's been on my mental todo list for a while, but it's
a pretty invasive change. What we have right now is definitely racy,
though, and we only get away with it because i_flags changes happen
relatively rarely. Fixing this would be definitely be a Good Thing.
- Ted
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Fight unfair telecom internet charges in Canada: sign http://stopthemeter.ca/
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
WARNING: multiple messages have this Message-ID (diff)
From: "Ted Ts'o" <tytso@mit.edu>
To: Jan Kara <jack@suse.cz>
Cc: Andy Lutomirski <luto@amacapital.net>,
Andreas Dilger <adilger@dilger.ca>,
linux-kernel@vger.kernel.org, linux-mm@kvack.org,
linux-fsdevel@vger.kernel.org, linux-ext4@vger.kernel.org
Subject: Re: [PATCH] mm: Improve cmtime update on shared writable mmaps
Date: Wed, 2 Nov 2011 11:19:03 -0400 [thread overview]
Message-ID: <20111102151903.GA15045@thunk.org> (raw)
In-Reply-To: <20111102150200.GC31575@quack.suse.cz>
On Wed, Nov 02, 2011 at 04:02:00PM +0100, Jan Kara wrote:
> That's a good question. Locking of i_flags was always kind of unclear to
> me. They are certainly read without any locks and in the couple of places
> where setting can actually race VFS uses i_mutex for serialization which is
> kind of overkill (and unusable from page fault due to locking constraints).
> Probably using atomic bitops for setting i_flags would be needed.
Adding a set of inode_{test,set,clear}_flag() inline functions, and
then converting accesses of i_flags to use them would be a great
cleanup task. It's been on my mental todo list for a while, but it's
a pretty invasive change. What we have right now is definitely racy,
though, and we only get away with it because i_flags changes happen
relatively rarely. Fixing this would be definitely be a Good Thing.
- Ted
next prev parent reply other threads:[~2011-11-02 15:19 UTC|newest]
Thread overview: 49+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-10-20 0:39 Latency writing to an mlocked ext4 mapping Andy Lutomirski
2011-10-20 0:39 ` Andy Lutomirski
2011-10-20 1:02 ` Andreas Dilger
2011-10-20 1:02 ` Andreas Dilger
2011-10-20 1:15 ` Andy Lutomirski
2011-10-20 1:15 ` Andy Lutomirski
2011-10-20 2:17 ` Andy Lutomirski
2011-10-20 2:17 ` Andy Lutomirski
2011-10-20 2:17 ` Andy Lutomirski
2011-10-20 5:59 ` Andy Lutomirski
2011-10-20 5:59 ` Andy Lutomirski
2011-10-20 5:59 ` Andy Lutomirski
2011-10-25 12:26 ` Jan Kara
2011-10-25 12:26 ` Jan Kara
2011-10-25 12:26 ` Jan Kara
2011-10-28 23:37 ` Andy Lutomirski
2011-10-28 23:37 ` Andy Lutomirski
2011-10-28 23:39 ` [PATCH] mm: Improve cmtime update on shared writable mmaps Andy Lutomirski
2011-10-28 23:39 ` Andy Lutomirski
2011-11-01 22:53 ` Jan Kara
2011-11-01 22:53 ` Jan Kara
2011-11-01 23:02 ` Andy Lutomirski
2011-11-01 23:02 ` Andy Lutomirski
2011-11-01 23:02 ` Andy Lutomirski
2011-11-02 7:38 ` Christoph Hellwig
2011-11-02 7:38 ` Christoph Hellwig
2011-11-02 15:02 ` Jan Kara
2011-11-02 15:02 ` Jan Kara
2011-11-02 15:02 ` Jan Kara
2011-11-02 15:19 ` Ted Ts'o [this message]
2011-11-02 15:19 ` Ted Ts'o
2011-10-31 23:10 ` Latency writing to an mlocked ext4 mapping Jan Kara
2011-10-31 23:10 ` Jan Kara
2011-10-31 23:10 ` Jan Kara
2011-10-31 23:14 ` Andy Lutomirski
2011-10-31 23:14 ` Andy Lutomirski
2011-10-31 23:14 ` Andy Lutomirski
2011-11-01 23:03 ` Jan Kara
2011-11-01 23:03 ` Jan Kara
2011-11-01 23:03 ` Jan Kara
2011-11-01 23:10 ` Andy Lutomirski
2011-11-01 23:10 ` Andy Lutomirski
2011-11-01 23:10 ` Andy Lutomirski
2011-11-02 1:51 ` Andy Lutomirski
2011-11-02 1:51 ` Andy Lutomirski
2011-11-02 1:51 ` Andy Lutomirski
2011-11-02 20:17 ` Jan Kara
2011-11-02 20:17 ` Jan Kara
2011-11-02 20:17 ` Jan Kara
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=20111102151903.GA15045@thunk.org \
--to=tytso@mit.edu \
--cc=adilger@dilger.ca \
--cc=jack@suse.cz \
--cc=linux-ext4@vger.kernel.org \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=luto@amacapital.net \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.