Page MenuHomeFreeBSD

bhyve: add support for qemu's ACPI table loader
AbandonedPublic

Authored by corvink on Apr 13 2022, 9:54 AM.
Tags
Referenced Files
Unknown Object (File)
Fri, Dec 13, 2:29 AM
Unknown Object (File)
Nov 18 2024, 3:49 PM
Unknown Object (File)
Nov 18 2024, 11:58 AM
Unknown Object (File)
Nov 17 2024, 5:17 AM
Unknown Object (File)
Nov 16 2024, 11:12 AM
Unknown Object (File)
Nov 16 2024, 9:20 AM
Unknown Object (File)
Sep 17 2024, 3:21 PM
Unknown Object (File)
Sep 13 2024, 10:17 PM

Details

Reviewers
jhb
markj
Group Reviewers
bhyve
Summary

At the moment, bhyve copies his ACPI tables into the guest memory.
This isn't flexible because bhyve has to ensure that the guest
doesn't accidently overwrites the ACPI tables. Additonally, OVMF
doesn't search for ACPI tables in the guest memory. It installs it
own ACPI tables which may be wrong or miss some features.

Qemu has a much more flexible way of providing ACPI for the guest. It
uses it's FwCfg interface to send the ACPI tables to the guest.
The guest copies the ACPI tables from FwCfg into memory. With this
approach the guest can decide on it's own where to copy the ACPI
tables. Some ACPI tables contain pointer to others. For that
reason, the guest has to patch these pointers. Additionally, the
checksums of the ACPI tables won't match if the guest patches the
pointers. Therefore, qemu provides an additional FwCfg item which
contains some instructions for the guest how to patch the ACPI
tables.

This patch adds support for qemu's ACPI table loader to bhyve.
Additionally, all ACPI tables are copied into the guest memory
with correct pointers and checksums. This ensures backward
compatibility.

Note:
This revision is based on

It includes all changes for easier testing.

This revision is split into smaller commits at https://github.com/Beckhoff/freebsd-src/commits/phab/corvink/qemu-loader.

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Skipped
Unit
Tests Skipped