summaryrefslogtreecommitdiff
path: root/drivers/net/wireless/ath/ath9k/wmi.h
diff options
context:
space:
mode:
authorSujith Manoharan <Sujith.Manoharan@atheros.com>2011-04-13 09:53:52 +0400
committerJohn W. Linville <linville@tuxdriver.com>2011-04-13 23:22:33 +0400
commitf4c88991f51e097b6541f998fd23d477999e5886 (patch)
tree5cc4be2cb3296f50402793e209012875dfa13f95 /drivers/net/wireless/ath/ath9k/wmi.h
parentb0a6ba983e3663bf256ca2e79d17bb846878cd9e (diff)
downloadlinux-f4c88991f51e097b6541f998fd23d477999e5886.tar.xz
ath9k_htc: Queue WMI events
Use a queue to handle WMI events and schedule a tasklet to process the events. This fixes the race between the WMI event ISR and the SWBA tasklet when the arrival of WMI events in quick succession could overwrite the SWBA data before the tasklet from a previous iteration could have been scheduled. Also, drain the WMI queue properly. Signed-off-by: Sujith Manoharan <Sujith.Manoharan@atheros.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/ath/ath9k/wmi.h')
-rw-r--r--drivers/net/wireless/ath/ath9k/wmi.h7
1 files changed, 4 insertions, 3 deletions
diff --git a/drivers/net/wireless/ath/ath9k/wmi.h b/drivers/net/wireless/ath/ath9k/wmi.h
index 2fa91a941a72..ff5ba2b30ecc 100644
--- a/drivers/net/wireless/ath/ath9k/wmi.h
+++ b/drivers/net/wireless/ath/ath9k/wmi.h
@@ -106,13 +106,13 @@ struct wmi {
struct mutex op_mutex;
struct completion cmd_wait;
enum wmi_cmd_id last_cmd_id;
+ struct sk_buff_head wmi_event_queue;
+ struct tasklet_struct wmi_event_tasklet;
u16 tx_seq_id;
u8 *cmd_rsp_buf;
u32 cmd_rsp_len;
bool stopped;
- u64 tsf;
- u8 beacon_pending;
spinlock_t wmi_lock;
atomic_t mwrite_cnt;
@@ -129,8 +129,9 @@ int ath9k_wmi_cmd(struct wmi *wmi, enum wmi_cmd_id cmd_id,
u8 *cmd_buf, u32 cmd_len,
u8 *rsp_buf, u32 rsp_len,
u32 timeout);
-void ath9k_swba_tasklet(unsigned long data);
+void ath9k_wmi_event_tasklet(unsigned long data);
void ath9k_fatal_work(struct work_struct *work);
+void ath9k_wmi_event_drain(struct ath9k_htc_priv *priv);
#define WMI_CMD(_wmi_cmd) \
do { \