Received: by 2002:a05:6359:c8b:b0:c7:702f:21d4 with SMTP id go11csp600548rwb; Wed, 28 Sep 2022 06:56:18 -0700 (PDT) X-Google-Smtp-Source: AMsMyM7XiX3opU6RDHQazOIuZXixECbzplvzcFkYp29GlF5ElZTOtm7Qs/THX7bW2wEXzKtn+xDd X-Received: by 2002:a17:90b:3b47:b0:202:d9d4:23f7 with SMTP id ot7-20020a17090b3b4700b00202d9d423f7mr10721793pjb.56.1664373378153; Wed, 28 Sep 2022 06:56:18 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1664373378; cv=none; d=google.com; s=arc-20160816; b=j7CzWR0BgeuwjrXv8dFS6GJDkXiERetYZ3/b6CDbF6EzdKaK0ASMFr6+86yWtVcxE/ CFmI9Ay1yp3DVD8ff5jgr8wL3lLNMMyVUxmkPTTx6l0Y+heb8S5P+ZtIfE7RC42UoOHm Vsv5wXMvVcGKQRFC8/2f//3JdKG/doAndfLl1efIzCC4ge5zFGq0ZQ9SZpLPXE1AqRJF 5XLf1PP2zPb9dG8+WdZkkvKKhlRhX6Ntg2nCrBF6y4zM73ER+bVJkG5mvhTEQOLaj31e XQsplHkUJ9eexmr1NcYxRsf48hJrA60cOC7ZMtAqKJX0+bQuCrcpIxyYmMUcuPsx3Q+w TLrQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:robot-unsubscribe :robot-id:message-id:mime-version:references:in-reply-to:cc:subject :to:reply-to:sender:from:dkim-signature:dkim-signature:date; bh=ezA3nOAK0hQ5krIIxLg2+ffpT67T6wPcZS73xL5As4M=; b=X/nnDzewFs7nkItslqnGCwKY4HSoy5UNT2zYKuYZnruWJndmMoV/blscMmnvWY12SF BFr9QGd5NOIHk+wXvszQvfg0FkSZsCKa21BFJoZKesabZvo9yG1PW4Pw2IGIUFqWF+SS 1w+JBoxmlqB+AiuCPS4v6fGyd2kQD4V/ThpRiweAkcXQhhuFgI9uX2zwj3xOnmnZ0LxQ jaX+qV80F/Ebf+0Yj1g7hmiCZTie5S9NJjiWFFJp+63B+7efrYwyOe+ZKZb9jqtoNHS6 B7Zm3D7Fu/9AwQFBQmAXMRVPslgLnCNb3Wbu2R7uC70xR622hgGhv4q5GWeqSZJbagyZ fbUw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b="2/beQCKm"; dkim=neutral (no key) header.i=@linutronix.de; 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; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id s1-20020a63a301000000b00434c18fdd78si6033189pge.765.2022.09.28.06.56.06; Wed, 28 Sep 2022 06:56:18 -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=@linutronix.de header.s=2020 header.b="2/beQCKm"; dkim=neutral (no key) header.i=@linutronix.de; 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; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234162AbiI1Nhu (ORCPT + 99 others); Wed, 28 Sep 2022 09:37:50 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45192 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234037AbiI1Nh0 (ORCPT ); Wed, 28 Sep 2022 09:37:26 -0400 Received: from galois.linutronix.de (Galois.linutronix.de [193.142.43.55]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D2B608E0FE for ; Wed, 28 Sep 2022 06:37:24 -0700 (PDT) Date: Wed, 28 Sep 2022 13:37:22 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1664372243; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=ezA3nOAK0hQ5krIIxLg2+ffpT67T6wPcZS73xL5As4M=; b=2/beQCKmNnmkHNidykrnIAvJ4FFGuTw/uDpcAXPXU/5/4zNQLNZ2iplJR1GO2mPFn+cRuV 8ieXvT1r6Yw2qj4oS58QFSJYo1ZhvE9i76VWLWNOIYofP5hsHjwjsFmvzyUb9kpz/2seiq jLeBwTmv6Hs9uTdYy6PWAhpMJNF6JqP/8z0VkViVLo1qww/Jcgmb60OlsFr/g3rbZATaat Ewru0F42vtKpp80iqvErA3dqFgNaoMv/jEdQQDT+oRJGPvmvWbhoNd0I5yk2N4b9MUfBGM 6Kqak2HNq1aGzQBS92nEnLK3Ft/nsigMthcs4p4k6+kG1w/RVpCNk0F0JNN4hA== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1664372243; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=ezA3nOAK0hQ5krIIxLg2+ffpT67T6wPcZS73xL5As4M=; b=xptjYPb83iHQNw+Xz4V7RC3B2L9Qc1nT1p8qDEJ5v81gYc9xOZRZGqGZpz3KhA+B+Ovh2A zgZcFSw5uGQovSDw== From: "irqchip-bot for Huacai Chen" Sender: tip-bot2@linutronix.de Reply-to: linux-kernel@vger.kernel.org To: linux-kernel@vger.kernel.org Subject: [irqchip: irq/irqchip-next] irqchip: Make irqchip_init() usable on pure ACPI systems Cc: Huacai Chen , Tiezhu Yang , Marc Zyngier , tglx@linutronix.de In-Reply-To: <20220927124557.3246737-1-chenhuacai@loongson.cn> References: <20220927124557.3246737-1-chenhuacai@loongson.cn> MIME-Version: 1.0 Message-ID: <166437224234.401.12622502106684377053.tip-bot2@tip-bot2> Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED,SPF_HELO_NONE, SPF_PASS autolearn=ham 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: X-Mailing-List: linux-kernel@vger.kernel.org The following commit has been merged into the irq/irqchip-next branch of irqchip: Commit-ID: 612d5494aef9bd2ab68d585a8c0ac2b16d12d520 Gitweb: https://git.kernel.org/pub/scm/linux/kernel/git/maz/arm-platforms/612d5494aef9bd2ab68d585a8c0ac2b16d12d520 Author: Huacai Chen AuthorDate: Tue, 27 Sep 2022 20:45:57 +08:00 Committer: Marc Zyngier CommitterDate: Wed, 28 Sep 2022 14:11:28 +01:00 irqchip: Make irqchip_init() usable on pure ACPI systems Pure ACPI systems (e.g., LoongArch) do not need OF_IRQ, but still require irqchip_init() to perform the ACPI irqchip probing, even when OF_IRQ isn't selected. Relax the dependency to enable the generic irqchip support when ACPI_GENERIC_GSI is configured. Signed-off-by: Huacai Chen Tested-by: Tiezhu Yang [maz: revamped commit message] Signed-off-by: Marc Zyngier Link: https://lore.kernel.org/r/20220927124557.3246737-1-chenhuacai@loongson.cn --- drivers/irqchip/Kconfig | 2 +- include/linux/of_irq.h | 6 ++++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/drivers/irqchip/Kconfig b/drivers/irqchip/Kconfig index 66b9fa4..93ad04d 100644 --- a/drivers/irqchip/Kconfig +++ b/drivers/irqchip/Kconfig @@ -3,7 +3,7 @@ menu "IRQ chip support" config IRQCHIP def_bool y - depends on OF_IRQ + depends on (OF_IRQ || ACPI_GENERIC_GSI) config ARM_GIC bool diff --git a/include/linux/of_irq.h b/include/linux/of_irq.h index 83fccd0..d6d3eae 100644 --- a/include/linux/of_irq.h +++ b/include/linux/of_irq.h @@ -37,9 +37,8 @@ extern unsigned int irq_create_of_mapping(struct of_phandle_args *irq_data); extern int of_irq_to_resource(struct device_node *dev, int index, struct resource *r); -extern void of_irq_init(const struct of_device_id *matches); - #ifdef CONFIG_OF_IRQ +extern void of_irq_init(const struct of_device_id *matches); extern int of_irq_parse_one(struct device_node *device, int index, struct of_phandle_args *out_irq); extern int of_irq_count(struct device_node *dev); @@ -57,6 +56,9 @@ extern struct irq_domain *of_msi_map_get_device_domain(struct device *dev, extern void of_msi_configure(struct device *dev, struct device_node *np); u32 of_msi_map_id(struct device *dev, struct device_node *msi_np, u32 id_in); #else +static inline void of_irq_init(const struct of_device_id *matches) +{ +} static inline int of_irq_parse_one(struct device_node *device, int index, struct of_phandle_args *out_irq) {