opencontainers / runtime-spec

OCI Runtime Specification
http://www.opencontainers.org
Apache License 2.0
3.13k stars 535 forks source link

config: Add Hardware description object to the VM configuration #1209

Open oleksiimoisieiev opened 1 year ago

oleksiimoisieiev commented 1 year ago

This adds section to describe HW that should be passed through to the VM. This enables Hardware-level isolation provided by XEN for e.g. functional safety use cases.

Adds hwConfig object to the VM section which is apt to describe the initial configuration for the VM, sush as number of vcpus and memory, provided to the VM. Hardware description includes path to the device-tree, that should be passed to the VM and the hardware configuration parameters which provides all needed data for VM to use the devices, such as:

giuseppe commented 1 year ago

@slp could this be useful for krun?

slp commented 1 year ago

@giuseppe I don't see an immediate use for it, but it's good to know it's there.

AkihiroSuda commented 1 year ago

Looks good, but we are freezing the main branch until releasing v1.1.0.

Hope we can release v1.1.0 and merge post-v1.1 PRs in the next couple of weeks.

klogg commented 1 year ago

@giuseppe I don't see an immediate use for it, but it's good to know it's there.

We plan to extend with RT scheduling / mem bw control for domains, do you have some interest or ideas in that?

oleksiimoisieiev commented 5 months ago

Hi @AkihiroSuda. Do you have any plans merging this changes?

AkihiroSuda commented 5 months ago

Yes, but after releasing this:

We also want to see a POC of this PR to confirm implementability.

oleksiimoisieiev commented 5 months ago

Yes, but after releasing this:

* [Release v1.1.1 #1242](https://github.com/opencontainers/runtime-spec/pull/1242)

We also want to see a POC of this PR to confirm implementability.

Thank you for the quick response. What do you expect as POC? Some real yamls based on this bindings?

AkihiroSuda commented 5 months ago

A POC of an actual runtime implementation would be more preferable

AkihiroSuda commented 4 months ago

ping @opencontainers/runtime-spec-maintainers

oleksiimoisieiev commented 4 months ago

A POC of an actual runtime implementation would be more preferable

Hi @AkihiroSuda, Attaching sample JSON spec (see attached domain.json) and Xen config (see attached domain.txt) that can be generated from the provided spec. Using this config Xen domain can be started.

domain.json domain.txt