提交 b7e50635 编写于 作者: A Arnd Bergmann 提交者: Mauro Carvalho Chehab

[media] atmel-isc: mark PM functions as __maybe_unused

The newly added atmel-isc driver uses SET_RUNTIME_PM_OPS() to
refer to its suspend/resume functions, causing a warning when
CONFIG_PM is not set:

media/platform/atmel/atmel-isc.c:1477:12: error: 'isc_runtime_resume' defined but not used [-Werror=unused-function]
media/platform/atmel/atmel-isc.c:1467:12: error: 'isc_runtime_suspend' defined but not used [-Werror=unused-function]

This adds __maybe_unused annotations to avoid the warning without
adding an error-prone #ifdef around it.
Signed-off-by: NArnd Bergmann <arnd@arndb.de>
Signed-off-by: NHans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: NMauro Carvalho Chehab <mchehab@s-opensource.com>
上级 37f0644f
......@@ -1470,7 +1470,7 @@ static int atmel_isc_remove(struct platform_device *pdev)
return 0;
}
static int isc_runtime_suspend(struct device *dev)
static int __maybe_unused isc_runtime_suspend(struct device *dev)
{
struct isc_device *isc = dev_get_drvdata(dev);
......@@ -1480,7 +1480,7 @@ static int isc_runtime_suspend(struct device *dev)
return 0;
}
static int isc_runtime_resume(struct device *dev)
static int __maybe_unused isc_runtime_resume(struct device *dev)
{
struct isc_device *isc = dev_get_drvdata(dev);
int ret;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册