From patchwork Tue Jun 18 15:59:41 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: 805219 Delivered-To: patch@linaro.org Received: by 2002:a05:6000:144:b0:362:4979:7f74 with SMTP id r4csp271632wrx; Tue, 18 Jun 2024 09:04:06 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCViHvX5H764wFuFwZl8SDh14HmV8Y1fuH9YTlEDMxTx3z8F9dCIYEm/rIWd9qbPOfcaM8YaRsJ+NeT8/oDi91aB X-Google-Smtp-Source: AGHT+IElIidDiTEohIEowVr6g+MuRi5kQUuhXBpWNW7ZdYzqyhcZmOWsWv5U/hVHfJV1TdNg3Usd X-Received: by 2002:a05:6870:9121:b0:259:8b7d:1544 with SMTP id 586e51a60fabf-25c949911e3mr225455fac.15.1718726646671; Tue, 18 Jun 2024 09:04:06 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1718726646; cv=none; d=google.com; s=arc-20160816; b=rycUG9l8wypOsVTL+gt1pUOeFZA1Kl3Z4YloYqwhkD45erczOJjxSr3aAD0xvxdh4e I3g3aOMNebO1pGZToKJLTs9Z6GyTYh9kgrSioMzHGSYHPNXthtmdTH+RUUPRpbevdbwV P5KbANlziXvNk9GAfVIB9+ENURQgSq8PUTRLeNNc1rd4LplkH9aAX7AMgbniJnxQb/b/ aBinlkAO53z7vxD47E67ltJp449DYGdVyHkfcAACEyA5n0j7+VymRmSHEzcUIEc/YDyd EnoB8oV+IGToBia2rbuL377YmcVdbxJpSRPYiZg/yl8yY5mBHAnCvlSSYSBLPZ8nLSw/ gXCg== 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=481P++9pg0zI2n/4exvP8oZom8l9jtwiiKGRbZrAgxw=; fh=QeIS5kb1Uh2g1z6dWJxoYMIPD1Pl4adL6YUWYeE5yJk=; b=qMeHUfUIJAm4Md21Thlqns3+O8/GS430hTuMWMgf6/bDr1voaAnrcF46Fe7BgpBhY8 lCFuevlxsy66FBiVC+kfsB0N6CS7juMoqLV3nD3LEZ1UfRGPTF6TIbzh86sTutE/rVEw +ArkryBD/JO4mTp/jAZhT8GXxqA65fDy0IYccfT2TxbXV8d5jrar9CKGHMG/OoAQ6sRd 52fyLlda/FOD3yEZQ62NsiMousvTFYMAylLzdsLYGX+3U05KV/XCxsr4HaiUHA+xDV/C jr8o/VnbOY1fMmcADhkQbxH7F2IohZdeYoU69/9XzQwpEPYszapV9HEQY1EDgVf97YHz TiiA==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="t/IFGzp0"; 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 ada2fe7eead31-48da4471b4fsi2062262137.285.2024.06.18.09.04.06 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Tue, 18 Jun 2024 09:04:06 -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="t/IFGzp0"; 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 1sJbIU-0006iz-Lo; Tue, 18 Jun 2024 12:03:02 -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 1sJbI6-0005mr-Da for qemu-devel@nongnu.org; Tue, 18 Jun 2024 12:02:38 -0400 Received: from mail-ed1-x532.google.com ([2a00:1450:4864:20::532]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1sJbI4-0006z2-P5 for qemu-devel@nongnu.org; Tue, 18 Jun 2024 12:02:38 -0400 Received: by mail-ed1-x532.google.com with SMTP id 4fb4d7f45d1cf-57d06101d76so316376a12.3 for ; Tue, 18 Jun 2024 09:02:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1718726554; x=1719331354; 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=481P++9pg0zI2n/4exvP8oZom8l9jtwiiKGRbZrAgxw=; b=t/IFGzp0tf75LtSiVqmcNdMVqB3T80hQy8V7gS5dYbXVoG6NxhKtavRZ6P08RWUa3O Ed6j2KasFBpmBYMpSK5KB57nkLTGV8wlWIXpuDQrBqh0woALiJZJKUVFMKP9Qv2igAgo Il2yjk0rqs1Qwv9ky0WaQG0D8CQSb0kqxshvjbQoQIB5kfBRnF+cZ+ZiUpViBXveVW4E +xCpXym+ZFoNa3nSLfHrLcMeOV3EGxqi6C13DUFQXO/+zj30uXOM8XSNnrCgwYvUXJ12 E0LYonXP+w/Mo9PEKG9hd2pXMYCNtnriJl/3j802f9enZBxnxxg7BnwO12/N5F6B89OL 76ug== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1718726554; x=1719331354; 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=481P++9pg0zI2n/4exvP8oZom8l9jtwiiKGRbZrAgxw=; b=Qoz7/qAM4Fcm3JqYBj37D1+jMYb3F9BeTJ6tAVGFIMbm9ScWQi6cU1K4ijth7F1N5Y Ag2tW9mDTCXri3+kAQpvO6m7J5FsaaZbwFwYqTmvW0TZIltxrU0RCfkhqE+qvCbHRoUM oDVmmQPlAfsf7EFArzcxQzcNbo7HyYSrds0NtXfQQ9tjIKjhjSPfPVB4G2ZAsrDbPHU7 /eVNFg/fRjnJtBl9OZ8iaddfwVZdSR14eECY6rMYHmIv8Bz53J54EOiCF0/LUXs8lbi1 CRQNF0Zo/f8HpQEUmNSzSw2m0KtDACcsQG+PR93yNOEQjrrX9VKF5m94+WfhiSh5o7tM +yLQ== X-Gm-Message-State: AOJu0YwEgptqFirDwpMKMVwnFTK52EJ3ZybMGpC0kl3KFgpHXgKqZwAx jHrU5sLrY9xw/UVHzAjvg+U0wbIGBamBpq3p2ulj/UEAsJ1pxtf9t4HBQwvXTDMT4bOV8dh/f08 r X-Received: by 2002:a50:fb15:0:b0:57d:3be:5ec2 with SMTP id 4fb4d7f45d1cf-57d03be6373mr910594a12.30.1718726554554; Tue, 18 Jun 2024 09:02:34 -0700 (PDT) Received: from m1x-phil.lan ([176.187.212.55]) by smtp.gmail.com with ESMTPSA id 4fb4d7f45d1cf-57cb72da32fsm7877548a12.36.2024.06.18.09.02.33 (version=TLS1_3 cipher=TLS_CHACHA20_POLY1305_SHA256 bits=256/256); Tue, 18 Jun 2024 09:02:34 -0700 (PDT) From: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Cc: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= , Thomas Huth , Zhao Liu , Igor Mammedov Subject: [PULL 19/76] hw/i386/acpi: Remove AcpiBuildState::rsdp field Date: Tue, 18 Jun 2024 17:59:41 +0200 Message-ID: <20240618160039.36108-20-philmd@linaro.org> X-Mailer: git-send-email 2.41.0 In-Reply-To: <20240618160039.36108-1-philmd@linaro.org> References: <20240618160039.36108-1-philmd@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::532; envelope-from=philmd@linaro.org; helo=mail-ed1-x532.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 Message-Id: <20240617071118.60464-20-philmd@linaro.org> --- 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);