From: Jin Xiaoyun <jinxiaoyun2@huawei.com>
To: <matthias.bgg@gmail.com>,
<angelogioacchino.delregno@collabora.com>, <khilman@baylibre.com>,
<zhengbin13@huawei.com>, <gaochao49@huawei.com>
Cc: <linux-arm-kernel@lists.infradead.org>,
<linux-mediatek@lists.infradead.org>,
<linux-kernel@vger.kernel.org>,
"Jin Xiaoyun" <jinxiaoyun2@huawei.com>
Subject: [PATCH -next] soc: mediatek: SVS: Make svs_resume and svs_suspend defined when CONFIG_PM_SLEEP is y
Date: Wed, 22 Jun 2022 09:34:10 +0800 [thread overview]
Message-ID: <20220622013410.2786760-1-jinxiaoyun2@huawei.com> (raw)
The svs_resume and svs_suspend is defined through SIMPLE_DEV_PM_OPS. If CONFIG_PM_SLEEP
is not defined, SIMPLE_DEV_PM_OPS is equivalent to an empty function. In this case,
the defination of svs_resume and svs_suspend is meaningless.
Fix build error:
drivers/soc/mediatek/mtk-svs.c:1515:12: error: ‘svs_resume’ defined but not used [-Werror=unused-function]
drivers/soc/mediatek/mtk-svs.c:1481:12: error: ‘svs_suspend’ defined but not used [-Werror=unused-function]
Signed-off-by: Jin Xiaoyun <jinxiaoyun2@huawei.com>
---
drivers/soc/mediatek/mtk-svs.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/soc/mediatek/mtk-svs.c b/drivers/soc/mediatek/mtk-svs.c
index 606a00a2e57d..8440058784dc 100644
--- a/drivers/soc/mediatek/mtk-svs.c
+++ b/drivers/soc/mediatek/mtk-svs.c
@@ -1478,6 +1478,7 @@ static int svs_start(struct svs_platform *svsp)
return 0;
}
+#ifdef CONFIG_PM_SLEEP
static int svs_suspend(struct device *dev)
{
struct svs_platform *svsp = dev_get_drvdata(dev);
@@ -1537,6 +1538,7 @@ static int svs_resume(struct device *dev)
return 0;
}
+#endif
static int svs_bank_resource_setup(struct svs_platform *svsp)
{
--
2.25.1
next reply other threads:[~2022-06-22 1:17 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-06-22 1:34 Jin Xiaoyun [this message]
2022-06-22 13:55 ` [PATCH -next] soc: mediatek: SVS: Make svs_resume and svs_suspend defined when CONFIG_PM_SLEEP is y Matthias Brugger
2022-06-23 3:09 ` [PATCH v2 -next] soc: mediatek: SVS: Use the new PM macros Jin Xiaoyun
2022-06-23 11:59 ` Matthias Brugger
2022-06-23 12:03 ` Matthias Brugger
2022-07-07 8:26 ` Matthias Brugger
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20220622013410.2786760-1-jinxiaoyun2@huawei.com \
--to=jinxiaoyun2@huawei.com \
--cc=angelogioacchino.delregno@collabora.com \
--cc=gaochao49@huawei.com \
--cc=khilman@baylibre.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mediatek@lists.infradead.org \
--cc=matthias.bgg@gmail.com \
--cc=zhengbin13@huawei.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox