CVSROOT: /cvs Module name: src Changes by: bl...@cvs.openbsd.org 2025/05/24 06:47:00
Modified files: sys/arch/amd64/conf: files.amd64 sys/arch/amd64/include: vmmvar.h Added files: sys/arch/amd64/amd64: ghcb.c sys/arch/amd64/include: ghcb.h Log message: Define GHCB for AMD SEV-ES guest-host communication via vmm(4). SEV-ES enabled guests will communicate with vmm(4) using a non-encrypted page, the Guest Host Communication Block (GHCB). The GHCB layout is specified by AMD. It includes all GPR, FPU and extended state and a buffer for other data. Which members are valid is specified in a bitmap. For now we will only use the GPRs A, B, C and D and the exit related members. Also provide functions for copying values to and from the GHCB. For GPRs we respect the given operand size. For example, when emulating an inb instruction we only want to copy the response from vmm(4) into %al (lowest byte) and not %rax (quad word). from hshoexer@