All of lore.kernel.org
 help / color / mirror / Atom feed
From: Oleksii Kurochko <oleksii.kurochko@gmail.com>
To: xen-devel@lists.xenproject.org
Cc: Oleksii Kurochko <oleksii.kurochko@gmail.com>,
	Alistair Francis <alistair.francis@wdc.com>,
	Bob Eshleman <bobbyeshleman@gmail.com>,
	Connor Davis <connojdavis@gmail.com>,
	Andrew Cooper <andrew.cooper3@citrix.com>,
	Jan Beulich <jbeulich@suse.com>, Julien Grall <julien@xen.org>,
	Stefano Stabellini <sstabellini@kernel.org>
Subject: [PATCH v1 0/5] Setup memory management
Date: Wed, 16 Oct 2024 11:15:52 +0200	[thread overview]
Message-ID: <cover.1729068334.git.oleksii.kurochko@gmail.com> (raw)

Finish initializing the memory subsystem by mapping the direct map and
frame table.
In the case of RISC-V 64, which has a large virtual address space
(the minimum supported MMU mode is Sv39, providing TB of VA space),
the direct map and frame table are mapped starting from physical address
0. This simplifies the calculations and thereby improves performance for
page_to_mfn(), mfn_to_page(), and maddr_to_virt(), as there is no
need to account for {directmap, frametable}_base_pdx.
In addition, initialize the VMAP_DEFAULT region, finalize the boot allocator,
and update the system state from early_boot to boot.

Also, after patch 3 ("xen/riscv: introduce setup_mm()") of this patch series,
the linkage error mentioned in patch 1 ("xen/riscv: add stub for
share_xen_page_with_guest()") began to occur, so patch 1 addresses this issue.

The function maddr_to_virt() is introduced as part of this patch series, as
setup_directmap_mappings() uses it indirectly through mfn_to_virt().

Oleksii Kurochko (5):
  xen/riscv: add stub for share_xen_page_with_guest()
  xen/riscv: implement maddr_to_virt()
  xen/riscv: introduce setup_mm()
  xen/riscv: initialize the VMAP_DEFAULT virtual range
  xen/riscv: finalize boot allocator and transition to boot state

 xen/arch/riscv/include/asm/mm.h    |  10 ++-
 xen/arch/riscv/include/asm/setup.h |   2 +
 xen/arch/riscv/mm.c                | 104 +++++++++++++++++++++++++++--
 xen/arch/riscv/pt.c                |   6 ++
 xen/arch/riscv/setup.c             |  14 ++++
 xen/arch/riscv/stubs.c             |  10 +++
 6 files changed, 138 insertions(+), 8 deletions(-)

-- 
2.47.0



             reply	other threads:[~2024-10-16  9:16 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-10-16  9:15 Oleksii Kurochko [this message]
2024-10-16  9:15 ` [PATCH v1 1/5] xen/riscv: add stub for share_xen_page_with_guest() Oleksii Kurochko
2024-10-17 14:51   ` Jan Beulich
2024-10-18 13:10     ` oleksii.kurochko
2024-10-18 13:27       ` Jan Beulich
2024-10-18 15:57         ` oleksii.kurochko
2024-10-28  8:04           ` Jan Beulich
2024-10-16  9:15 ` [PATCH v1 2/5] xen/riscv: implement maddr_to_virt() Oleksii Kurochko
2024-10-16 10:50   ` Alejandro Vallejo
2024-10-17 14:55   ` Jan Beulich
2024-10-18 13:17     ` oleksii.kurochko
2024-10-21  7:56       ` Alejandro Vallejo
2024-10-21  9:17         ` oleksii.kurochko
2024-10-21 10:08           ` Alejandro Vallejo
2024-10-16  9:15 ` [PATCH v1 3/5] xen/riscv: introduce setup_mm() Oleksii Kurochko
2024-10-17 15:15   ` Jan Beulich
2024-10-18 14:27     ` oleksii.kurochko
2024-10-28  8:19       ` Jan Beulich
2024-10-16  9:15 ` [PATCH v1 4/5] xen/riscv: initialize the VMAP_DEFAULT virtual range Oleksii Kurochko
2024-10-17 15:18   ` Jan Beulich
2024-10-16  9:15 ` [PATCH v1 5/5] xen/riscv: finalize boot allocator and transition to boot state Oleksii Kurochko
2024-10-17 15:18   ` Jan Beulich

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=cover.1729068334.git.oleksii.kurochko@gmail.com \
    --to=oleksii.kurochko@gmail.com \
    --cc=alistair.francis@wdc.com \
    --cc=andrew.cooper3@citrix.com \
    --cc=bobbyeshleman@gmail.com \
    --cc=connojdavis@gmail.com \
    --cc=jbeulich@suse.com \
    --cc=julien@xen.org \
    --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.