aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/mediatek/mtk_star_emac.c
diff options
context:
space:
mode:
authorArnd Bergmann <arnd@arndb.de>2020-05-27 15:34:45 +0200
committerDavid S. Miller <davem@davemloft.net>2020-05-27 11:32:39 -0700
commitf99c0646ef83076dba88255c42482d1b4325f890 (patch)
tree010dddbf7ed770c8218bde3ca182288f53390395 /drivers/net/ethernet/mediatek/mtk_star_emac.c
parentbridge: mrp: Rework the MRP netlink interface (diff)
downloadlinux-dev-f99c0646ef83076dba88255c42482d1b4325f890.tar.xz
linux-dev-f99c0646ef83076dba88255c42482d1b4325f890.zip
mtk-star-emac: mark PM functions as __maybe_unused
Without CONFIG_PM, the compiler warns about two unused functions: drivers/net/ethernet/mediatek/mtk_star_emac.c:1472:12: error: unused function 'mtk_star_suspend' [-Werror,-Wunused-function] drivers/net/ethernet/mediatek/mtk_star_emac.c:1488:12: error: unused function 'mtk_star_resume' [-Werror,-Wunused-function] Mark these as __maybe_unused. Fixes: 8c7bd5a454ff ("net: ethernet: mtk-star-emac: new driver") Signed-off-by: Arnd Bergmann <arnd@arndb.de> Acked-by: Bartosz Golaszewski <bgolaszewski@baylibre.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/mediatek/mtk_star_emac.c')
-rw-r--r--drivers/net/ethernet/mediatek/mtk_star_emac.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/ethernet/mediatek/mtk_star_emac.c b/drivers/net/ethernet/mediatek/mtk_star_emac.c
index 72bb624a6a68..8596ca0e60eb 100644
--- a/drivers/net/ethernet/mediatek/mtk_star_emac.c
+++ b/drivers/net/ethernet/mediatek/mtk_star_emac.c
@@ -1468,7 +1468,7 @@ out_put_node:
return ret;
}
-static int mtk_star_suspend(struct device *dev)
+static __maybe_unused int mtk_star_suspend(struct device *dev)
{
struct mtk_star_priv *priv;
struct net_device *ndev;
@@ -1484,7 +1484,7 @@ static int mtk_star_suspend(struct device *dev)
return 0;
}
-static int mtk_star_resume(struct device *dev)
+static __maybe_unused int mtk_star_resume(struct device *dev)
{
struct mtk_star_priv *priv;
struct net_device *ndev;