Commit 6da80863 authored by Jérémy Lefaure's avatar Jérémy Lefaure Committed by Greg Kroah-Hartman

staging: greybus: arche-apb-ctrl: fix unused warnings on resume/suspend

When CONFIG_PM_SLEEP is disabled, SIMPLE_DEV_PM_OPS does not use
arche_apb_ctrl_resume and arche_apb_ctrl_suspend functions:

drivers/staging/greybus/arche-apb-ctrl.c:478:12: warning:
‘arche_apb_ctrl_resume’ defined but not used [-Wunused-function]
 static int arche_apb_ctrl_resume(struct device *dev)
            ^~~~~~~~~~~~~~~~~~~~~
drivers/staging/greybus/arche-apb-ctrl.c:464:12: warning:
‘arche_apb_ctrl_suspend’ defined but not used [-Wunused-function]
 static int arche_apb_ctrl_suspend(struct device *dev)
            ^~~~~~~~~~~~~~~~~~~~~~

Adding __maybe_unused to the declaration of these functions removes the
warnings.
Signed-off-by: default avatarJérémy Lefaure <jeremy.lefaure@lse.epita.fr>
Acked-by: default avatarJohan Hovold <johan@kernel.org>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent f05a88a3
......@@ -461,7 +461,7 @@ static int arche_apb_ctrl_remove(struct platform_device *pdev)
return 0;
}
static int arche_apb_ctrl_suspend(struct device *dev)
static int __maybe_unused arche_apb_ctrl_suspend(struct device *dev)
{
/*
* If timing profile permits, we may shutdown bridge
......@@ -475,7 +475,7 @@ static int arche_apb_ctrl_suspend(struct device *dev)
return 0;
}
static int arche_apb_ctrl_resume(struct device *dev)
static int __maybe_unused arche_apb_ctrl_resume(struct device *dev)
{
/*
* Atleast for ES2 we have to meet the delay requirement between
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment