Message ID | 20230311111238.251000-1-krzysztof.kozlowski@linaro.org |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:5915:0:0:0:0:0 with SMTP id v21csp232848wrd; Sat, 11 Mar 2023 03:17:34 -0800 (PST) X-Google-Smtp-Source: AK7set/rhIfGexXQRCb7UCi3ogelXi8dguU5m/AkyIsuCfAyZbhmF4Sz64fWM6Vtow1pGWdTQRvf X-Received: by 2002:a62:63c4:0:b0:5a8:4861:af7d with SMTP id x187-20020a6263c4000000b005a84861af7dmr24127861pfb.20.1678533454513; Sat, 11 Mar 2023 03:17:34 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1678533454; cv=none; d=google.com; s=arc-20160816; b=QornOT+TOaTurr+cu8ofX2GlATEm4Nabt6eRrJBZO3UhcPHoQgW8i0AkiQdg5hei6O PnB+WEScp/fLf44/AqNiQbl707KTC0EPYDdfVjt1DsmiCyaPcTP3bAPizC/yVBQhKSWl NFR9JrJyUCfZVGtA/cKs8aYuFGU96bEBWZwokDl48lzNW5o2etVEGwAN4AO16GPaj9kz ZPhAow8xejhXW3Uq2ESg6Q9JY6rakyKXfslN05Nh7rpb0LtlpOoft6kRqHUPavOWF+cW yNrby+uNH3gVs+bvx372JJ0Msfod9/TVn32lhoFcPb69mUHybTgE5mtPM0ijcAsyF16G qFlQ== 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=OtoSadEYa8Ss/aLG2RB4W5+eHjvVyH51L/bxtSrvPMA=; b=a+bSIa4Ooz2IT8g6lYf5ehqhgjIQsS/9ZxDGw+ywWsxQh+AwBf64xemVIqIhcPe8Lw 878Snyg6AxdaSI/kMWpLfwk7Qh3UmvCkw9pMj30MVUbDoUY1F36mAqY0WnqGL6zD83xX lqxuQnQKuXChNRfJtG3WcOxsRTXkkfeBLXmad7KDWoDwsATXohkEdBtn957FGqv/1zBy GGgGTrrDZvq2/vMOqfU2NUTkz5cGaUaTClmLRcUydqDFEojTjqTMpPK7pvQNksVYIyR1 hqwoOfcNYFVZ1AB4XQd5kIiIXi5nW7TqHl26XGG9WJaEQyspsqxmaSfcLrLYHpoybemP dBcg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="Nuwpg9/E"; 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=linaro.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id y206-20020a6264d7000000b005a8b2a0385bsi1800586pfb.241.2023.03.11.03.17.19; Sat, 11 Mar 2023 03:17:34 -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=@linaro.org header.s=google header.b="Nuwpg9/E"; 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=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229668AbjCKLMt (ORCPT <rfc822;carlos.wei.hk@gmail.com> + 99 others); Sat, 11 Mar 2023 06:12:49 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42736 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229666AbjCKLMr (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Sat, 11 Mar 2023 06:12:47 -0500 Received: from mail-ed1-x531.google.com (mail-ed1-x531.google.com [IPv6:2a00:1450:4864:20::531]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5CB47138443 for <linux-kernel@vger.kernel.org>; Sat, 11 Mar 2023 03:12:42 -0800 (PST) Received: by mail-ed1-x531.google.com with SMTP id j11so30723634edq.4 for <linux-kernel@vger.kernel.org>; Sat, 11 Mar 2023 03:12:42 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1678533161; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=OtoSadEYa8Ss/aLG2RB4W5+eHjvVyH51L/bxtSrvPMA=; b=Nuwpg9/ECvGlnZViVbgeVL56DNY24+RGeMn76jRHFMkBgxNCWgtU1mkNx+kP2kSD2F bsVkGDEyG/e/e4kFaB4ukrBLKSquN3fGXh5Sb7E64ED8miiw99LeYeRhBlZvg6QofQm9 qKhoiyPLDgP7E2YhPV4YJ3gRplSJViLvnEfFMZ2klmykaYqsbLi5a0MYk3o8MefX0ed3 mBFaa6dybsxiLvuMKcm4vQ5WXr45KQaK39WazXdxnEFDVFkNx4uuq5VhK7Zj8xQcm4KG XUsw0SyosEFOdw2W817tmi8fvGCf9WC7SWlHz5QOAIKanfl6AJRCHp4pk+8k3n6t56yn k0Bg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1678533161; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=OtoSadEYa8Ss/aLG2RB4W5+eHjvVyH51L/bxtSrvPMA=; b=DhnHQz1xdzEMsbWXXREyk3lJjkhgUBMFPb/gGY5+o6fNJ0cfKOra971qiLEvi2QO0Z gSkZNeUc4oBQoZYmLewLbWrHyDkz3xAFwMczyGja4LStApp4NAoayGRMohCmE0pLB/3I 2slh7zw6c8Hdu6qa4gv/Yfir2YfoXYnODaAC2U6illZ6bwWfCNf9rsr8WVPPX1lzdI2x eok9vAasYdveREPyjhHET6f1gi4R0ikaFNoAr6BHczALvFCfQ2onUeOVuiG4ciJdaH3N 6oOnAQvrUFLf1X9qkXkPe3hmHQRbjcr7dRiFnOXlGoo3dAasf5jzDTpYXqMxWUi9PM39 ICvw== X-Gm-Message-State: AO0yUKWhF7gOgXahnUoxHzugk5cd9Bzog1pMnzkN+24B0RPlEJk/6u2q 0N0VI6F4vjaWTKHGwJpPaS6NNw== X-Received: by 2002:a05:6402:1854:b0:4ac:b614:dd00 with SMTP id v20-20020a056402185400b004acb614dd00mr23528925edy.30.1678533160796; Sat, 11 Mar 2023 03:12:40 -0800 (PST) Received: from krzk-bin.. ([2a02:810d:15c0:828:fa97:2d7c:bdd7:e1b]) by smtp.gmail.com with ESMTPSA id a70-20020a509ecc000000b004c09f0ba24dsm1043803edf.48.2023.03.11.03.12.40 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 11 Mar 2023 03:12:40 -0800 (PST) From: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> To: Adrian Hunter <adrian.hunter@intel.com>, Ulf Hansson <ulf.hansson@linaro.org>, linux-mmc@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> Subject: [PATCH] mmc: sdhci: add static to !OF stub Date: Sat, 11 Mar 2023 12:12:38 +0100 Message-Id: <20230311111238.251000-1-krzysztof.kozlowski@linaro.org> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED 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: <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?1760069895707067215?= X-GMAIL-MSGID: =?utf-8?q?1760069895707067215?= |
Series |
mmc: sdhci: add static to !OF stub
|
|
Commit Message
Krzysztof Kozlowski
March 11, 2023, 11:12 a.m. UTC
The sdhci_get_compatibility() is not used outside of the unit:
drivers/mmc/host/sdhci-pltfm.c:76:6: error: no previous prototype for ‘sdhci_get_compatibility’ [-Werror=missing-prototypes]
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
drivers/mmc/host/sdhci-pltfm.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
Comments
On Sat, 11 Mar 2023 at 12:12, Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> wrote: > > The sdhci_get_compatibility() is not used outside of the unit: > > drivers/mmc/host/sdhci-pltfm.c:76:6: error: no previous prototype for ‘sdhci_get_compatibility’ [-Werror=missing-prototypes] > > Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> > --- > drivers/mmc/host/sdhci-pltfm.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/mmc/host/sdhci-pltfm.c b/drivers/mmc/host/sdhci-pltfm.c > index 328b132bbe57..245e56324dff 100644 > --- a/drivers/mmc/host/sdhci-pltfm.c > +++ b/drivers/mmc/host/sdhci-pltfm.c > @@ -73,7 +73,7 @@ static void sdhci_get_compatibility(struct platform_device *pdev) > host->quirks |= SDHCI_QUIRK_BROKEN_TIMEOUT_VAL; > } > #else > -void sdhci_get_compatibility(struct platform_device *pdev) {} > +static void sdhci_get_compatibility(struct platform_device *pdev) {} > #endif /* CONFIG_OF */ sdhci_get_compatibility() is using OF functions with stubs for !OF. Perhaps a cleaner option is to drop the #ifdef CONFIG_OF completely around sdhci_get_compatibility(), thus we can drop the stub too. > > void sdhci_get_property(struct platform_device *pdev) > -- > 2.34.1 > Kind regards Uffe
On 13/03/2023 13:49, Ulf Hansson wrote: > On Sat, 11 Mar 2023 at 12:12, Krzysztof Kozlowski > <krzysztof.kozlowski@linaro.org> wrote: >> >> The sdhci_get_compatibility() is not used outside of the unit: >> >> drivers/mmc/host/sdhci-pltfm.c:76:6: error: no previous prototype for ‘sdhci_get_compatibility’ [-Werror=missing-prototypes] >> >> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> >> --- >> drivers/mmc/host/sdhci-pltfm.c | 2 +- >> 1 file changed, 1 insertion(+), 1 deletion(-) >> >> diff --git a/drivers/mmc/host/sdhci-pltfm.c b/drivers/mmc/host/sdhci-pltfm.c >> index 328b132bbe57..245e56324dff 100644 >> --- a/drivers/mmc/host/sdhci-pltfm.c >> +++ b/drivers/mmc/host/sdhci-pltfm.c >> @@ -73,7 +73,7 @@ static void sdhci_get_compatibility(struct platform_device *pdev) >> host->quirks |= SDHCI_QUIRK_BROKEN_TIMEOUT_VAL; >> } >> #else >> -void sdhci_get_compatibility(struct platform_device *pdev) {} >> +static void sdhci_get_compatibility(struct platform_device *pdev) {} >> #endif /* CONFIG_OF */ > > sdhci_get_compatibility() is using OF functions with stubs for !OF. > > Perhaps a cleaner option is to drop the #ifdef CONFIG_OF completely > around sdhci_get_compatibility(), thus we can drop the stub too. Works, indeed, better idea. I'll send v2. Best regards, Krzysztof
diff --git a/drivers/mmc/host/sdhci-pltfm.c b/drivers/mmc/host/sdhci-pltfm.c index 328b132bbe57..245e56324dff 100644 --- a/drivers/mmc/host/sdhci-pltfm.c +++ b/drivers/mmc/host/sdhci-pltfm.c @@ -73,7 +73,7 @@ static void sdhci_get_compatibility(struct platform_device *pdev) host->quirks |= SDHCI_QUIRK_BROKEN_TIMEOUT_VAL; } #else -void sdhci_get_compatibility(struct platform_device *pdev) {} +static void sdhci_get_compatibility(struct platform_device *pdev) {} #endif /* CONFIG_OF */ void sdhci_get_property(struct platform_device *pdev)