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 for Android: free password hash cracker in your pocket
[<prev] [next>] [day] [month] [year] [list]
Message-ID: <9a586496-0d62-f246-19ec-d17b6f47e200@infradead.org>
Date:   Mon, 19 Oct 2020 23:02:04 -0700
From:   Randy Dunlap <rdunlap@...radead.org>
To:     LKML <linux-kernel@...r.kernel.org>,
        linux-media <linux-media@...r.kernel.org>,
        Jonathan Corbet <corbet@....net>,
        Mauro Carvalho Chehab <mchehab@...nel.org>
Subject: [PATCH] media/platform/marvell-ccic: fix warnings when CONFIG_PM is
 not enabled

From: Randy Dunlap <rdunlap@...radead.org>

Fix build warnings when CONFIG_PM is not set/enabled:

../drivers/media/platform/marvell-ccic/mmp-driver.c:324:12: warning: 'mmpcam_runtime_suspend' defined but not used [-Wunused-function]
  324 | static int mmpcam_runtime_suspend(struct device *dev)
../drivers/media/platform/marvell-ccic/mmp-driver.c:310:12: warning: 'mmpcam_runtime_resume' defined but not used [-Wunused-function]
  310 | static int mmpcam_runtime_resume(struct device *dev)

Signed-off-by: Randy Dunlap <rdunlap@...radead.org>
Cc: Jonathan Corbet <corbet@....net>
Cc: linux-media@...r.kernel.org
Cc: Mauro Carvalho Chehab <mchehab@...nel.org>
---
 drivers/media/platform/marvell-ccic/mmp-driver.c |    2 ++
 1 file changed, 2 insertions(+)

--- linux-next-20201009.orig/drivers/media/platform/marvell-ccic/mmp-driver.c
+++ linux-next-20201009/drivers/media/platform/marvell-ccic/mmp-driver.c
@@ -307,6 +307,7 @@ static int mmpcam_platform_remove(struct
  * Suspend/resume support.
  */
 
+#ifdef CONFIG_PM
 static int mmpcam_runtime_resume(struct device *dev)
 {
 	struct mmp_camera *cam = dev_get_drvdata(dev);
@@ -352,6 +353,7 @@ static int __maybe_unused mmpcam_resume(
 		return mccic_resume(&cam->mcam);
 	return 0;
 }
+#endif
 
 static const struct dev_pm_ops mmpcam_pm_ops = {
 	SET_RUNTIME_PM_OPS(mmpcam_runtime_suspend, mmpcam_runtime_resume, NULL)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ