linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
* cma_alloc(), add sleep-and-retry for temporary page pinning
@ 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 ` cma_alloc(), add sleep-and-retry for temporary page pinning Andrew Morton
  0 siblings, 2 replies; 3+ messages in thread
From: Chris Goldsworthy @ 2020-08-06  2:56 UTC (permalink / raw)
  To: akpm
  Cc: linux-mm, linux-arm-msm, linux-kernel, pratikp, pdaly, sudraja,
	iamjoonsoo.kim

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.



^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2020-08-07  1:31 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-08-06  2:56 cma_alloc(), add sleep-and-retry for temporary page pinning Chris Goldsworthy
2020-08-06  2:56 ` [PATCH] mm: cma: retry allocations in cma_alloc Chris Goldsworthy
2020-08-07  1:31 ` cma_alloc(), add sleep-and-retry for temporary page pinning Andrew Morton

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox