From: "Teddy Astie" <teddy.astie@vates.tech>
To: linux-kernel@vger.kernel.org, linux-mm@vger.kernel.org
Cc: Xen-devel <xen-devel@lists.xenproject.org>
Subject: Allocating SEV C-bit-cleared pages (without relying on swiotlb)
Date: Thu, 27 Mar 2025 14:12:28 +0000 [thread overview]
Message-ID: <b16ec2d7-4a84-482f-b875-d7c152facab5@vates.tech> (raw)
Hello Linux mailing list !
For porting Linux code to make it work on Xen with AMD-SEV, I need to
change the allocation of some pages to use "shared pages" (C-bit
cleared) instead of private pages (C-bit set, which is the default kind)
as these pages needs to be shared with the hypervisor/Dom0.
Is there a facility to allocate pages with C-bit cleared (and if not
running under SEV, just allocate a plain page) ? Current Linux code for
SEV seems to only rely on swiotlb as access to shared page is mostly
made through DMA-kind devices (e.g virtio or emulated device), but I
don't think it is the best approach.
Regards
Teddy
Teddy Astie | Vates XCP-ng Developer
XCP-ng & Xen Orchestra - Vates solutions
web: https://vates.tech
next reply other threads:[~2025-03-27 14:12 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-03-27 14:12 Teddy Astie [this message]
2025-03-28 16:30 ` Michael Kelley
2025-03-28 17:46 ` Teddy Astie
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=b16ec2d7-4a84-482f-b875-d7c152facab5@vates.tech \
--to=teddy.astie@vates.tech \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@vger.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®