From patchwork Wed Aug 16 11:33:26 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Geert Uytterhoeven X-Patchwork-Id: 13355077 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 428B6C001B0 for ; Wed, 16 Aug 2023 11:34:12 +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=cwIkho1ZWKL5wm95woaQ29gMs31jZQedoyTOjVUFgCI=; b=BQ8qUUB5IO8vxI 2jAwY1/cl+o2oYD/m+5WDcEHEvK3H3fiHDHoXJg82PEeOzJ7Lzs2RgnsQUNNpqmdAQjx4BDDWPsvM DZ1ANAkW/jPhoS7aHmXpBZu31hVd8tWelE+jo+15lWuUzxWnz6lShMrZfo2bAPPzzQEGGcyA2nG4t kLVmd4EPfRG7SDljtV5A9kqWM8VlTIHfVFsby32pTySMj6yOEtdwhiXYl8YOA9OLDG/X1KyrEj5yi FyavZfcHhUvWIxxFE/qDUagEVVy4ge9+FACxKiKfGa1WC5xRkLAf44l6vJj7riFJ/nCnKxVyV/jNR K+oTaxufZISiVnaq8LlA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1qWEmU-003zY7-35; Wed, 16 Aug 2023 11:33:42 +0000 Received: from xavier.telenet-ops.be ([2a02:1800:120:4::f00:14]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1qWEmS-003zX7-0u for linux-arm-kernel@lists.infradead.org; Wed, 16 Aug 2023 11:33:42 +0000 Received: from ramsan.of.borg ([IPv6:2a02:1810:ac12:ed40:5d0c:f209:12a7:4ce5]) by xavier.telenet-ops.be with bizsmtp id aBZT2A00445ualL01BZTFl; Wed, 16 Aug 2023 13:33:28 +0200 Received: from rox.of.borg ([192.168.97.57]) by ramsan.of.borg with esmtp (Exim 4.95) (envelope-from ) id 1qWEm8-000p1Y-GO; Wed, 16 Aug 2023 13:33:26 +0200 Received: from geert by rox.of.borg with local (Exim 4.95) (envelope-from ) id 1qWEmE-006A0c-RE; Wed, 16 Aug 2023 13:33:26 +0200 From: Geert Uytterhoeven To: Alessandro Zummo , Alexandre Belloni , Maxime Coquelin , Alexandre Torgue , Arnd Bergmann , Valentin Caron Cc: linux-rtc@vger.kernel.org, linux-stm32@st-md-mailman.stormreply.com, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, Geert Uytterhoeven Subject: [PATCH] rtc: stm32: Use NOIRQ_SYSTEM_SLEEP_PM_OPS() Date: Wed, 16 Aug 2023 13:33:26 +0200 Message-Id: <20230816113326.1468435-1-geert@linux-m68k.org> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230816_043340_478245_67D5220D X-CRM114-Status: GOOD ( 14.23 ) 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 If CONFIG_PM_SLEEP=n (e.g. m68k/allmodconfig): drivers/rtc/rtc-stm32.c:904:12: error: ‘stm32_rtc_resume’ defined but not used [-Werror=unused-function] 904 | static int stm32_rtc_resume(struct device *dev) | ^~~~~~~~~~~~~~~~ drivers/rtc/rtc-stm32.c:894:12: error: ‘stm32_rtc_suspend’ defined but not used [-Werror=unused-function] 894 | static int stm32_rtc_suspend(struct device *dev) | ^~~~~~~~~~~~~~~~~ Indeed, the previous change mixed up the semantics between SET_NOIRQ_SYSTEM_SLEEP_PM_OPS() and NOIRQ_SYSTEM_SLEEP_PM_OPS(). Fix this by using the modern NOIRQ_SYSTEM_SLEEP_PM_OPS() instead. Reported-by: noreply@ellerman.id.au Fixes: a69c610e13e2b2de ("rtc: stm32: remove incorrect #ifdef check") Signed-off-by: Geert Uytterhoeven Reviewed-by: Arnd Bergmann --- drivers/rtc/rtc-stm32.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/rtc/rtc-stm32.c b/drivers/rtc/rtc-stm32.c index 3ce4b3d08155b48d..76753c71d92eef3e 100644 --- a/drivers/rtc/rtc-stm32.c +++ b/drivers/rtc/rtc-stm32.c @@ -923,7 +923,7 @@ static int stm32_rtc_resume(struct device *dev) } static const struct dev_pm_ops stm32_rtc_pm_ops = { - SET_NOIRQ_SYSTEM_SLEEP_PM_OPS(stm32_rtc_suspend, stm32_rtc_resume) + NOIRQ_SYSTEM_SLEEP_PM_OPS(stm32_rtc_suspend, stm32_rtc_resume) }; static struct platform_driver stm32_rtc_driver = {