Page MenuHomeFreeBSD

[PATCH 7/19] bhyve: add basl support for checksums
ClosedPublic

Authored by corvink on Oct 14 2022, 9:13 AM.
Tags
Referenced Files
Unknown Object (File)
Mon, Nov 11, 5:36 AM
Unknown Object (File)
Sun, Nov 10, 4:57 AM
Unknown Object (File)
Sep 27 2024, 12:48 PM
Unknown Object (File)
Sep 24 2024, 4:09 AM
Unknown Object (File)
Sep 19 2024, 8:26 PM
Unknown Object (File)
Sep 18 2024, 5:50 AM
Unknown Object (File)
Sep 17 2024, 12:53 PM
Unknown Object (File)
Sep 17 2024, 11:16 AM
Subscribers

Details

Summary

The qemu ACPI table loader patches the ACPI tables. After patching them,
checksums aren't correct any more. It has to calculate a new checksum
for the ACPI table. For that reason, basl has to keep track of checksums
and has to cause the qemu loader to create new checksums for the tables.

The qemu ACPI table loader isn't supported yet. However, the address of all tables is unknown as long as bhyve hasn't finished ACPI table creation. So, the checksum of tables which include pointer to other tables are unknown too. This requires tracking of checksums too.

This is the 7. patch required to merge D36983

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 48223
Build 45109: arc lint + arc unit

Event Timeline

corvink retitled this revision from [acpi-table part 7] bhyve: add basl support for checksums to [PATCH 7/19] bhyve: add basl support for checksums.Oct 14 2022, 9:44 AM
usr.sbin/bhyve/basl.c
62

In the final version we have a bunch of different lists, each is 1-to-1 with the table list. Why don't you embed these structures in struct basl_table instead, so there's only one list and no need for backpointers everywhere?

135
138
161
179
  • rebase
  • turn basl_checksums into a member variable of basl_table to avoid global variables and backpointer
usr.sbin/bhyve/basl.c
212

I would maybe merge this comment with the comment below (so you don't need a separate comment below) by just saying that the second one updates the checksums in the installed tables.

usr.sbin/bhyve/basl.c
212

Nevermind, I see how it factors into later commits.

This revision is now accepted and ready to land.Nov 11 2022, 6:29 PM
This revision was automatically updated to reflect the committed changes.