All of lore.kernel.org
 help / color / mirror / Atom feed
From: Penny Zheng <penny.zheng@arm.com>
To: <xen-devel@lists.xenproject.org>, <sstabellini@kernel.org>,
	<julien@xen.org>
Cc: <Bertrand.Marquis@arm.com>, <Penny.Zheng@arm.com>,
	<Wei.Chen@arm.com>, <jbeulich@suse.com>, <nd@arm.com>
Subject: [PATCH V3 00/10] Domain on Static Allocation
Date: Thu, 15 Jul 2021 05:18:09 +0000	[thread overview]
Message-ID: <20210715051819.3073628-1-penny.zheng@arm.com> (raw)

Static Allocation refers to system or sub-system(domains) for which memory
areas are pre-defined by configuration using physical address ranges.
Those pre-defined memory, -- Static Memory, as parts of RAM reserved in the
beginning, shall never go to heap allocator or boot allocator for any use.

Domain on Static Allocation is supported through device tree property
`xen,static-mem` specifying reserved RAM banks as this domain's guest RAM.
The size of address-cells/size-cells must be defined in
"#xen,static-mem-address-cells" and "#xen,static-mem-size-cells".

This Patch Serie only talks about Domain on Static Allocation.

Looking into related [design link](
https://lists.xenproject.org/archives/html/xen-devel/2021-05/msg00882.html)
for more details.

The whole design is about Static Allocation and 1:1 direct-map, and this
Patch Serie only covers parts of it, which are Domain on Static Allocation.
Other features will be delievered through different patch series.
---
changes in v3:
- use "xen,static-mem" property to be compatible with System Sevice Tree
in the future
- introduce new helper device_tree_get_meminfo
- extract common codes for dealing with reserved memory stored in
bootinfo
- rename from "free_page" to "mark_page_free"
- remove non-trivial page_to_mfn conversion in "mark_page_free" due to
pdx compression, and let the MFN passed in
- let all switch-cases shared in "mark_page_free"
- change CONFIG_STATIC_ALLOCATION to CONFIG_STATIC_MEMORY
- put init_staticmem_pages in setup_mm
- rename assign_pages_nr to assign_pages
- alter the order of assign_pages parameters to help backporting
- change name from alloc_staticmem_pages/alloc_domstatic_pages to
acquire_staticmem_pages and acquire_domstatic_pages.
- remove hunks' #ifdef-ary by introducing PGC_reserved = 0
- remove DMA restriction
- "memory" property shall be mandatory
- rename allocate_static_bank_memory to append_static_memory_to_bank
- infer the next GFN from the bank information in append_static_memory_to_bank
- simplify the code of double loop in allocate_static_memory

Penny Zheng (10):
  xen/arm: introduce domain on Static Allocation
  xen/arm: introduce new helper device_tree_get_meminfo
  xen/arm: handle static memory in dt_unreserved_regions
  xen: introduce mark_page_free
  xen/arm: static memory initialization
  xen/arm: introduce PGC_reserved
  xen: re-define assign_pages and introduce assign_page
  xen/arm: introduce acquire_staticmem_pages and acquire_domstatic_pages
  xen/arm: check "xen,static-mem" property during domain construction
  xen/arm: introduce allocate_static_memory

 docs/misc/arm/device-tree/booting.txt |  40 +++++
 xen/arch/arm/Kconfig                  |   3 +
 xen/arch/arm/bootfdt.c                |  89 +++++++---
 xen/arch/arm/domain_build.c           | 170 +++++++++++++++++-
 xen/arch/arm/setup.c                  |  73 ++++++--
 xen/arch/x86/pv/dom0_build.c          |   2 +-
 xen/common/grant_table.c              |   2 +-
 xen/common/memory.c                   |   4 +-
 xen/common/page_alloc.c               | 245 ++++++++++++++++++++------
 xen/include/asm-arm/mm.h              |   3 +
 xen/include/asm-arm/setup.h           |   2 +
 xen/include/xen/mm.h                  |  15 ++
 12 files changed, 546 insertions(+), 102 deletions(-)

-- 
2.25.1



             reply	other threads:[~2021-07-15  5:19 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-07-15  5:18 Penny Zheng [this message]
2021-07-15  5:18 ` [PATCH V3 01/10] xen/arm: introduce domain on Static Allocation Penny Zheng
2021-07-15  5:18 ` [PATCH V3 02/10] xen/arm: introduce new helper device_tree_get_meminfo Penny Zheng
2021-07-15  5:18 ` [PATCH V3 03/10] xen/arm: handle static memory in dt_unreserved_regions Penny Zheng
2021-07-15  5:18 ` [PATCH V3 04/10] xen: introduce mark_page_free Penny Zheng
2021-07-19  8:13   ` Jan Beulich
2021-07-15  5:18 ` [PATCH V3 05/10] xen/arm: static memory initialization Penny Zheng
2021-07-19  8:20   ` Jan Beulich
2021-07-21  3:07     ` Penny Zheng
2021-07-21  8:15       ` Jan Beulich
2021-07-19  8:25   ` Jan Beulich
2021-07-15  5:18 ` [PATCH V3 06/10] xen/arm: introduce PGC_reserved Penny Zheng
2021-07-15  5:18 ` [PATCH V3 07/10] xen: re-define assign_pages and introduce assign_page Penny Zheng
2021-07-19  8:41   ` Jan Beulich
2021-07-21  5:53     ` Penny Zheng
2021-07-15  5:18 ` [PATCH V3 08/10] xen/arm: introduce acquire_staticmem_pages and acquire_domstatic_pages Penny Zheng
2021-07-19  9:26   ` Jan Beulich
2021-07-19 10:00     ` Julien Grall
2021-07-21  7:52       ` Penny Zheng
2021-07-21  7:37     ` Penny Zheng
2021-07-15  5:18 ` [PATCH V3 09/10] xen/arm: check "xen,static-mem" property during domain construction Penny Zheng
2021-07-15  5:18 ` [PATCH V3 10/10] xen/arm: introduce allocate_static_memory Penny Zheng
2021-07-27  3:44   ` Penny Zheng
2021-07-27  6:18     ` Penny Zheng

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=20210715051819.3073628-1-penny.zheng@arm.com \
    --to=penny.zheng@arm.com \
    --cc=Bertrand.Marquis@arm.com \
    --cc=Wei.Chen@arm.com \
    --cc=jbeulich@suse.com \
    --cc=julien@xen.org \
    --cc=nd@arm.com \
    --cc=sstabellini@kernel.org \
    --cc=xen-devel@lists.xenproject.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.