clarify VMCS interfaces in bhyve
As it was imported from FreeBSD, bhyve has an API surface for interacting with the VMCS (virtual machine control structure) when running on Intel hardware. This API is somewhat scattered and inconsistent, both in how it exposes access to VMCS tasks, and how it manipulates data when doing so. It is a mix of fallible (reporting errors) and infallible (panic on presumably unexpected errors) functions, with a real mix of how consumers use and interpret any potential error states.
It would be nice to clear this up so that all unexpected errors are handled with
panic(), making handling easier for consumers. Additionally, any manipulation of the data being written/read from the VMCS should be done as part of the VMX logic, so it's clear, rather than being hidden by the VMCS API as it is now. The combination of these efforts should result in cleaner more readable code which is less prone to barreling through unexpected conditions.
Updated by Electric Monk about 1 year ago
- Status changed from In Progress to Closed
- % Done changed from 0 to 100
commit 007ca33219ffdc49281657f5f8a9ee1bbfc367ab Author: Patrick Mooney <email@example.com> Date: 2020-08-28T18:28:42.000Z 13063 clarify VMCS interfaces in bhyve 13064 bhyve should not waste extra page for VMCS Reviewed by: Robert Mustacchi <firstname.lastname@example.org> Reviewed by: Mike Zeller <email@example.com> Approved by: Dan McDonald <firstname.lastname@example.org>