From: Mel Gorman <mgorman@techsingularity.net>
To: Qian Cai <cai@lca.pw>
Cc: vbabka@suse.cz, Linux-MM <linux-mm@kvack.org>
Subject: Re: low-memory crash with patch "capture a page under direct compaction"
Date: Wed, 6 Mar 2019 09:13:19 +0000 [thread overview]
Message-ID: <20190306091319.GJ9565@techsingularity.net> (raw)
In-Reply-To: <5eecbceb-2522-c880-7d6a-af20cf548500@lca.pw>
On Tue, Mar 05, 2019 at 10:14:29PM -0500, Qian Cai wrote:
> I don't understand this part.
>
> @@ -2279,14 +2286,24 @@ static enum compact_result compact_zone_order(struct
> zone *zone, int order,
> .ignore_skip_hint = (prio == MIN_COMPACT_PRIORITY),
> .ignore_block_suitable = (prio == MIN_COMPACT_PRIORITY)
> };
> + struct capture_control capc = {
> + .cc = &cc,
> + .page = NULL,
> + };
> +
> + if (capture)
> + current->capture_control = &capc;
>
>
> That check will always be true as it is,
>
It's a defensive check allowing for the possibility that
try_to_compact_pages() is passed NULL. Originally the structure was
different but I preserved the NULL check to avoid potential surprises.
It could be changed but I don't think it'll help. I aim to setup a machine
with your config today, try again to reproduce the problem and look at
the patch again to see can I spot how it could corrupt anything.
--
Mel Gorman
SUSE Labs
prev parent reply other threads:[~2019-03-06 9:13 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-03-05 3:55 low-memory crash with patch "capture a page under direct compaction" Qian Cai
2019-03-05 14:42 ` Mel Gorman
2019-03-05 15:13 ` Qian Cai
2019-03-05 15:27 ` Mel Gorman
2019-03-06 3:01 ` Qian Cai
2019-03-06 3:14 ` Qian Cai
2019-03-06 9:13 ` Mel Gorman [this message]
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=20190306091319.GJ9565@techsingularity.net \
--to=mgorman@techsingularity.net \
--cc=cai@lca.pw \
--cc=linux-mm@kvack.org \
--cc=vbabka@suse.cz \
/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).