From: "Amir G." <amir73il@users.sourceforge.net>
To: Andreas Dilger <adilger@dilger.ca>
Cc: Theodore Tso <tytso@mit.edu>,
"Aneesh Kumar K.V" <aneesh.kumar@linux.vnet.ibm.com>,
Ext4 Developers List <linux-ext4@vger.kernel.org>
Subject: Re: [PATCH][RFC] ext4: avoid taking down_read(&grp->alloc_sem)
Date: Mon, 14 Feb 2011 20:18:11 +0200 [thread overview]
Message-ID: <AANLkTimxw0e37XbwW8PwXgLEyCEC2zH_wThCjBpbsEhm@mail.gmail.com> (raw)
In-Reply-To: <2D97EC87-86D8-41D9-8779-BB4A48E60E89@dilger.ca>
On Mon, Feb 14, 2011 at 6:30 PM, Andreas Dilger <adilger@dilger.ca> wrote:
> On 2011-02-14, at 0:52, "Amir G." <amir73il@users.sourceforge.net> wrote:
>>> @@ -1160,7 +1160,15 @@ ext4_mb_load_buddy(struct super_block *sb,
>>>
>>> + /*
>>> + * We only need to take the read lock if other groups share the buddy
>>> + * page with this group or if blocks may be added to this (last) group
>>> + * by ext4_group_extend().
>>> + */
>>> + if (blocks_per_page > 2 || group == sbi->s_groups_count - 1)
>>> + e4b->alloc_semp = &grp->alloc_sem;
>
> No comment on whether this change is safe or not, but shouldn't this check be:
>
> if (blocks_per_page > 1 ||
>
No, it should be groups_per_page > 1, as Aneesh suggested,
which translates to blocks_per_group > 2, but this is obviously not
clear from the code...
--
To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
next prev parent reply other threads:[~2011-02-14 18:18 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-02-09 10:05 [PATCH][RFC] ext4: avoid taking down_read(&grp->alloc_sem) Amir G.
2011-02-14 7:52 ` Amir G.
2011-02-14 16:30 ` Andreas Dilger
2011-02-14 18:18 ` Amir G. [this message]
2011-02-14 9:34 ` Aneesh Kumar K. V
2011-02-14 12:08 ` Amir G.
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=AANLkTimxw0e37XbwW8PwXgLEyCEC2zH_wThCjBpbsEhm@mail.gmail.com \
--to=amir73il@users.sourceforge.net \
--cc=adilger@dilger.ca \
--cc=aneesh.kumar@linux.vnet.ibm.com \
--cc=linux-ext4@vger.kernel.org \
--cc=tytso@mit.edu \
/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;
as well as URLs for NNTP newsgroup(s).