On 10/8/26 19:20, Roman Bogorodskiy wrote:
> Probe the bhyve binary to determine whether it supports TPM devices.
>
> Signed-off-by: Roman Bogorodskiy <[email protected]>
> ---
> src/bhyve/bhyve_capabilities.c | 15 +++++++++++++++
> src/bhyve/bhyve_capabilities.h | 1 +
> 2 files changed, 16 insertions(+)
>
> diff --git a/src/bhyve/bhyve_capabilities.h b/src/bhyve/bhyve_capabilities.h
> index 0302b68e22..9b3163b9ef 100644
> --- a/src/bhyve/bhyve_capabilities.h
> +++ b/src/bhyve/bhyve_capabilities.h
> @@ -58,6 +58,7 @@ typedef enum {
> BHYVE_CAP_ACPI = 1 << 12,
> BHYVE_CAP_NUMA = 1 << 13,
> BHYVE_CAP_RCTL = 1 << 14,
> + BHYVE_CAP_LPC_TPM = 1 << 15,
You'll need to rebase this and change this to 1 << 17.
Or even better, turn this into a sequential enum (1, 2, 3, ... 17) and
then use virBitmap to store capabilities ;-) Just like I suggested in
one of my earlier reviews to something.
> } virBhyveCapsFlags;
>
> int virBhyveProbeGrubCaps(virBhyveGrubCapsFlags *caps);
Michal