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: 33755 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:e747:0:0:0:0:0 with SMTP id c7csp484303wrn; Thu, 15 Dec 2022 09:05:30 -0800 (PST) X-Google-Smtp-Source: AA0mqf5/f1VwCc09GZCysBqJ9Vq0gou15MtveCThDFUQqcz/GsnPR+5BUhoyFZCLMdi71UmBgVEk X-Received: by 2002:a17:906:3811:b0:7c0:bd9a:a4ef with SMTP id v17-20020a170906381100b007c0bd9aa4efmr22521498ejc.39.1671123930745; Thu, 15 Dec 2022 09:05:30 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1671123930; cv=none; d=google.com; s=arc-20160816; b=bJzcBYcOFGeX3B1wsfCQix+I0R5845PMhGpb2HoBIN7btY8ArjX96xTAvkN01olnqU 2zqYB72dQGqWQuUMJNOrQP/LXNAeSOW5fX+7Bd6qde11hluA2VVHtn3KAs3d4H63B+Mq zjy8U207Mqd9klYb2OA+rFByerVp9/p2Ybe1Fz8n4/mpgh8nmFdSDvYZpizm+JY0zrHw 7NgdRNKw6bpZQVlNf8RZLhUSb1bAW8RA+z3sjfC54dexqzHiW96USOh/1yXfDRUTJv5t TNpRsClySbuT9RM6fWPBcKkBQ25GNJh2y1RmgFWtQuVTE25FpVdTPaNNllXK3y0IkpTx QLUw== 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 :message-id:date:subject:cc:to:from:dkim-signature; bh=6L5YRRv9IpOELbfocp+GWThzrROTKRKDAxqV0JpX23k=; b=C7uefFgbtotwS8j/VbOh2SLNrmrFSKlvdpi1mFxAA6zpxdvWQAB7sPjyUtzfE/9eOy //eZluPe4+noCpwVfDtLUMmMTfSZD4Ibl0QwfeXWFzRdl2LnEx5hLhNDry3PYfA1226u pcaBR1KpEjmUNDotFZLEyoFFTSo3JaGhfsiZlyNmeF8RPsY83p4ogIhHMV8McJ4mSqO8 +Fxu+t8EIBob5xrEkCFP8xVY00itdxJhik373Rw+Tqr88oB1jLXPx11nvdp7hVylxCsC NYx0HBKqHLVy3bO3MizEfmTFDedinjl6C/E6wWvE4U7cuCSI1QZaGSyP5Wan6mD4Zo24 BalA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=l0tpiBK+; 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=NONE dis=NONE) header.from=kernel.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id hd15-20020a170907968f00b007b2a6aaff06si16875606ejc.50.2022.12.15.09.05.07; Thu, 15 Dec 2022 09:05:30 -0800 (PST) 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=@kernel.org header.s=k20201202 header.b=l0tpiBK+; 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=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230505AbiLORCz (ORCPT + 99 others); Thu, 15 Dec 2022 12:02:55 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52294 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231176AbiLORCN (ORCPT ); Thu, 15 Dec 2022 12:02:13 -0500 Received: from sin.source.kernel.org (sin.source.kernel.org [IPv6:2604:1380:40e1:4800::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4667622280 for ; Thu, 15 Dec 2022 09:02:11 -0800 (PST) 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 sin.source.kernel.org (Postfix) with ESMTPS id 24F64CE1BC0 for ; Thu, 15 Dec 2022 17:02:10 +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-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, 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 X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1752300446834664823?= X-GMAIL-MSGID: =?utf-8?q?1752300446834664823?= 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)