rust-vmm / community

rust-vmm community content
477 stars 26 forks source link

Where should the xen-sys crate be hosted? #128

Open mathieupoirier opened 2 years ago

mathieupoirier commented 2 years ago

Following a discussion that happened during March 7th 2022's rust-vmm sync meeting, I am opening this issue to gather input on where the xen-sys crate should be hosted. A pull request that provides support for aarch64 is currenlty pending and more work is under way to add ioctl() call support. This will provide a foundation allowing for interaction with the Xen hypervisor to request details about hardware specifics and reserve different kind of resources such as mapped memory and virtual CPUs.

Is this something we want to add under the rust-vmm umbrella, host under the Xen project of leave where it is?

I have raised the same question with Doug Goldstein who currently maintains the crate and the Xen community at large.

andreeaflorescu commented 2 years ago

I would be happy to see this part of rust-vmm! Let me know if you need support with setting that up. In terms of testing infrastructure, how is the crate currently tested? Are there any host requirements?

I'll also transfer this issue to the community repository because that's where we discuss about adding new crates to rust-vmm.

mathieupoirier commented 2 years ago

At this time the crate is compilation tested for X86_64 and does not have any #[cfg(test)] section. On the flip side this crate is very hardware oriented and adding function tests that is inline with what is done for other creates under the rust-vmm umbrella might be difficult. I am mainly enhancing the aarch64 architecture and testing that requires a platform that is supported by Xen or QEMU. The former is hard to find and requires a high degree of maintenance. The latter is more accessible but involves a somewhat complex software stack that will also demand a fair amount of maintenance.

That being said I am happy to work with other people that have more Rust knowledge, and perhaps have done the same thing for other hypervisor, to improve this area.

andreeaflorescu commented 2 years ago

I can take a look to see how we can add some testing if it's useful. Did you discuss with the maintainer of the crate? Is this something that we would want to make part of rust-vmm?

mathieupoirier commented 2 years ago

I will gladly take you up on your offer to look at how testing can be enhanced for this crate. But for now I sugget to hold back on that until we have a clear view of where this crate should be hosted. I need to discuss with the Xen community and get in contact with the maintainer, which I haven't been able to reach since early January. I will keep you posted.

dwmw2 commented 2 years ago

I'm very interested in the Rust definitions of the Xen hypercall ABI but not for calling them; for implementing them. Linux/KVM now has support for hosting Xen guests, and the VMM is expected to implement the Xen hypercalls. We made a start on this at https://github.com/alexandruag/vmm-reference/commits/xen