On Mon, Jan 06, 2025 at 03:16:15AM -0800, Christoph Hellwig wrote: > On Mon, Dec 23, 2024 at 06:18:03PM +0000, Dmytro Maluka wrote: > > There are cases when the bootloader provides information to the kernel > > in both ACPI and DTB, not interchangeably. One such use case is virtual > > machines in Android. When running on x86, the Android Virtualization > > Framework (AVF) boots VMs with ACPI like it is usually done on x86 (i.e. > > the virtual LAPIC, IOAPIC, HPET, PCI MMCONFIG etc are described in ACPI) > > but also passes various AVF-specific boot parameters in DTB. This allows > > reusing the same implementations of various AVF components on both > > arm64 and x86. > > What are these "AVF-specific boot parameters"? Let me quote my reply to Rob: The strictly AVF-specific properties are described in [1]. When it comes to Linux guests, actually AFAIK currently all those properties are consumed by the guest userspace, not the guest kernel, so the role of the kernel is in fact just to pass them over to the userspace via sysfs. Besides that, one important DT binding used by AVF's Linux guest kernels, not userspace, is google,open-dice documented in Documentation/devicetree/bindings/reserved-memory/google,open-dice.yaml. [2] describes how it is used by the protected VM firmware (pvmfw) to securely boot protected VMs. Cc'ing some AVF folks to keep me honest. (AVF used to support protected VMs on arm64 only, but now we are trying to make them work on x86. So, taking google,open-dice as an example, we could add an ACPI binding to the open-dice driver, however bloating pvmfw with AML support is a no go, so we want to keep passing it via DT on x86 as well.) [1] https://android.googlesource.com/platform/packages/modules/Virtualization/+/refs/heads/main/docs/device_trees.md#dt-for-guests [2] https://android.googlesource.com/platform/packages/modules/Virtualization/+/refs/heads/main/guest/pvmfw/#handover-abi