From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:48561) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dGolb-0008Jr-Sf for qemu-devel@nongnu.org; Fri, 02 Jun 2017 11:45:37 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dGolW-0007fq-Tb for qemu-devel@nongnu.org; Fri, 02 Jun 2017 11:45:35 -0400 Received: from mx1.redhat.com ([209.132.183.28]:50452) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1dGolW-0007cY-LR for qemu-devel@nongnu.org; Fri, 02 Jun 2017 11:45:30 -0400 From: Laszlo Ersek Message-ID: Date: Fri, 2 Jun 2017 17:45:21 +0200 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Subject: [Qemu-devel] allocation zone extensions for the firmware linker/loader List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: SeaBIOS devel list , qemu devel list , edk2-devel-ml01 Cc: Kevin O'Connor , "Michael S. Tsirkin" , Ard Biesheuvel , Ben Warren , Dongjiu Geng , Igor Mammedov , "Jordan Justen (Intel address)" , "Leif Lindholm (Linaro address)" , Shannon Zhao , Stefan Berger , Xiao Guangrong Hi, this message is cross-posted to three lists (qemu, seabios, edk2). I'll follow up with three patch series, one series for each project. I'll cross-post all of the patches as well, but I'll add the project name in the "bag of tags" in the subject lines. The QEMU series introduces two extensions to the ALLOCATE firmware linker/loader command. One extension is a new allocation zone, with value 3, for allowing the firmware to allocate the fw_cfg blobs in 64-bit address space. The other extension is a repurposing of the most significant bit (bit 7) in the zone field. This bit becomes orthogonal to the rest of the zone field. If the bit is set, it means that QEMU promises the firmware that the blob referenced by the ALLOCATE command contains no ACPI tables at all. After introducing these, the QEMU series puts them to use, covering all of the currently generated ALLOCATE commands, as appropriate. Among the benefits we can mention - the removal of the OVMF ACPI SDT Header Probe suppressor from VMGENID (and from any similar future devices), - and the fact that the "virt" machine type (and maybe other machine types) of the arm/aarch64 target will no longer require RAM under 4GB for ACPI to work. Both of these extensions are irrelevant for SeaBIOS, therefore the SeaBIOS patches simply mask out bit 7 (for ignoring the "no ACPI content" hint), and fall back to the HIGH zone (= 32-bit address space) when the 64-bit zone is permitted. In other words, SeaBIOS needs some patches to recognize the new zone values, but beyond that, the behavior is unchanged. Both extensions are important for virtual UEFI firmware (OVMF in x86 guests and ArmVirtQemu in aarch64 guests). The edk2 patches add support to OvmfPkg/AcpiPlatformDxe for the extensions. Please see the commit messages for details (all the extensions are explained in detail in the relevant patches for all of the projects). The patches can cause linker/loader breakage when old firmware is booted on new QEMU. However, that's no problem (it's nothing new), the next release of QEMU should bundle the new firmware binaries as always. New firmware will continue running on old QEMU without issues. (In case you have sent me emails about this in the last few tens of hours, please know that I'm not ignoring them, I just haven't seen / read them. Reading emails every five minutes makes focused work impossible, so when I'm busy, I tend to read email once per day.) Thanks Laszlo