From patchwork Thu Dec 15 17:01:57 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 13074372 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 053BCC4332F for ; Thu, 15 Dec 2022 17:03:17 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-Id:Date:Subject:Cc :To:From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=t+mnCq5Rd4OgQsNSu4+VPxjDYYOOHvYe2TWV3Zag5k8=; b=dhh/aNPEmY7Gsj CFHPhYJF4ke8uHYpUW5hOzJGXMWY0YFyCQUzTIF4LXwr5XrhJNLlNHRrJAA7k5yDe12t5iqkNFzyI 7EvYvJCDg95vgu9NkZjo3rfNHwWWWeOZkEW7JVjQKHq7fm8GyLk4gR2I63sba/28xYTwj86OShzAr MO5R73tuTT2KJOmCaguox5EX0WYZIAbUFhBdLk1tM0XH6stRi2hZypvMfA1/mMaluwx5bIj/85jS3 YccmM6W6ism6VDoxHkJRJEdqzHmzcqMYTH1e6YQ7+BNVoS/DMOd/d6Xk146V5vo2/mcTYGdgSBdSz zLZ8poTMZweqq9BV6Ciw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1p5rcc-00ASBS-8Y; Thu, 15 Dec 2022 17:02:14 +0000 Received: from dfw.source.kernel.org ([2604:1380:4641:c500::1]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1p5rcX-00AS9L-OC for linux-arm-kernel@lists.infradead.org; Thu, 15 Dec 2022 17:02:10 +0000 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id C80DA61DE1; Thu, 15 Dec 2022 17:02:08 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 0B7EDC433D2; Thu, 15 Dec 2022 17:02:05 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1671123728; bh=aZPP5Ds69HdaOxy+6a8OrUz2MqCG1aXCDs4UKolW/As=; h=From:To:Cc:Subject:Date:From; b=l0tpiBK+b9s4IrxHju9S2phe8M9Eex7yQTuPXrR+Vv0qVD1fKN3TZCZS4/Zkeof9S 1EuDmyi66XvSafhDdW5J0EVGCpH8l7uhZOkLZ0oP+ne8YT1H860ndqgvNVPk8FAmCB c+mSLLVzxgpjnVuPY16B3q7IfYZkTh6eEEh6fYyw5VjQpdgbutJ+E60WGDWE1KJ/M7 Dhqjb2Xf9Y1p0bbRhKhFnH7NVGzUJBpz7z7lWyfbiaKiW+XgBpcaWbXgaovUcix59C xKT/cnOZ/QNchOpmvKXlql2qSMf8ifx6umv78Uvjzhdcae2FKjrwlw3Fow5EgVWprP MZl/XyyS+ZlzQ== From: Arnd Bergmann To: Andrew Lunn , Gregory Clement , Sebastian Hesselbarth , Thomas Gleixner , Marc Zyngier , Nathan Rossi Cc: Arnd Bergmann , =?utf-8?q?Pali_Roh=C3=A1r?= , linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: [PATCH] irqchip: armada: suppress unused-function warning Date: Thu, 15 Dec 2022 18:01:57 +0100 Message-Id: <20221215170202.2441960-1-arnd@kernel.org> X-Mailer: git-send-email 2.35.1 MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20221215_090209_874147_212DBB7E X-CRM114-Status: GOOD ( 13.34 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org From: Arnd Bergmann armada_370_xp_msi_reenable_percpu is only defined when CONFIG_PCI_MSI is enabled, and only called when SMP is enabled. Without CONFIG_SMP, there are no callers, so we get a build time warning instead: drivers/irqchip/irq-armada-370-xp.c:319:13: error: 'armada_370_xp_msi_reenable_percpu' defined but not used [-Werror=unused-function] 319 | static void armada_370_xp_msi_reenable_percpu(void) {} | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Mark the function as __maybe_unused to avoid adding more complexity to the #ifdefs. Fixes: 8ca61cde32c1 ("irqchip/armada-370-xp: Enable MSI affinity configuration") Signed-off-by: Arnd Bergmann --- drivers/irqchip/irq-armada-370-xp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/irqchip/irq-armada-370-xp.c b/drivers/irqchip/irq-armada-370-xp.c index ee18eb3e72b7..178ff63f8e93 100644 --- a/drivers/irqchip/irq-armada-370-xp.c +++ b/drivers/irqchip/irq-armada-370-xp.c @@ -316,7 +316,7 @@ static int armada_370_xp_msi_init(struct device_node *node, return 0; } #else -static void armada_370_xp_msi_reenable_percpu(void) {} +static __maybe_unused void armada_370_xp_msi_reenable_percpu(void) {} static inline int armada_370_xp_msi_init(struct device_node *node, phys_addr_t main_int_phys_base)