From: Hari Bathini <hbathini@linux.ibm.com>
To: David Hildenbrand <david@redhat.com>,
akpm@linux-foundation.org, linux-mm@kvack.org,
mpe@ellerman.id.au, linuxppc-dev@lists.ozlabs.org
Cc: osalvador@suse.de, mahesh@linux.ibm.com,
sourabhjain@linux.ibm.com, mike.kravetz@oracle.com
Subject: Re: [PATCH 1/2] mm/cma: provide option to opt out from exposing pages on activation failure
Date: Wed, 12 Jan 2022 15:20:29 +0530 [thread overview]
Message-ID: <4eafb016-8b80-dae5-cd93-69adca33bfb7@linux.ibm.com> (raw)
In-Reply-To: <21364354-83d1-5a56-378e-8ca07ccf9957@redhat.com>
On 11/01/22 8:06 pm, David Hildenbrand wrote:
> On 06.01.22 13:01, Hari Bathini wrote:
>>
>> To answer the question, fadump does not want the memory to be used for
>> kernel pages, if CMA activation fails...
>
> Okay, so what you want is a reserved region, and if possible, let CMA
> use that memory for other (movable allocation) purposes until you
> actually need that area and free it up by using CMA. If CMA cannot use
> the region because of zone issues, you just want that region to stay
> reserved.
>
Right.
> I guess the biggest different to other CMA users is that it can make use
> of the memory even if not allocated via CMA -- because it's going to
> make use of the the physical memory range indirectly via a HW facility,
> not via any "struct page" access.
>
>
> I wonder if we can make the terminology a bit clearer, the freeing part
> is a bit confusing, because init_cma_reserved_pageblock() essentially
> also frees pages, just to the MIGRATE_CMA lists ... what you want is to
> treat it like a simple memblock allocation/reservation on error.
> What about:
> * cma->reserve_pages_on_error that defaults to false
> * void __init cma_reserve_pages_on_error(struct cma *cma)
Yeah, this change does make things bit more clearer.
Will send out a v2 with the change..
next prev parent reply other threads:[~2022-01-12 9:50 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-12-20 19:34 [PATCH 0/2] powerpc/fadump: handle CMA activation failure appropriately Hari Bathini
2021-12-20 19:34 ` [PATCH 1/2] mm/cma: provide option to opt out from exposing pages on activation failure Hari Bathini
[not found] ` <e4748b18-3de3-b3f9-464a-e5cfcf9f05d4@redhat.com>
2022-01-06 12:01 ` Hari Bathini
2022-01-11 14:36 ` David Hildenbrand
2022-01-12 9:50 ` Hari Bathini [this message]
2021-12-20 19:34 ` [PATCH 2/2] powerpc/fadump: opt out from freeing pages on cma " Hari Bathini
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=4eafb016-8b80-dae5-cd93-69adca33bfb7@linux.ibm.com \
--to=hbathini@linux.ibm.com \
--cc=akpm@linux-foundation.org \
--cc=david@redhat.com \
--cc=linux-mm@kvack.org \
--cc=linuxppc-dev@lists.ozlabs.org \
--cc=mahesh@linux.ibm.com \
--cc=mike.kravetz@oracle.com \
--cc=mpe@ellerman.id.au \
--cc=osalvador@suse.de \
--cc=sourabhjain@linux.ibm.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