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: <20210913140937.1490133-1-hello@bryanbrattlof.com>
Date:   Mon, 13 Sep 2021 14:10:12 +0000
From:   Bryan Brattlof <hello@...anbrattlof.com>
To:     Greg Kroah-Hartman <gregkh@...uxfoundation.org>
Cc:     linux-staging@...ts.linux.dev, linux-kernel@...r.kernel.org,
        Bryan Brattlof <hello@...anbrattlof.com>
Subject: [PATCH] staging: rtl8723bs: define wowlan_stub only when CONFIG_PM is enabled

The wake-on-lan stub is needed only when the device power management
functionality is enabled in the kernel. Conditionally define
wowlan_stub to avoid potential unused object warnings.

Signed-off-by: Bryan Brattlof <hello@...anbrattlof.com>
---
 drivers/staging/rtl8723bs/os_dep/ioctl_cfg80211.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/staging/rtl8723bs/os_dep/ioctl_cfg80211.c b/drivers/staging/rtl8723bs/os_dep/ioctl_cfg80211.c
index 34da8a569709..f4a9b4b7c97e 100644
--- a/drivers/staging/rtl8723bs/os_dep/ioctl_cfg80211.c
+++ b/drivers/staging/rtl8723bs/os_dep/ioctl_cfg80211.c
@@ -47,6 +47,7 @@ static const u32 rtw_cipher_suites[] = {
  * Moreover wowlan has to be enabled via a the nl80211_set_wowlan callback.
  * (from user space, e.g. iw phy0 wowlan enable)
  */
+#if defined(CONFIG_PM)
 static const struct wiphy_wowlan_support wowlan_stub = {
 	.flags = WIPHY_WOWLAN_ANY,
 	.n_patterns = 0,
@@ -54,6 +55,7 @@ static const struct wiphy_wowlan_support wowlan_stub = {
 	.pattern_min_len = 0,
 	.max_pkt_offset = 0,
 };
+#endif

 static struct ieee80211_rate rtw_rates[] = {
 	RATETAB_ENT(10,  0x1,   0),
--
2.30.2


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ