Search Linux Wireless

[PATCH 14/33] wl12xx: pass the wake up condition when configuring the wake up event

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Luciano Coelho <luciano.coelho@xxxxxxxxx>

Changed the function wl12xx_acx_wake_up_conditions() so that it receives an
argument with the actual wake up condition, instead of having
WAKE_UP_EVENT_DTIM_BITMAP hardcoded.  This is needed because we have to use
different conditions in 1271.

Signed-off-by: Luciano Coelho <luciano.coelho@xxxxxxxxx>
Signed-off-by: Kalle Valo <kalle.valo@xxxxxxxxx>
---

 drivers/net/wireless/wl12xx/acx.c |    5 +++--
 drivers/net/wireless/wl12xx/acx.h |    3 ++-
 drivers/net/wireless/wl12xx/cmd.c |    3 ++-
 3 files changed, 7 insertions(+), 4 deletions(-)

diff --git a/drivers/net/wireless/wl12xx/acx.c b/drivers/net/wireless/wl12xx/acx.c
index d0daf69..a6b8945 100644
--- a/drivers/net/wireless/wl12xx/acx.c
+++ b/drivers/net/wireless/wl12xx/acx.c
@@ -96,7 +96,8 @@ out:
 	return ret;
 }
 
-int wl12xx_acx_wake_up_conditions(struct wl12xx *wl, u8 listen_interval)
+int wl12xx_acx_wake_up_conditions(struct wl12xx *wl, u8 wake_up_event,
+				  u8 listen_interval)
 {
 	struct acx_wake_up_condition *wake_up;
 	int ret;
@@ -109,7 +110,7 @@ int wl12xx_acx_wake_up_conditions(struct wl12xx *wl, u8 listen_interval)
 		goto out;
 	}
 
-	wake_up->wake_up_event = WAKE_UP_EVENT_DTIM_BITMAP;
+	wake_up->wake_up_event = wake_up_event;
 	wake_up->listen_interval = listen_interval;
 
 	ret = wl12xx_cmd_configure(wl, ACX_WAKE_UP_CONDITIONS,
diff --git a/drivers/net/wireless/wl12xx/acx.h b/drivers/net/wireless/wl12xx/acx.h
index 549e537..92e7248 100644
--- a/drivers/net/wireless/wl12xx/acx.h
+++ b/drivers/net/wireless/wl12xx/acx.h
@@ -1112,7 +1112,8 @@ int wl12xx_acx_frame_rates(struct wl12xx *wl, u8 ctrl_rate, u8 ctrl_mod,
 			   u8 mgt_rate, u8 mgt_mod);
 int wl12xx_acx_station_id(struct wl12xx *wl);
 int wl12xx_acx_default_key(struct wl12xx *wl, u8 key_id);
-int wl12xx_acx_wake_up_conditions(struct wl12xx *wl, u8 listen_interval);
+int wl12xx_acx_wake_up_conditions(struct wl12xx *wl, u8 wake_up_event,
+				  u8 listen_interval);
 int wl12xx_acx_sleep_auth(struct wl12xx *wl, u8 sleep_auth);
 int wl12xx_acx_fw_version(struct wl12xx *wl, char *buf, size_t len);
 int wl12xx_acx_tx_power(struct wl12xx *wl, int power);
diff --git a/drivers/net/wireless/wl12xx/cmd.c b/drivers/net/wireless/wl12xx/cmd.c
index 0a02cdd..d98941a 100644
--- a/drivers/net/wireless/wl12xx/cmd.c
+++ b/drivers/net/wireless/wl12xx/cmd.c
@@ -346,7 +346,8 @@ int wl12xx_cmd_ps_mode(struct wl12xx *wl, u8 ps_mode)
 	int ret = 0;
 
 	/* FIXME: this should be in ps.c */
-	ret = wl12xx_acx_wake_up_conditions(wl, wl->listen_int);
+	ret = wl12xx_acx_wake_up_conditions(wl, WAKE_UP_EVENT_DTIM_BITMAP,
+					    wl->listen_int);
 	if (ret < 0) {
 		wl12xx_error("couldn't set wake up conditions");
 		goto out;

--
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]
  Powered by Linux