Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Interface proposal for the split TD partitioning VMM #355

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

cxdong
Copy link
Contributor

@cxdong cxdong commented May 22, 2024

This draft PR is opened to collect review comments and discussions, but not to merge.

The TD partitioning VMM was implemented fully in the coconut-svsm kernel mode, which runs the coconut-svsm as a L1 VMM in TD and a Linux OS as a L2 guest. The code is published here.

Following the development plan, most parts of this TD partitioning VMM should be moved to the user mode for security reasons, while keeping the necessary parts (e.g., executing TDCALL instruction) left in the svsm kernel. We made a document, available for preview here, which discusses the high-level architecture of the split TD partitioning VMM and outlines the key VMM interfaces between user mode and kernel mode. In short, the proposal is to use the common file based syscalls ABI, e.g., open, ioctl, mmap as the VMM interfaces, and clone syscall to create multiple vCPU threads which shares the same user mode address space.

Before moving forward, we would like to use this PR to collect the review comments from the community about this proposal and possibility of extending it for SEV user mode VMM, as well as any alternative proposals that the community prefers. We would greatly appreciate it if you could take some time to review and share your thoughts.

@cxdong
Copy link
Contributor Author

cxdong commented May 23, 2024

The markdown doc is converted to a pdf file, which is now uploaded to this PR.

@cxdong
Copy link
Contributor Author

cxdong commented Aug 15, 2024

Hi @joergroedel, this document is updated with describing a basic vcpu run loop implementation in the user mode VMM to enter guest and handle simple vmexit event, with utilizing the syscalls outlined in the X86-64 Syscall API/ABI Document. And here is the pdf version. Would you please let us know if this is on the right direction or not? Thanks!

Add design doc USER-MODE-VMM.md and related picture resources. This
doc majorly takes about the interfaces between the user mode VMM and
the COCONUT-SVSM kernel, and how the user mode VMM is implemented via
the syscalls.

Signed-off-by: Chuanxiao Dong <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant