From: Vlastimil Babka <vbabka@suse.cz>
To: Mike Kravetz <mike.kravetz@oracle.com>,
"linux-mm@kvack.org" <linux-mm@kvack.org>
Cc: 'Joonsoo Kim' <iamjoonsoo.kim@lge.com>,
Laura Abbott <labbott@redhat.com>
Subject: Re: freepage accounting bug with CMA/migrate isolation
Date: Thu, 26 Jul 2018 23:26:33 +0200 [thread overview]
Message-ID: <78329b64-0101-e1bd-1f7a-5194c56053b1@suse.cz> (raw)
In-Reply-To: <fb90a412-ead7-0ada-c443-2bd1c41f2614@oracle.com>
On 07/26/2018 06:50 PM, Mike Kravetz wrote:
> On 07/26/2018 05:28 AM, Vlastimil Babka wrote:
>>> Just looking for suggesting in where/how to debug. I've been hacking on
>>> this without much success.
>
> As mentioned in my reply to Laura, I noticed that move_freepages_block()
> can move more than a pageblock of pages. This is the case where page_order
> of the (first) free page is > pageblock_order. Should only happen in the
> set_migratetype_isolate case as unset has that check you added. Thi
Hmm not sure which "check I added" you mean, in
unset_migratetype_isolate() ?
> generally 'works' as alloc_contig_range rounds up to MAX_ORDER(-1). So,
> set and unset migrate isolate tend to balance out. But, I am wondering
> if there might be some kind of race where someone could mess with those
> pageblocks (and freepage counts) while we drop the zone lock. Trying to
Yeah see my other mail for such race when we drop the zone lock in
unset_migratetype_isolate(). set_migratetype_isolate() would also have
this problem (which would result in *less* freepages counted), but if we
move MAX_ORDER-1 pages to MIGRATE_ISOLATE freelist, then nobody can mess
with them while the zone is locked, as they are isolated.
unset_migratetype_isolate() has no such luck.
> put together a quick hack to test this theory, but it is more complicated
> that first thought. :)
>
next prev parent reply other threads:[~2018-07-26 21:28 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-07-24 4:24 Mike Kravetz
2018-07-24 22:38 ` Laura Abbott
2018-07-25 0:46 ` Mike Kravetz
2018-07-26 12:28 ` Vlastimil Babka
2018-07-26 16:50 ` Mike Kravetz
2018-07-26 21:26 ` Vlastimil Babka [this message]
2018-07-26 13:30 ` Vlastimil Babka
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=78329b64-0101-e1bd-1f7a-5194c56053b1@suse.cz \
--to=vbabka@suse.cz \
--cc=iamjoonsoo.kim@lge.com \
--cc=labbott@redhat.com \
--cc=linux-mm@kvack.org \
--cc=mike.kravetz@oracle.com \
/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