From patchwork Mon Jun 17 07:11:14 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= X-Patchwork-Id: 804858 Delivered-To: patch@linaro.org Received: by 2002:adf:fb90:0:b0:360:93e7:1765 with SMTP id a16csp434661wrr; Mon, 17 Jun 2024 00:14:22 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCXy+H6Z4TJBuAVd1V2s7oJGo7HIJVsS/B+3TZu1oL6Cm34Q1C1bSUs3jgHNRoyJqoCRaZIeqs8nLXmk9HRE7Alt X-Google-Smtp-Source: AGHT+IHox851BWXpSooIhmwJJ19k7Syg1CWkE7wjZOQAvVgtOsRtI6vr5CMg3PJ2bgsiczfMZYVz X-Received: by 2002:a05:622a:148d:b0:440:f8df:9dae with SMTP id d75a77b69052e-44216b35de8mr95948801cf.58.1718608462676; Mon, 17 Jun 2024 00:14:22 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1718608462; cv=none; d=google.com; s=arc-20160816; b=R2CEyQcB2YvbyykAn2ff0YSST1DQuzMwWlLPFfctoy5AKVsx8In03s6FOsWjtXIAOs AR2PdayyW9QvST/LHY1y3UOYX9FMiAnvOE3j+GnWNFVy07yF/+ViU2Ybx23ZKKAN79iy eLAv3ciibXPbf1AVoacGj8ZsILCHrZch28HQrqx9Ld06dG1XHA2JtOqBrli5TeCHWfCc UY5u18p5NFmQTKY8My1jcmoXbVuOcrFiPvILQjkt0HCbNTc186yN4jNaLKSSB0BGYE8J gLYHzT/9jkAvR3YLy/9/l877zxwUtF2cFZWEcWOJPashfePb8Hp0bVCsKCZaraHQlKhe dDsg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=8HoghgUjXslv99c0oIEDxG9bbeaop6k9yBJ/Y2X/84U=; fh=LxU1EPCBVYorV++vrCt2dyzDsbIeuRBouOVrSj5U16k=; b=OCjqASc2/712Y2dEoExUoL3uaaRPOAQrzQtwvdTUfgC4uBN0P1PZwBTx7+LMBc/Qhu YfiDf4o8bdBQbszLcPNa82VTPln1sKYB9P+Pe53tDDB/7hZC4BAwCx1xoJmidK10Xjcr edCdVKYeaVn5XssBzU2D3VVQPd5Xt3UxyqaKstF5p3r+D469Qs5zYsMS032VERtiKIjk zl0fptYCuKLDKzBxK8vcjh2WD4HCOy24+nWVeB7m8jN79O5wEZ8M3YpC8eZjHhe7IRx9 G9hbY7AXWpF5SbaWd2CjYS8AxPtxQ3nVhFBQWHjTUm06qk5LjaUxZZuET+QI9XzQWw5L Zn1Q==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=xihpoSuL; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id d75a77b69052e-441f2fe6504si89798491cf.573.2024.06.17.00.14.22 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Mon, 17 Jun 2024 00:14:22 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=xihpoSuL; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1sJ6Ya-0000y8-0x; Mon, 17 Jun 2024 03:13:36 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1sJ6YG-0000Vj-Gr for qemu-devel@nongnu.org; Mon, 17 Jun 2024 03:13:19 -0400 Received: from mail-ed1-x536.google.com ([2a00:1450:4864:20::536]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1sJ6YE-0002RX-KO for qemu-devel@nongnu.org; Mon, 17 Jun 2024 03:13:16 -0400 Received: by mail-ed1-x536.google.com with SMTP id 4fb4d7f45d1cf-579fa270e53so6014147a12.3 for ; Mon, 17 Jun 2024 00:13:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1718608388; x=1719213188; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=8HoghgUjXslv99c0oIEDxG9bbeaop6k9yBJ/Y2X/84U=; b=xihpoSuLiTV4xozsyvC2iN6IxIyl9n3F7ELqbX6naqOZ1MblgRJH8Dkf6Ny29TeeXo Kfg8mL+k4Ql5bsYwdio5y9vxI0aD1ip49Ytq5GIEKiQe6jUE+xLXLE57MjxaAx+RHIOR whjeDZ8b49LPOZ9ANk3n7dvTPYiDu6FcykvbNEgO7FX5BQSzeiQSlaQQOQm21yzlq4pi LFJ6RsIDxf+pIq0qe4t3chqu4t3qVx2ZmJ5rlTHlDU8EdmlmsenFjv77gj9cSJ1JUpy0 t8XTiHGB/i8AsV0yGi7SYzsEGcpJrH3MS//rvYIRkXDNQ5Cw+8jdr0+cXtCjBKD0sYuB tQMQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1718608388; x=1719213188; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=8HoghgUjXslv99c0oIEDxG9bbeaop6k9yBJ/Y2X/84U=; b=Bat8S6+GAetkOv2u7RhGSt6Lp6RdmdTGhCy6Vvspu3uEZ81ggQt8VNonpYQpGbN82T T8k/EDmWEUuX+NCKkhqXb6TcEPjg4lihHOeEJpqieeTzBDXCCzOaL0tRPs8ChTjb2g/+ DGCasLhPwvCX9PbU+VeXeU7Ue3fKnqWLbG3KV7inp/wNDR6yBHn0gGQ5xYBCDz1fvtGB hT46S5GJZb6vKnNGFZhA3RU8GxvNUtk1zbou6jaiDo/m/q3dai1OtgZ9BVIpOwAFVUDa 26VrFgoa/Hc4AAux8+9tk793kvTKGX6H2mvcefQm7f7k3FOt33oxbCr/818K6Y5OAMOd axPw== X-Gm-Message-State: AOJu0YyX8SaDdwVNU3P8YbZjK33LXyzczr+5R5UB1TXz/NjwQUgeFJjH 3wPF7mepr1rpRerCwX+uP77q1SK3PQX/do9aQPrjyYSHL3CAXZmW73seg+8zozIayFvnileljYC GMEI= X-Received: by 2002:a50:9557:0:b0:57a:33a5:9b71 with SMTP id 4fb4d7f45d1cf-57cbd69eb5dmr8062641a12.33.1718608387738; Mon, 17 Jun 2024 00:13:07 -0700 (PDT) Received: from m1x-phil.lan ([176.176.169.90]) by smtp.gmail.com with ESMTPSA id 4fb4d7f45d1cf-57cb741e782sm5967415a12.64.2024.06.17.00.13.06 (version=TLS1_3 cipher=TLS_CHACHA20_POLY1305_SHA256 bits=256/256); Mon, 17 Jun 2024 00:13:07 -0700 (PDT) From: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Cc: Paolo Bonzini , Igor Mammedov , "Michael S. Tsirkin" , =?utf-8?q?Philippe_Mathieu-Daud?= =?utf-8?q?=C3=A9?= , Thomas Huth , Zhao Liu Subject: [PATCH v6 19/23] hw/i386/acpi: Remove AcpiBuildState::rsdp field Date: Mon, 17 Jun 2024 09:11:14 +0200 Message-ID: <20240617071118.60464-20-philmd@linaro.org> X-Mailer: git-send-email 2.41.0 In-Reply-To: <20240617071118.60464-1-philmd@linaro.org> References: <20240617071118.60464-1-philmd@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::536; envelope-from=philmd@linaro.org; helo=mail-ed1-x536.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 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 AcpiBuildState::rsdp is always NULL, remove it, simplifying acpi_build_update(). Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Thomas Huth Reviewed-by: Zhao Liu Reviewed-by: Igor Mammedov --- hw/i386/acpi-build.c | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/hw/i386/acpi-build.c b/hw/i386/acpi-build.c index 158e74f64a..f4e366f64f 100644 --- a/hw/i386/acpi-build.c +++ b/hw/i386/acpi-build.c @@ -2458,7 +2458,6 @@ struct AcpiBuildState { MemoryRegion *table_mr; /* Is table patched? */ uint8_t patched; - void *rsdp; MemoryRegion *rsdp_mr; MemoryRegion *linker_mr; } AcpiBuildState; @@ -2714,11 +2713,7 @@ static void acpi_build_update(void *build_opaque) acpi_ram_update(build_state->table_mr, tables.table_data); - if (build_state->rsdp) { - memcpy(build_state->rsdp, tables.rsdp->data, acpi_data_len(tables.rsdp)); - } else { - acpi_ram_update(build_state->rsdp_mr, tables.rsdp); - } + acpi_ram_update(build_state->rsdp_mr, tables.rsdp); acpi_ram_update(build_state->linker_mr, tables.linker->cmd_blob); acpi_build_tables_cleanup(&tables, true); @@ -2804,7 +2799,6 @@ void acpi_setup(void) tables.vmgenid); } - build_state->rsdp = NULL; build_state->rsdp_mr = acpi_add_rom_blob(acpi_build_update, build_state, tables.rsdp, ACPI_BUILD_RSDP_FILE);