lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date:   Thu, 17 Jun 2021 11:51:29 +0800
From:   YueHaibing <yuehaibing@...wei.com>
To:     <ulli.kroll@...glemail.com>, <linus.walleij@...aro.org>,
        <clabbe@...libre.com>, <herbert@...dor.apana.org.au>,
        <davem@...emloft.net>
CC:     <linux-arm-kernel@...ts.infradead.org>,
        <linux-crypto@...r.kernel.org>, <linux-kernel@...r.kernel.org>,
        YueHaibing <yuehaibing@...wei.com>
Subject: [PATCH -next] crypto: sl3516 - Fix build warning without CONFIG_PM

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@...wei.com>
---
 drivers/crypto/gemini/sl3516-ce-core.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/crypto/gemini/sl3516-ce-core.c b/drivers/crypto/gemini/sl3516-ce-core.c
index da6cd529a6c0..00bfc5e19818 100644
--- a/drivers/crypto/gemini/sl3516-ce-core.c
+++ b/drivers/crypto/gemini/sl3516-ce-core.c
@@ -320,6 +320,7 @@ static void sl3516_ce_unregister_algs(struct sl3516_ce_dev *ce)
 	}
 }
 
+#ifdef CONFIG_PM
 static void sl3516_ce_start(struct sl3516_ce_dev *ce)
 {
 	ce->ctx = 0;
@@ -365,6 +366,7 @@ static int sl3516_ce_pm_resume(struct device *dev)
 	sl3516_ce_pm_suspend(dev);
 	return err;
 }
+#endif
 
 static const struct dev_pm_ops sl3516_ce_pm_ops = {
 	SET_RUNTIME_PM_OPS(sl3516_ce_pm_suspend, sl3516_ce_pm_resume, NULL)
-- 
2.17.1

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ