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]
Message-Id: <20171013092554.531186-1-arnd@arndb.de>
Date:   Fri, 13 Oct 2017 11:25:32 +0200
From:   Arnd Bergmann <arnd@...db.de>
To:     Tony Lindgren <tony@...mide.com>
Cc:     Arnd Bergmann <arnd@...db.de>, linux-kernel@...r.kernel.org
Subject: [PATCH] bus: ti-sysc: mark PM functions as __maybe_unused

The new bus driver causes a harmless compile-time warning when
CONFIG_PM is disabled:

drivers/bus/ti-sysc.c:440:12: error: 'sysc_runtime_resume' defined but not used [-Werror=unused-function]
 static int sysc_runtime_resume(struct device *dev)
            ^~~~~~~~~~~~~~~~~~~
drivers/bus/ti-sysc.c:421:12: error: 'sysc_runtime_suspend' defined but not used [-Werror=unused-function]
 static int sysc_runtime_suspend(struct device *dev)
            ^~~~~~~~~~~~~~~~~~~~

This marks the two unused functions as __maybe_unused to shut up
that warning.

Fixes: 0eecc636e5a2 ("bus: ti-sysc: Add minimal TI sysc interconnect target driver")
Signed-off-by: Arnd Bergmann <arnd@...db.de>
---
 drivers/bus/ti-sysc.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/bus/ti-sysc.c b/drivers/bus/ti-sysc.c
index 9b3cb278ce41..8b95d0f0c319 100644
--- a/drivers/bus/ti-sysc.c
+++ b/drivers/bus/ti-sysc.c
@@ -418,7 +418,7 @@ static void sysc_show_registers(struct sysc *ddata)
 		buf);
 }
 
-static int sysc_runtime_suspend(struct device *dev)
+static int __maybe_unused sysc_runtime_suspend(struct device *dev)
 {
 	struct sysc *ddata;
 	int i;
@@ -437,7 +437,7 @@ static int sysc_runtime_suspend(struct device *dev)
 	return 0;
 }
 
-static int sysc_runtime_resume(struct device *dev)
+static int __maybe_unused sysc_runtime_resume(struct device *dev)
 {
 	struct sysc *ddata;
 	int i, error;
-- 
2.9.0

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ