Message ID | 20230407083453.6305-5-lvjianmin@loongson.cn |
---|---|
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 b10csp143994vqo; Fri, 7 Apr 2023 01:48:54 -0700 (PDT) X-Google-Smtp-Source: AKy350bxFAOGyN3rfiQubKeb6r/k1/9+bYPDVi616o5XKMht6X73zofp+AZxhFgbjW0OPZ4sS6+2 X-Received: by 2002:a17:907:76e8:b0:92f:efdc:610e with SMTP id kg8-20020a17090776e800b0092fefdc610emr1620269ejc.66.1680857334361; Fri, 07 Apr 2023 01:48:54 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1680857334; cv=none; d=google.com; s=arc-20160816; b=B1Qa3IPT0pAvfponTNg0x4H3UUHc218JY16uTgwG7Fc4zuGPyTl2dAQNrmDzr4p2QT zeUqR+YqT62glZJ0z8JWXepX/yGR80rRC64AyuppSbTPXgfGY4V36dmMYLZ5fb+XXRan 4KX+6iiSW0BZi5ehXmvFcnKAdZeCCcK8k8vgIBamhz+leopg5BVVSmscukxlcm7hovvo 5gAMngRfgjjZEx9F3sAF/Ywr+Vdspu5dBq1wpAJmiNPmOwFDc9JrOBm6YLp94itdr9iv UsPZOwQJonNgVZh0vNjaq5qO6wN48j/A3EqE+4G5Fa0ft7ajEsbwIURd1f+E3Gpr2vu9 gNpw== 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; bh=njZ8azFzq0H3aO5U6fDdMOyvjHP52NQ5XL/KqMFg4wI=; b=Ww5qPGymCxUsAuT+igWVb8d1roym88inWd+abks/eZfx4BM+zKNWCROU99e0C2PQzM UO91iUEvOrAvDHtz2tPrw3RcpayYF6qnFdU9ZZovfwARr5dpy2s1XIElipkiWuwy+MGe /Q6l4W+LVHDARUDCmGdHeP+PW+M11nRhBJM2zhM0p+7ilXKeR9n/kSc3ov5IwJivXpSh n2Ax2i0GYQdDwdbthE7hIJV+NXpfG+7Anqd1dT+aStLgmRdyPO9mb613kgFXYTlc9VBi 5HzLkAFqqXuo0P2lVNiLPfdKRCg0Y+pcH/DH0UnYtjfGgkFF44Cr7xRlsAOASB0YZxgN 7deA== ARC-Authentication-Results: i=1; mx.google.com; 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 gl8-20020a170906e0c800b00930bc91dcedsi2001279ejb.881.2023.04.07.01.48.30; Fri, 07 Apr 2023 01:48:54 -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; 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 S240211AbjDGIf0 (ORCPT <rfc822;a1648639935@gmail.com> + 99 others); Fri, 7 Apr 2023 04:35:26 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:53180 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232635AbjDGIfO (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Fri, 7 Apr 2023 04:35:14 -0400 Received: from loongson.cn (mail.loongson.cn [114.242.206.163]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 25B1510A; Fri, 7 Apr 2023 01:35:09 -0700 (PDT) Received: from loongson.cn (unknown [10.20.42.153]) by gateway (Coremail) with SMTP id _____8AxYcy91S9kvscXAA--.36974S3; Fri, 07 Apr 2023 16:35:09 +0800 (CST) Received: from loongson-pc.loongson.cn (unknown [10.20.42.153]) by localhost.localdomain (Coremail) with SMTP id AQAAf8AxGL2t1S9kKRwYAA--.21995S6; Fri, 07 Apr 2023 16:35:08 +0800 (CST) From: Jianmin Lv <lvjianmin@loongson.cn> To: Thomas Gleixner <tglx@linutronix.de>, Marc Zyngier <maz@kernel.org> Cc: linux-kernel@vger.kernel.org, loongarch@lists.linux.dev, Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>, Jiaxun Yang <jiaxun.yang@flygoat.com>, Huacai Chen <chenhuacai@loongson.cn>, loongson-kernel@lists.loongnix.cn, stable@vger.kernel.org Subject: [PATCH V3 4/5] irqchip/loongson-pch-pic: Fix registration of syscore_ops Date: Fri, 7 Apr 2023 16:34:52 +0800 Message-Id: <20230407083453.6305-5-lvjianmin@loongson.cn> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20230407083453.6305-1-lvjianmin@loongson.cn> References: <20230407083453.6305-1-lvjianmin@loongson.cn> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-CM-TRANSID: AQAAf8AxGL2t1S9kKRwYAA--.21995S6 X-CM-SenderInfo: 5oymxthqpl0qxorr0wxvrqhubq/ X-Coremail-Antispam: 1Uk129KBjvdXoW7Xr43Xr4UCFyUAryDuFy8Zrb_yoWkXFcEgr yIqa9rA348Zr1Uu3yfZr15ZF4aqa1UWFn5uFZ8KF9xJ3yrX34fJr12yrn8Cw47Ga4rAFnx C395Wr9akryxCjkaLaAFLSUrUUUUnb8apTn2vfkv8UJUUUU8wcxFpf9Il3svdxBIdaVrn0 xqx4xG64xvF2IEw4CE5I8CrVC2j2Jv73VFW2AGmfu7bjvjm3AaLaJ3UjIYCTnIWjp_UUUY A7kC6x804xWl14x267AKxVWUJVW8JwAFc2x0x2IEx4CE42xK8VAvwI8IcIk0rVWrJVCq3w AFIxvE14AKwVWUXVWUAwA2ocxC64kIII0Yj41l84x0c7CEw4AK67xGY2AK021l84ACjcxK 6xIIjxv20xvE14v26F1j6w1UM28EF7xvwVC0I7IYx2IY6xkF7I0E14v26F4j6r4UJwA2z4 x0Y4vEx4A2jsIE14v26F4UJVW0owA2z4x0Y4vEx4A2jsIEc7CjxVAFwI0_Cr1j6rxdM2kK e7AKxVWUAVWUtwAS0I0E0xvYzxvE52x082IY62kv0487Mc804VCY07AIYIkI8VC2zVCFFI 0UMc02F40EFcxC0VAKzVAqx4xG6I80ewAv7VC0I7IYx2IY67AKxVWrXVW3AwAv7VC2z280 aVAFwI0_Gr0_Cr1lOx8S6xCaFVCjc4AY6r1j6r4UM4x0Y48IcxkI7VAKI48JMxkF7I0En4 kS14v26r126r1DMxAIw28IcxkI7VAKI48JMxC20s026xCaFVCjc4AY6r1j6r4UMxCIbckI 1I0E14v26r126r1DMI8I3I0E5I8CrVAFwI0_Jr0_Jr4lx2IqxVCjr7xvwVAFwI0_JrI_Jr Wlx4CE17CEb7AF67AKxVWUtVW8ZwCIc40Y0x0EwIxGrwCI42IY6xIIjxv20xvE14v26ryj 6F1UMIIF0xvE2Ix0cI8IcVCY1x0267AKxVW8JVWxJwCI42IY6xAIw20EY4v20xvaj40_Jr 0_JF4lIxAIcVC2z280aVAFwI0_Gr0_Cr1lIxAIcVC2z280aVCY1x0267AKxVW8JVW8JrUv cSsGvfC2KfnxnUUI43ZEXa7IU0_WrPUUUUU== X-Spam-Status: No, score=-0.0 required=5.0 tests=SPF_HELO_PASS,SPF_PASS 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?1762506660669623425?= X-GMAIL-MSGID: =?utf-8?q?1762506660669623425?= |
Series |
Fix some issues of irq controllers for dual-bridges scenario
|
|
Commit Message
吕建民
April 7, 2023, 8:34 a.m. UTC
When support suspend/resume for loongson-pch-pic, the syscore_ops
is registered twice in dual-bridges machines where there are two
pch-pic IRQ domains. Repeated registration of an same syscore_ops
broke syscore_ops_list, so the patch will corret it.
Fixes: 1ed008a2c331 ("irqchip/loongson-pch-pic: Add suspend/resume support")
Cc: stable@vger.kernel.org
Signed-off-by: Jianmin Lv <lvjianmin@loongson.cn>
---
drivers/irqchip/irq-loongson-pch-pic.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/irqchip/irq-loongson-pch-pic.c b/drivers/irqchip/irq-loongson-pch-pic.c index 437f1af693d0..64fa67d4ee7a 100644 --- a/drivers/irqchip/irq-loongson-pch-pic.c +++ b/drivers/irqchip/irq-loongson-pch-pic.c @@ -311,7 +311,8 @@ static int pch_pic_init(phys_addr_t addr, unsigned long size, int vec_base, pch_pic_handle[nr_pics] = domain_handle; pch_pic_priv[nr_pics++] = priv; - register_syscore_ops(&pch_pic_syscore_ops); + if (nr_pics == 1) + register_syscore_ops(&pch_pic_syscore_ops); return 0;