Message ID | 20250113195525.57150-8-philmd@linaro.org |
---|---|
State | New |
Headers | show
Delivered-To: patch@linaro.org Received: by 2002:a5d:525c:0:b0:385:e875:8a9e with SMTP id k28csp1601120wrc; Mon, 13 Jan 2025 11:56:58 -0800 (PST) X-Forwarded-Encrypted: i=2; AJvYcCVTJiK5yw699z+u4gl8SgGCKf023u6cDYWzCwe6mi0GOSxo6Y813OiMl8D36dM+qNWK4s1KMg==@linaro.org X-Google-Smtp-Source: AGHT+IEeThSWzm9LLyJCktvqR8Nm+d7kGT+XxUwEIdFQaUlhr/T3B1rmJqT/1mPjGMmNXFxod1fn X-Received: by 2002:ad4:5d64:0:b0:6d8:9838:d3a9 with SMTP id 6a1803df08f44-6df9b22d71cmr259611746d6.26.1736798218156; Mon, 13 Jan 2025 11:56:58 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1736798218; cv=none; d=google.com; s=arc-20240605; b=YjozfgSbsKKf7IOdOg6MzMu7HkS8HS6oQ3F/ckQA0nVPFX0iHn9MXD8ZD5xUQcJs7s HPgjkng0DYzyA3yLPFSCOeFbx52JDrgnftmb/bjAV+V9I2WTUhhqz1i/v0Fp+ao2au+V Auq0yHRkXhqGBQI6X0IftDeP/lVdvlnAxO/s7wbaF4IKVFp5eXkLnwoQJDOQUcUMLcR6 tuh4D41FDKvUb6fG5RJaeuHSIKXhMjhN/idIb+RixbTwdO+nO2a64jTAL3fEMW6z1KMo Kx201bcWEXuQwJeGJ4u9LklsQM66/GPMc59BdHuSBj31N0gesxNJ7rlMsV1Ao33h//H0 d4nw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; 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=tkdKuqLsU14ZzZ0juxUu8/huKQ0KKnNGQSOpTw7EA2I=; fh=wMwPlu6s3WDa+luMUca6ONpSmNJKUwF5E3uCFeq1PI4=; b=HGu1Ea5uw3GtWmNRygE9osNao2zIZKysMc4d2tqIpl4IxmaKAhoOjNS8HaD0uX0bc+ lUrUwair2ypmFzqQeRdk0IBWYz2PmeHq38jbZwd/sSOk/lUxprEgbA/ImobOkmeZKQdZ B8ZkaP2Z8uHXEfOdGuLbBczJEZDWuRzytFHSFt3TdWhAR78CVYuBW5+Y0jjvEVFQysgY P3f5z+xO9LBNwqLd+VsFqx6w5OIRG8a0MYlC41Lf5tkcXmUazxRldmBNQxJ5/biaORoK dlew0zoCSRfG5iN++DjbpwhEGPzAffgEMd/16ke+WIr7iDmUkqdbnmIptZcRFd2pE0It BCzA==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=iCANKKMB; 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; dara=neutral header.i=@linaro.org Return-Path: <qemu-devel-bounces+patch=linaro.org@nongnu.org> Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id d75a77b69052e-46c873e4b09si96232641cf.251.2025.01.13.11.56.57 for <patch@linaro.org> (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Mon, 13 Jan 2025 11:56:58 -0800 (PST) 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=iCANKKMB; 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; dara=neutral header.i=@linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from <qemu-devel-bounces@nongnu.org>) id 1tXQXl-00063x-Ct; Mon, 13 Jan 2025 14:56:13 -0500 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 <philmd@linaro.org>) id 1tXQXk-00063b-Ax for qemu-devel@nongnu.org; Mon, 13 Jan 2025 14:56:12 -0500 Received: from mail-wm1-x32e.google.com ([2a00:1450:4864:20::32e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from <philmd@linaro.org>) id 1tXQXi-0007TA-NY for qemu-devel@nongnu.org; Mon, 13 Jan 2025 14:56:12 -0500 Received: by mail-wm1-x32e.google.com with SMTP id 5b1f17b1804b1-4361f664af5so54212055e9.1 for <qemu-devel@nongnu.org>; Mon, 13 Jan 2025 11:56:05 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1736798164; x=1737402964; 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=tkdKuqLsU14ZzZ0juxUu8/huKQ0KKnNGQSOpTw7EA2I=; b=iCANKKMBGIQt9QwbQZdSXgiocsjyMXu7CaCMvSA+OqANUt3YP8WYNS7ywFBIewO8Ko I39EAZ93R1pwBZcxr7dk+iZHp7WPWT2zFKhOq8C0P4alvgm69dkNeumKIi4XMfkqFQ9k IcKot4jcF11Ysoo5/2KUxmLczuYcaKxtDucM75fb/9UAi8I2cvgQCqIWcCdPy+WVkRL9 bAYXN37+lNWureiabhIpNbJ2M5fRASofmZ+5B7J1cglLW7+eoLtWyGHwfOswsW9ypy2C zck132Fack6v1r4FgsdSmg4fc9N2CnWak7DuaxvUUfNmqfqLmz5IWiRuWR5ThirtUg0G SeaQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1736798164; x=1737402964; 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=tkdKuqLsU14ZzZ0juxUu8/huKQ0KKnNGQSOpTw7EA2I=; b=OtRB92Wkv5woXpru8mhQ8Q2ON9GnaztpvZ4JVF3M6/4cwAHB14T2ojf75qfOGDnArg +LzM5NH1vrTEFN+xFhlNdCHFFkKkKDOhYrVV9eeg1EX5YVYWGdavJeBO/+x448uNlzUZ Fn4l/7eXA3LkD0SnBXpoJQGGGuD8OBwSP4takCcv1UYYRrY6k/ferZIcFdygUIdk164L 63UTTtnJEr2gOFd00PaWVBeYX8x86+gdspBu7vCRMk/pvZktx9F+dQn6X6R65UkhYgvQ snVMNFkMzd9uBwrAvFtOnupAvyfKAw1xQIIrNOAqyYzUKi6gsaqnmf+9gLOW+0y0dOrB iSDw== X-Gm-Message-State: AOJu0Yz9c9NYDnXpLYJJZC4i/7E8L8EQ6Ah55buSp6b61jkFuXNXSa8O +KDyhaPxn6qnybFgXm3GoV3hih9FdmRoZINAqnLznLZNj942RnSoPaFhTV7VEnN+wNTfnOe31+C fsys= X-Gm-Gg: ASbGncsnHpUCvWZjzPtGcpp7UQes6lE1t47GCCVU19RftMxsmdmFPh+9oFW/GHNUFOt +tV0Td0XeQChA2sHtzwFHSuNvouIHIZ+09IodbvFmxJakfwzCfaoZA83p42F5AFHrzvvqHAkrq8 0n0S6ImujFi9Owf9sznsc75BoKeHJ/gxRHEO5jZHzcepe1Bg6kPNMV9KCNSIhHaZsNDgWzbpBXH bfTgZY+aAYEsPP2nzE/8CQ0Vb6w+rch2JeU/aCpqzC8WhrgRTb7ye7KPqjoUVjIwYYDeNRQblB0 ilPtaUaVr/vaI5YMnQA6wykljFbYFcI= X-Received: by 2002:a05:600c:138a:b0:434:a781:f5d5 with SMTP id 5b1f17b1804b1-436e271bcb3mr221749155e9.30.1736798163905; Mon, 13 Jan 2025 11:56:03 -0800 (PST) Received: from localhost.localdomain (88-187-86-199.subs.proxad.net. [88.187.86.199]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-436e9e37d74sm153210325e9.29.2025.01.13.11.56.02 (version=TLS1_3 cipher=TLS_CHACHA20_POLY1305_SHA256 bits=256/256); Mon, 13 Jan 2025 11:56:03 -0800 (PST) From: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= <philmd@linaro.org> To: qemu-devel@nongnu.org Cc: Paul Burton <paulburton@kernel.org>, Aurelien Jarno <aurelien@aurel32.net>, =?utf-8?q?Philippe_Mathieu-Daud?= =?utf-8?q?=C3=A9?= <philmd@linaro.org>, Jiaxun Yang <jiaxun.yang@flygoat.com>, Aleksandar Rikalo <arikalo@gmail.com>, Huacai Chen <chenhuacai@kernel.org> Subject: [PATCH v2 07/19] hw/mips/boston: Propagate CPU to gen_firmware() Date: Mon, 13 Jan 2025 20:55:13 +0100 Message-ID: <20250113195525.57150-8-philmd@linaro.org> X-Mailer: git-send-email 2.47.1 In-Reply-To: <20250113195525.57150-1-philmd@linaro.org> References: <20250113195525.57150-1-philmd@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Received-SPF: pass client-ip=2a00:1450:4864:20::32e; envelope-from=philmd@linaro.org; helo=mail-wm1-x32e.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 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: <qemu-devel.nongnu.org> List-Unsubscribe: <https://lists.nongnu.org/mailman/options/qemu-devel>, <mailto:qemu-devel-request@nongnu.org?subject=unsubscribe> List-Archive: <https://lists.nongnu.org/archive/html/qemu-devel> List-Post: <mailto:qemu-devel@nongnu.org> List-Help: <mailto:qemu-devel-request@nongnu.org?subject=help> List-Subscribe: <https://lists.nongnu.org/mailman/listinfo/qemu-devel>, <mailto:qemu-devel-request@nongnu.org?subject=subscribe> Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org |
Series |
hw/mips: Remove all uses of &first_cpu
|
expand
|
diff --git a/hw/mips/boston.c b/hw/mips/boston.c index 63dc654192a..491e1c4f7ea 100644 --- a/hw/mips/boston.c +++ b/hw/mips/boston.c @@ -323,7 +323,8 @@ static void boston_register_types(void) } type_init(boston_register_types) -static void gen_firmware(void *p, hwaddr kernel_entry, hwaddr fdt_addr) +static void gen_firmware(const MIPSCPU *cpu, void *p, + hwaddr kernel_entry, hwaddr fdt_addr) { uint64_t regaddr; @@ -825,7 +826,9 @@ static void boston_mach_init(MachineState *machine) } } - gen_firmware(memory_region_get_ram_ptr(flash) + 0x7c00000, + gen_firmware(MIPS_CPU(object_resolve_path_component(OBJECT(&s->cps), + "cpu[0]")), + memory_region_get_ram_ptr(flash) + 0x7c00000, s->kernel_entry, s->fdt_base); } else if (!qtest_enabled()) { error_report("Please provide either a -kernel or -bios argument");
Propagate a CPU to gen_firmware(). Since we expect the first CPU to run the firmware, get it from the CPS in boston_mach_init(), resolving it using its QOM path. Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org> --- hw/mips/boston.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-)