From: Andrew Morton <akpm@linux-foundation.org>
To: Chris Goldsworthy <cgoldswo@codeaurora.org>
Cc: linux-mm@kvack.org, linux-arm-msm@vger.kernel.org,
linux-kernel@vger.kernel.org, pratikp@codeaurora.org,
pdaly@codeaurora.org, sudraja@codeaurora.org,
iamjoonsoo.kim@lge.com
Subject: Re: cma_alloc(), add sleep-and-retry for temporary page pinning
Date: Thu, 6 Aug 2020 18:31:41 -0700 [thread overview]
Message-ID: <20200806183141.14a4fb8d210d3bdec68e1e7f@linux-foundation.org> (raw)
In-Reply-To: <1596682582-29139-1-git-send-email-cgoldswo@codeaurora.org>
On Wed, 5 Aug 2020 19:56:21 -0700 Chris Goldsworthy <cgoldswo@codeaurora.org> wrote:
> On mobile devices, failure to allocate from a CMA area constitutes a
> functional failure. Sometimes during CMA allocations, we have observed
> that pages in a CMA area allocated through alloc_pages(), that we're trying
> to migrate away to make room for a CMA allocation, are temporarily pinned.
> This temporary pinning can occur when a process that owns the pinned page
> is being forked (the example is explained further in the commit text).
> This patch addresses this issue by adding a sleep-and-retry loop in
> cma_alloc() . There's another example we know of similar to the above that
> occurs during exit_mmap() (in zap_pte_range() specifically), but I need to
> determine if this is still relevant today.
Sounds fairly serious but boy, we're late for 5.9.
I can queue it for 5.10 with a cc:stable so that it gets backported
into earlier kernels a couple of months from now, if we think the
seriousness justifies backporting(?).
Or I can do something else - thoughts?
And... it really is a sad little patch, isn't it? Instead of fixing
the problem, it reduces the problem's probability by 5x. Can't we do
better than this?
next prev parent reply other threads:[~2020-08-07 1:31 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-08-06 2:56 Chris Goldsworthy
2020-08-06 2:56 ` [PATCH] mm: cma: retry allocations in cma_alloc Chris Goldsworthy
2020-08-07 1:31 ` Andrew Morton [this message]
2020-08-11 22:20 cma_alloc(), add sleep-and-retry for temporary page pinning cgoldswo
2020-08-21 4:17 ` cgoldswo
2020-08-21 22:01 ` Andrew Morton
2020-09-11 18:39 ` Chris Goldsworthy
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=20200806183141.14a4fb8d210d3bdec68e1e7f@linux-foundation.org \
--to=akpm@linux-foundation.org \
--cc=cgoldswo@codeaurora.org \
--cc=iamjoonsoo.kim@lge.com \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=pdaly@codeaurora.org \
--cc=pratikp@codeaurora.org \
--cc=sudraja@codeaurora.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