android_kernel_oneplus_msm8998/drivers/net/wireless/cw1200
Arnd Bergmann d3843789e7 wireless: cw1200: use __maybe_unused to hide pm functions_
commit 836856e3bd61d0644e5178a2c1b51d90459e2788 upstream.

The cw1200 uses #ifdef to check for CONFIG_PM, but then
uses SIMPLE_DEV_PM_OPS, which leaves the references out when
CONFIG_PM_SLEEP is not defined, so we get a warning with
PM=y && PM_SLEEP=n:

drivers/net/wireless/st/cw1200/cw1200_spi.c:450:12: error: 'cw1200_spi_suspend' defined but not used [-Werror=unused-function]

This removes the incorrect #ifdef and instead uses a __maybe_unused
annotation to let the compiler know it can silently drop
the function definition.

For the DEV_PM_OPS definition, we can use an IS_ENABLED() check
to avoid defining the structure when CONFIG_PM is not set without
the #ifdef.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-02-25 11:03:50 +01:00
..
bh.c cw1200: When debug is enabled, display all wakeup conditions for the wait_event_interruptible_timeout() call. 2013-08-28 13:58:29 -04:00
bh.h
cw1200.h cw1200: Fix up a large pile of sparse warnings 2013-06-24 14:44:24 -04:00
cw1200_sdio.c wireless: cw1200: Use consistent internal locking conventions 2013-12-05 14:54:47 -05:00
cw1200_spi.c wireless: cw1200: use __maybe_unused to hide pm functions_ 2018-02-25 11:03:50 +01:00
debug.c cw1200: Fix cw1200_debug_link_id 2014-04-14 14:31:42 -04:00
debug.h
fwio.c cw1200: Less function calls in cw1200_load_firmware_cw1200() after error detection 2015-02-06 08:48:04 +02:00
fwio.h
hwbus.h Revert "cw1200: Don't perform SPI transfers in interrupt context" 2013-09-26 14:02:31 -04:00
hwio.c Revert "cw1200: Don't perform SPI transfers in interrupt context" 2013-09-26 14:02:31 -04:00
hwio.h cw1200: Fix up a large pile of sparse warnings 2013-06-24 14:44:24 -04:00
Kconfig
main.c mac80211: convert HW flags to unsigned long bitmap 2015-06-10 16:05:36 +02:00
Makefile
pm.c wireless: cw1200: Use setup_timer 2015-01-07 10:44:59 +02:00
pm.h wireless: cw1200: use __maybe_unused to hide pm functions_ 2018-02-25 11:03:50 +01:00
queue.c cw1200: queue: Use setup_timer 2015-01-07 10:45:04 +02:00
queue.h
scan.c cw1200: use msecs_to_jiffies for conversion 2015-02-06 08:43:29 +02:00
scan.h mac80211: support more than one band in scan request 2014-06-25 09:10:42 +02:00
sta.c mac80211: pass block ack session timeout to to driver 2017-05-20 14:27:03 +02:00
sta.h mac80211: pass block ack session timeout to to driver 2017-05-20 14:27:03 +02:00
txrx.c wireless: Use eth_<foo>_addr instead of memset 2015-03-03 17:01:36 -05:00
txrx.h
wsm.c cw1200: fix bogus maybe-uninitialized warning 2018-02-25 11:03:50 +01:00
wsm.h cw1200: Fix incorrect endianness annotation in a header field 2013-07-22 16:54:44 -04:00