From patchwork Fri Jun 26 13:31:17 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Peter Maydell X-Patchwork-Id: 50353 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-lb0-f200.google.com (mail-lb0-f200.google.com [209.85.217.200]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 4D9A322902 for ; Fri, 26 Jun 2015 13:34:43 +0000 (UTC) Received: by lbcui10 with SMTP id ui10sf26760125lbc.0 for ; Fri, 26 Jun 2015 06:34:42 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:delivered-to:from:to:date :message-id:in-reply-to:references:subject:precedence:list-id :list-unsubscribe:list-archive:list-post:list-help:list-subscribe :errors-to:sender:x-original-sender :x-original-authentication-results:mailing-list; bh=fCswp5GTn2/tKNSpmUChHVTWy4G3c4//yKclfcxG36Y=; b=j119lItenYtEb7w0DkgH8xX8H3xEnVQ4Xdzbv7MTtNwQD+c7BCI38jiIBoGHMlkt+e gyhQAEzSYALaoVuijC7fzBaGeJPOsIBrVM7XVdvn0Kqj9HJPVACc62sIOJ3vh8XnSJQd UzLsWAn+DY47WqlRGdytkWV/Lhucbo1W6BiiOS6WraB+pT7P1eVZQb1Gw6EFHOok5mc1 5QJTjvN9/iSMRev3rGL9g0OmG0ApTzJED52pG5LV2Rd3mNoXllDyBAZduiuxB3nSLqdH gbGMPekd0xE6+TmLRW6pa74EVQS2sFtDTsyBLOh03wq/l09YT8voBpWNir9LuOMm+x9V uTGg== X-Gm-Message-State: ALoCoQkIV5FmppY7lpyu70QODTJ6Eh0MAwRZop16P+bnVvP5LYaaIQYQO0TQ243B9FA+Q+z0BndV X-Received: by 10.180.189.50 with SMTP id gf18mr1913966wic.3.1435325682294; Fri, 26 Jun 2015 06:34:42 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.203.136 with SMTP id kq8ls107693lac.32.gmail; Fri, 26 Jun 2015 06:34:42 -0700 (PDT) X-Received: by 10.152.10.104 with SMTP id h8mr1633073lab.23.1435325682119; Fri, 26 Jun 2015 06:34:42 -0700 (PDT) Received: from mail-la0-f46.google.com (mail-la0-f46.google.com. [209.85.215.46]) by mx.google.com with ESMTPS id jx2si27428553lbc.124.2015.06.26.06.34.42 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 26 Jun 2015 06:34:42 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.46 as permitted sender) client-ip=209.85.215.46; Received: by lagi2 with SMTP id i2so63894418lag.2 for ; Fri, 26 Jun 2015 06:34:42 -0700 (PDT) X-Received: by 10.152.179.234 with SMTP id dj10mr1628617lac.73.1435325682035; Fri, 26 Jun 2015 06:34:42 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.112.108.230 with SMTP id hn6csp1331401lbb; Fri, 26 Jun 2015 06:34:41 -0700 (PDT) X-Received: by 10.55.43.228 with SMTP id r97mr3562883qkr.82.1435325680656; Fri, 26 Jun 2015 06:34:40 -0700 (PDT) Received: from lists.gnu.org (lists.gnu.org. [2001:4830:134:3::11]) by mx.google.com with ESMTPS id 85si32884095qhu.28.2015.06.26.06.34.40 for (version=TLSv1 cipher=RC4-SHA bits=128/128); Fri, 26 Jun 2015 06:34:40 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 2001:4830:134:3::11 as permitted sender) client-ip=2001:4830:134:3::11; Received: from localhost ([::1]:60022 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Z8TmB-0007S2-Qx for patch@linaro.org; Fri, 26 Jun 2015 09:34:39 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:54692) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Z8TjB-0002JB-85 for qemu-devel@nongnu.org; Fri, 26 Jun 2015 09:31:39 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Z8TjA-0001Vj-4L for qemu-devel@nongnu.org; Fri, 26 Jun 2015 09:31:33 -0400 Received: from mnementh.archaic.org.uk ([2001:8b0:1d0::1]:34512) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Z8Tj9-0001QX-Rz for qemu-devel@nongnu.org; Fri, 26 Jun 2015 09:31:32 -0400 Received: from pm215 by mnementh.archaic.org.uk with local (Exim 4.80) (envelope-from ) id 1Z8Tj2-0005GT-2M for qemu-devel@nongnu.org; Fri, 26 Jun 2015 14:31:24 +0100 From: Peter Maydell To: qemu-devel@nongnu.org Date: Fri, 26 Jun 2015 14:31:17 +0100 Message-Id: <1435325484-20208-2-git-send-email-peter.maydell@linaro.org> X-Mailer: git-send-email 1.7.10.4 In-Reply-To: <1435325484-20208-1-git-send-email-peter.maydell@linaro.org> References: <1435325484-20208-1-git-send-email-peter.maydell@linaro.org> X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2001:8b0:1d0::1 Subject: [Qemu-devel] [PULL 1/7] hw/arm/virt-acpi-build: Fix table revision and some comments X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: , List-Help: , List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: peter.maydell@linaro.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.46 as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 From: Shannon Zhao The table revision is not the ACPI spec version. Fix the wrong revision and also some comments. Signed-off-by: Shannon Zhao Reviewed-by: Michael S. Tsirkin Message-id: 1433820378-8336-1-git-send-email-zhaoshenglong@huawei.com Signed-off-by: Peter Maydell --- hw/arm/virt-acpi-build.c | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/hw/arm/virt-acpi-build.c b/hw/arm/virt-acpi-build.c index d5a8b9c..40029dd 100644 --- a/hw/arm/virt-acpi-build.c +++ b/hw/arm/virt-acpi-build.c @@ -387,7 +387,7 @@ build_mcfg(GArray *table_data, GArray *linker, VirtGuestInfo *guest_info) mcfg->allocation[0].end_bus_number = (memmap[VIRT_PCIE_ECAM].size / PCIE_MMCFG_SIZE_MIN) - 1; - build_header(linker, table_data, (void *)mcfg, "MCFG", len, 5); + build_header(linker, table_data, (void *)mcfg, "MCFG", len, 1); } /* GTDT */ @@ -413,7 +413,7 @@ build_gtdt(GArray *table_data, GArray *linker) build_header(linker, table_data, (void *)(table_data->data + gtdt_start), "GTDT", - table_data->len - gtdt_start, 5); + table_data->len - gtdt_start, 2); } /* MADT */ @@ -450,7 +450,7 @@ build_madt(GArray *table_data, GArray *linker, VirtGuestInfo *guest_info, build_header(linker, table_data, (void *)(table_data->data + madt_start), "APIC", - table_data->len - madt_start, 5); + table_data->len - madt_start, 3); } /* FADT */ @@ -507,7 +507,7 @@ build_dsdt(GArray *table_data, GArray *linker, VirtGuestInfo *guest_info) g_array_append_vals(table_data, dsdt->buf->data, dsdt->buf->len); build_header(linker, table_data, (void *)(table_data->data + table_data->len - dsdt->buf->len), - "DSDT", dsdt->buf->len, 5); + "DSDT", dsdt->buf->len, 2); free_aml_allocator(); } @@ -545,6 +545,7 @@ void virt_acpi_build(VirtGuestInfo *guest_info, AcpiBuildTables *tables) * FADT * GTDT * MADT + * MCFG * DSDT */ @@ -552,7 +553,7 @@ void virt_acpi_build(VirtGuestInfo *guest_info, AcpiBuildTables *tables) dsdt = tables_blob->len; build_dsdt(tables_blob, tables->linker, guest_info); - /* FADT MADT GTDT SPCR pointed to by RSDT */ + /* FADT MADT GTDT MCFG SPCR pointed to by RSDT */ acpi_add_table(table_offsets, tables_blob); build_fadt(tables_blob, tables->linker, dsdt);