提交 a234442c 编写于 作者: B Brian Norris 提交者: Ulf Hansson

mmc: sdhci-brcmstb: Resolve "unused" warnings with CONFIG_OF=n

With W=1, we can see this gcc warning:

drivers/mmc/host/sdhci-brcmstb.c:182:34: warning: ‘sdhci_brcm_of_match’ defined but not used [-Wunused-const-variable=]
  182 | static const struct of_device_id sdhci_brcm_of_match[] = {
      |                                  ^~~~~~~~~~~~~~~~~~~

Rather than play around more with #ifdef's, the simplest solution is to
just mark this __maybe_unused.

Fixes: 50bfe185 ("mmc: sdhci-brcmstb: Allow building with COMPILE_TEST")
Reported-by: Nkernel test robot <lkp@intel.com>
Link: https://lore.kernel.org/all/202212060700.NjMecjxS-lkp@intel.com/Signed-off-by: NBrian Norris <briannorris@chromium.org>
Acked-by: NFlorian Fainelli <f.fainelli@gmail.com>
Link: https://lore.kernel.org/r/20221205160353.1.I5fa28f1045f17fb9285d507accf139f8b2a8f4b5@changeidSigned-off-by: NUlf Hansson <ulf.hansson@linaro.org>
上级 491ad767
......@@ -179,7 +179,7 @@ static const struct brcmstb_match_priv match_priv_7216 = {
.ops = &sdhci_brcmstb_ops_7216,
};
static const struct of_device_id sdhci_brcm_of_match[] = {
static const struct of_device_id __maybe_unused sdhci_brcm_of_match[] = {
{ .compatible = "brcm,bcm7425-sdhci", .data = &match_priv_7425 },
{ .compatible = "brcm,bcm7445-sdhci", .data = &match_priv_7445 },
{ .compatible = "brcm,bcm7216-sdhci", .data = &match_priv_7216 },
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册