[PATCH -next] crypto: sl3516 - Fix build warning without CONFIG_PM

LABBE Corentin clabbe at baylibre.com
Thu Jun 17 06:00:34 PDT 2021


Le Thu, Jun 17, 2021 at 11:51:29AM +0800, YueHaibing a écrit :
> drivers/crypto/gemini/sl3516-ce-core.c:345:12:
>  warning: ‘sl3516_ce_pm_resume’ defined but not used [-Wunused-function]
>  static int sl3516_ce_pm_resume(struct device *dev)
>             ^~~~~~~~~~~~~~~~~~~
> 
> Use #ifdef macro to guard this.
> 
> Signed-off-by: YueHaibing <yuehaibing at huawei.com>
> ---
>  drivers/crypto/gemini/sl3516-ce-core.c | 2 ++
>  1 file changed, 2 insertions(+)
> 

Hello

Thanks for the report, but I am sorry and need to NAK this patch.

The driver needs PM, without it, clock and resets are never set.
The correct fix is to add "depends on PM".

Regards



More information about the linux-arm-kernel mailing list