Re: [PATCH v2 1/4] mm/page_alloc: fix non cma alloc context

From: Joonsoo Kim
Date: Mon Jul 20 2020 - 23:33:38 EST


2020ë 7ì 21ì (í) ìì 8:23, Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>ëì ìì:
>
> On Mon, 20 Jul 2020 13:56:15 +0900 js1304@xxxxxxxxx wrote:
>
> > Currently, preventing cma area in page allocation is implemented by using
> > current_gfp_context(). However, there are two problems of this
> > implementation.
> >
> > First, this doesn't work for allocation fastpath. In the fastpath,
> > original gfp_mask is used since current_gfp_context() is introduced in
> > order to control reclaim and it is on slowpath.
> > Second, clearing __GFP_MOVABLE has a side effect to exclude the memory
> > on the ZONE_MOVABLE for allocation target.
> >
> > To fix these problems, this patch changes the implementation to exclude
> > cma area in page allocation. Main point of this change is using the
> > alloc_flags. alloc_flags is mainly used to control allocation so it fits
> > for excluding cma area in allocation.
> >
> > Fixes: d7fefcc8de91 (mm/cma: add PF flag to force non cma alloc)
> > Cc: <stable@xxxxxxxxxxxxxxx>
>
> This patch is against linux-next (or -mm) and has a lot of issues
> applying to mainline. If we indeed wish to backport it to -stable, it
> should be against mainline, please.

I sent a revised patch against the mainline a minute ago. Subject and commit
description is updated.

Thanks.