From mboxrd@z Thu Jan 1 00:00:00 1970 Received: by 2002:a5d:6089:0:0:0:0:0 with SMTP id w9csp5806372wrt; Mon, 26 Nov 2018 08:34:28 -0800 (PST) X-Google-Smtp-Source: AFSGD/XeLLLS4bqS1qKwqsREhEkzit+tM1gSoIhPPr9r6yrEhxWL/o2u3AhfwROyJeCXW8rlSVzV X-Received: by 2002:a25:5a0b:: with SMTP id o11-v6mr28299442ybb.52.1543250068178; Mon, 26 Nov 2018 08:34:28 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1543250068; cv=none; d=google.com; s=arc-20160816; b=kEO1vXD1BvGgzM42XPFXRl+4Awl1+oS8ufap3KqPkE+n6bz/Oj2hPbqx6zZb2xQ9Nv Qv/akrMDJp0Myi6oJHMWzUgSpqUI3CtNdFqrqtKgdb3NKrlnXJ307GDpCqJKWorK2cV2 E0YbLoobi0dHZrQvR1nbZJbvn0hmOVd0nfJ+DDk5Rb9m9WMfn6KYMDabgRwfh1lB2vLq 1HYLUNFxlDCSixTBKzbr/9pO8kCq2khZn0z6dI21XDGJVh4T01dtxXA7gUeeEPnFqHZV tVrUN9xPXzdYYWb8Q2PWtEaQemABFAzxkBqVRxfBEtOi7P6iCZXEaciadzm++zBhFgMH qhUA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:subject :content-transfer-encoding:mime-version:message-id:date:to:from; bh=rejNqgXRs+EOa0xY0Cah/apH7+GRDTCCPMo/sr4ddME=; b=m3FdmZ8ZFTt4pcpLV1F0JUiz8QBtq6Non3d0ZYQBLR3Cdtq3FPCP0jsHTWREMekihs WnfCH5nh2lD7oitof0i3/2XPKENd8pFVVjFVyExHY1jjpjzUHzeSjq5WAudSFSxyiRzc u8wEH0HtNwp2rGM2IdVr2PNzCZtjDo+PsOoBFeJYJPRQv1o2WmoDy3lV6N+4PkcMdU5f KNXnfeWHLbtzSiSQTGgbO2UmW2ijTBrJWbjJkgwhllb3BO6nk0vYhSSCLH74WeNgxlJp rToPYsxKGQFMEkIplf+VoJHwch/FtfNhBNsBPhnsfuOeniHGFxgUyxANCIjLmUIUgHLk 36Mw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of qemu-devel-bounces+alex.bennee=linaro.org@nongnu.org designates 2001:4830:134:3::11 as permitted sender) smtp.mailfrom="qemu-devel-bounces+alex.bennee=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from lists.gnu.org (lists.gnu.org. [2001:4830:134:3::11]) by mx.google.com with ESMTPS id q37si596505ywa.288.2018.11.26.08.34.28 for (version=TLS1 cipher=AES128-SHA bits=128/128); Mon, 26 Nov 2018 08:34:28 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+alex.bennee=linaro.org@nongnu.org designates 2001:4830:134:3::11 as permitted sender) client-ip=2001:4830:134:3::11; Authentication-Results: mx.google.com; spf=pass (google.com: domain of qemu-devel-bounces+alex.bennee=linaro.org@nongnu.org designates 2001:4830:134:3::11 as permitted sender) smtp.mailfrom="qemu-devel-bounces+alex.bennee=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: from localhost ([::1]:37527 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gRJq7-0003ya-H6 for alex.bennee@linaro.org; Mon, 26 Nov 2018 11:34:27 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:37674) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gRJmR-0000m1-J9 for qemu-devel@nongnu.org; Mon, 26 Nov 2018 11:30:40 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gRJmM-0004PW-MA for qemu-devel@nongnu.org; Mon, 26 Nov 2018 11:30:39 -0500 Received: from mga14.intel.com ([192.55.52.115]:1699) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1gRJmK-0004Gc-Re; Mon, 26 Nov 2018 11:30:34 -0500 X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga008.fm.intel.com ([10.253.24.58]) by fmsmga103.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 26 Nov 2018 08:30:19 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.56,283,1539673200"; d="scan'208";a="90948916" Received: from sunandos-mobl2.ger.corp.intel.com (HELO localhost.localdomain) ([10.251.82.176]) by fmsmga008.fm.intel.com with ESMTP; 26 Nov 2018 08:30:14 -0800 From: Samuel Ortiz To: qemu-devel@nongnu.org Date: Mon, 26 Nov 2018 17:29:33 +0100 Message-Id: <20181126162942.21258-1-sameo@linux.intel.com> X-Mailer: git-send-email 2.19.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 192.55.52.115 Subject: [Qemu-devel] [PATCH 0/8] hw: acpi: RSDP fixes and refactoring X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Laurent Vivier , Peter Maydell , Thomas Huth , Eduardo Habkost , Ben Warren , "Michael S. Tsirkin" , Shannon Zhao , qemu-arm@nongnu.org, Paolo Bonzini , Igor Mammedov , Richard Henderson Errors-To: qemu-devel-bounces+alex.bennee=linaro.org@nongnu.org Sender: "Qemu-devel" X-TUID: ZrfFewDwuNxa This patch serie fixes a couple of RSDP checksum related issues: - On RSDP rev2, we are not adding the extended checksum and computing the checksum on the full table instead of the first 20 bytes. - On RSDP rev1, we are computing the checksum on 36 bytes instead of 20. We're lucky enough that this is only adding zeroes to the checksum. A guest Linux kernel does not seem to care about RSDP checksums, so those 2 fixes are mostly for correctness sake. Any machine type that generates rev2 RSDP will see its RSDP table modified but since x86 builds RSDP v1 and all ACPI tests only run on either pc or q35, the ACPI tests tables are not affected by this fix. The serie also extends the ARM virt ACPI RSDP build routine to support both RSDP v1 and v2, in order to share this code between x86 and aarch64. While extending, we also convert the routine to the latest build_append_foo() API. The new implementation is a closer reflection of the ACPI spec itself, is endian agnostic and allows for getting rid of the AcpiRsdpDescriptor structure. Igor Mammedov (2): hw: arm: acpi: Fix incorrect checksums in RSDP hw: i386: Use correct RSDT length for checksum Samuel Ortiz (6): hw: acpi: The RSDP build API can return void hw: arm: Carry RSDP specific data through AcpiRsdpData hw: arm: Convert the RSDP build to the buid_append_foo() API hw: arm: Support both legacy and current RSDP build hw: acpi: Export and share the ARM RSDP build hw: acpi: Remove AcpiRsdpDescriptor and fix tests include/hw/acpi/acpi-defs.h | 44 ++++++++++++++------ include/hw/acpi/aml-build.h | 5 +++ tests/acpi-utils.h | 5 ++- hw/acpi/aml-build.c | 81 +++++++++++++++++++++++++++++++++++++ hw/arm/virt-acpi-build.c | 35 ++-------------- hw/i386/acpi-build.c | 31 ++------------ tests/acpi-utils.c | 48 +++++++++++++++++----- tests/bios-tables-test.c | 27 +++++++++---- tests/vmgenid-test.c | 8 ++-- 9 files changed, 193 insertions(+), 91 deletions(-) -- 2.19.1 From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:37674) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gRJmR-0000m1-J9 for qemu-devel@nongnu.org; Mon, 26 Nov 2018 11:30:40 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gRJmM-0004PW-MA for qemu-devel@nongnu.org; Mon, 26 Nov 2018 11:30:39 -0500 From: Samuel Ortiz Date: Mon, 26 Nov 2018 17:29:33 +0100 Message-Id: <20181126162942.21258-1-sameo@linux.intel.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: [Qemu-devel] [PATCH 0/8] hw: acpi: RSDP fixes and refactoring List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: Peter Maydell , Igor Mammedov , qemu-arm@nongnu.org, Shannon Zhao , Laurent Vivier , Richard Henderson , Paolo Bonzini , Ben Warren , Thomas Huth , Marcel Apfelbaum , Eduardo Habkost , "Michael S. Tsirkin" This patch serie fixes a couple of RSDP checksum related issues: - On RSDP rev2, we are not adding the extended checksum and computing the checksum on the full table instead of the first 20 bytes. - On RSDP rev1, we are computing the checksum on 36 bytes instead of 20. We're lucky enough that this is only adding zeroes to the checksum. A guest Linux kernel does not seem to care about RSDP checksums, so those 2 fixes are mostly for correctness sake. Any machine type that generates rev2 RSDP will see its RSDP table modified but since x86 builds RSDP v1 and all ACPI tests only run on either pc or q35, the ACPI tests tables are not affected by this fix. The serie also extends the ARM virt ACPI RSDP build routine to support both RSDP v1 and v2, in order to share this code between x86 and aarch64. While extending, we also convert the routine to the latest build_append_foo() API. The new implementation is a closer reflection of the ACPI spec itself, is endian agnostic and allows for getting rid of the AcpiRsdpDescriptor structure. Igor Mammedov (2): hw: arm: acpi: Fix incorrect checksums in RSDP hw: i386: Use correct RSDT length for checksum Samuel Ortiz (6): hw: acpi: The RSDP build API can return void hw: arm: Carry RSDP specific data through AcpiRsdpData hw: arm: Convert the RSDP build to the buid_append_foo() API hw: arm: Support both legacy and current RSDP build hw: acpi: Export and share the ARM RSDP build hw: acpi: Remove AcpiRsdpDescriptor and fix tests include/hw/acpi/acpi-defs.h | 44 ++++++++++++++------ include/hw/acpi/aml-build.h | 5 +++ tests/acpi-utils.h | 5 ++- hw/acpi/aml-build.c | 81 +++++++++++++++++++++++++++++++++++++ hw/arm/virt-acpi-build.c | 35 ++-------------- hw/i386/acpi-build.c | 31 ++------------ tests/acpi-utils.c | 48 +++++++++++++++++----- tests/bios-tables-test.c | 27 +++++++++---- tests/vmgenid-test.c | 8 ++-- 9 files changed, 193 insertions(+), 91 deletions(-) -- 2.19.1