Message ID | 20230515054928.2079268-12-sunilvl@ventanamicro.com |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:b0ea:0:b0:3b6:4342:cba0 with SMTP id b10csp6695574vqo; Sun, 14 May 2023 23:07:50 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ7P1Eh3saTGX6ls8FJ5L3SJ4ikY3D05O24K4ABXyTKghP8PaK2HB5+peksISs/gv9IzLI6F X-Received: by 2002:a05:6a20:4658:b0:f8:7372:66c0 with SMTP id eb24-20020a056a20465800b000f8737266c0mr33556557pzb.26.1684130869620; Sun, 14 May 2023 23:07:49 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1684130869; cv=none; d=google.com; s=arc-20160816; b=nXAWvkGdMTGWkCuJdTEBlGPgBDT0ZDcB6qXSWQ7idHSJCUqMwnvulTpL6wiojrerAN oyItCMyw3QGRocImeZkzClQxssD0FdgsDEdJ2gvRVgMvrMuWrv3iGGx48tclUOFEKFpY C87hunPBU4hKek0StwW625kRquQ5tAD2C5BGwPe3cg7SrPa70ENXl9cqDOEz4P78kfbT xzt+HywFBKmdSUdsO16glTqDxXp0No6KK/DxlVbcD47jK15WMjq2AYB9Sr3l8a/LsX3z frezNvftNaYC2PA6nMSeOIShhtD5aYbwg0aT+YUElD7XsIiBRxbPMeeQj0LmW1S+BMRr GnbA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=yNB5noEZPasx/OngqcP7wy15OXtx85aYSDWecQ1qX3I=; b=ULv+vRh40x90w2HXDPOcsqJ3IfHy4ur3414GeFoDlXSf439izZbzeqvBdukTBTd4ox GjSXnD6k2ISAdnH58AFKTcu9/3IrgeDIIWbFwMk53UEbt5mAgADXl0lU/qvTDJ+YsfB2 Jir4gm0Sbia50MfwvWpjqUr7qC1X6F8MkIuh/MEYVRbSvfkdb7d70jzS1/3GOm/QC8yS /burAorvihDiajWhIPiSa0j1RJjMLVJfjU/FJMHh+gq1HBoRlaaHrz7ohO1lWYlGIqO3 xBLOUCyjrUGvtq7gUEU/aabWNX9oVp2XZ2PvOo/bp2KZNxKlRWkxWLkOYBTHnsV4i6hq 7iiw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@ventanamicro.com header.s=google header.b=crUKtBVQ; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id bv185-20020a632ec2000000b0051970ed57e0si14973342pgb.9.2023.05.14.23.07.33; Sun, 14 May 2023 23:07:49 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@ventanamicro.com header.s=google header.b=crUKtBVQ; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S238380AbjEOFxr (ORCPT <rfc822;peekingduck44@gmail.com> + 99 others); Mon, 15 May 2023 01:53:47 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57820 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S238487AbjEOFwk (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Mon, 15 May 2023 01:52:40 -0400 Received: from mail-pg1-x52e.google.com (mail-pg1-x52e.google.com [IPv6:2607:f8b0:4864:20::52e]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5C8B63C00 for <linux-kernel@vger.kernel.org>; Sun, 14 May 2023 22:50:52 -0700 (PDT) Received: by mail-pg1-x52e.google.com with SMTP id 41be03b00d2f7-52867360efcso8659747a12.2 for <linux-kernel@vger.kernel.org>; Sun, 14 May 2023 22:50:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ventanamicro.com; s=google; t=1684129852; x=1686721852; 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=yNB5noEZPasx/OngqcP7wy15OXtx85aYSDWecQ1qX3I=; b=crUKtBVQVJV1vWBpuccoTSp8DaYY66fm3VKniawcVP6BKqjaKB4T2BaZyNqDyNPU7n 9YBY1TuYEPQIP65vBpgmiEENoR1RAcWrcdORTisds+fVFeKk4n6ot+7DHSQjWhfm42Ao dd8qhZ0hLmlYljm0LhvMRdBdV5496JPxOHUG3c+dIxD65S9A9Ryz9EyK68M3tzx/B0S9 JBM/ZcwzO0eRD86zNvVnVbRkCTjmonAhCiFUSmyEaFJ7WoJ5cJ4XrULn3PiTm14zJR8u OtxancRacVKlprqQD+tHP/Lkv/v3J35sEnIy3t7ws0ik1FK+XOq34vdkAgHW6F3l3d2P kubA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1684129852; x=1686721852; 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=yNB5noEZPasx/OngqcP7wy15OXtx85aYSDWecQ1qX3I=; b=D0r2rQTYiHz9fX/pkYfuFN4/JgwJWn1+Zbq0WgFbEimUsqYT6r+JkYS8s/PsE7l4Zv zdAHdLMjhsiuicEfbGsmnkcgrUJBOj0gpAxEk3VGaegGuTAfrwblecqx4Aqhjkh/ENrM 0EqdVNV61KXY5/JXw0SwPzj0bt81h9Y7Dc/lKcgkwxBiWc4WjaiNEZ1hgVKpMc5ZT2Ej WxNoH/rRMlUZYf5KT8Qmi1JIDrLll81nfoEWk/kxMPYL/4mVAHiHE0MZ+IKezVpsDpFw yuav8Z8z0wg9BjvxybWUrkshDktsZTW0ZS+k/y0/3KUVH4gMQql8A0eqo1wxowoTDcib 7/+g== X-Gm-Message-State: AC+VfDycmke/g0N3D+cknlNTvksRYSDZnH+15nKoS20ML6FS3V5ij9SR oE3P/WjJCSEhVBOXW9XTi3RpCQ== X-Received: by 2002:a17:902:b403:b0:1ac:8ad0:1703 with SMTP id x3-20020a170902b40300b001ac8ad01703mr21046473plr.35.1684129851850; Sun, 14 May 2023 22:50:51 -0700 (PDT) Received: from localhost.localdomain ([106.51.191.118]) by smtp.gmail.com with ESMTPSA id f10-20020a17090274ca00b001ab28f620d0sm12423277plt.290.2023.05.14.22.50.44 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 14 May 2023 22:50:51 -0700 (PDT) From: Sunil V L <sunilvl@ventanamicro.com> To: linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org, linux-riscv@lists.infradead.org, linux-acpi@vger.kernel.org, linux-crypto@vger.kernel.org, platform-driver-x86@vger.kernel.org, llvm@lists.linux.dev Cc: Jonathan Corbet <corbet@lwn.net>, Paul Walmsley <paul.walmsley@sifive.com>, Palmer Dabbelt <palmer@dabbelt.com>, Albert Ou <aou@eecs.berkeley.edu>, "Rafael J . Wysocki" <rafael@kernel.org>, Len Brown <lenb@kernel.org>, Sunil V L <sunilvl@ventanamicro.com>, Daniel Lezcano <daniel.lezcano@linaro.org>, Thomas Gleixner <tglx@linutronix.de>, Weili Qian <qianweili@huawei.com>, Zhou Wang <wangzhou1@hisilicon.com>, Herbert Xu <herbert@gondor.apana.org.au>, "David S . Miller" <davem@davemloft.net>, Marc Zyngier <maz@kernel.org>, Maximilian Luz <luzmaximilian@gmail.com>, Hans de Goede <hdegoede@redhat.com>, Mark Gross <markgross@kernel.org>, Nathan Chancellor <nathan@kernel.org>, Nick Desaulniers <ndesaulniers@google.com>, Tom Rix <trix@redhat.com>, "Rafael J . Wysocki" <rafael.j.wysocki@intel.com>, Conor Dooley <conor.dooley@microchip.com>, Andrew Jones <ajones@ventanamicro.com>, Palmer Dabbelt <palmer@rivosinc.com> Subject: [PATCH V6 11/21] RISC-V: smpboot: Create wrapper setup_smp() Date: Mon, 15 May 2023 11:19:18 +0530 Message-Id: <20230515054928.2079268-12-sunilvl@ventanamicro.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230515054928.2079268-1-sunilvl@ventanamicro.com> References: <20230515054928.2079268-1-sunilvl@ventanamicro.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1765939210518394799?= X-GMAIL-MSGID: =?utf-8?q?1765939210518394799?= |
Series |
Add basic ACPI support for RISC-V
|
|
Commit Message
Sunil V L
May 15, 2023, 5:49 a.m. UTC
setup_smp() currently assumes DT-based platforms. To enable ACPI, first make this a wrapper function and move existing code to a separate DT-specific function. Signed-off-by: Sunil V L <sunilvl@ventanamicro.com> Acked-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Reviewed-by: Conor Dooley <conor.dooley@microchip.com> Reviewed-by: Andrew Jones <ajones@ventanamicro.com> Reviewed-by: Palmer Dabbelt <palmer@rivosinc.com> --- arch/riscv/kernel/smpboot.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/arch/riscv/kernel/smpboot.c b/arch/riscv/kernel/smpboot.c index 445a4efee267..a2e66126b733 100644 --- a/arch/riscv/kernel/smpboot.c +++ b/arch/riscv/kernel/smpboot.c @@ -70,7 +70,7 @@ void __init smp_prepare_cpus(unsigned int max_cpus) } } -void __init setup_smp(void) +static void __init of_parse_and_init_cpus(void) { struct device_node *dn; unsigned long hart; @@ -116,6 +116,11 @@ void __init setup_smp(void) } } +void __init setup_smp(void) +{ + of_parse_and_init_cpus(); +} + static int start_secondary_cpu(int cpu, struct task_struct *tidle) { if (cpu_ops[cpu]->cpu_start)