summaryrefslogtreecommitdiff
path: root/drivers/net/wireless/ath/ath9k/wmi.h
diff options
context:
space:
mode:
authorSujith <Sujith.Manoharan@atheros.com>2010-04-16 10:24:01 +0400
committerJohn W. Linville <linville@tuxdriver.com>2010-04-16 23:47:12 +0400
commit6ce34ec11c6297562e70e27c57a24cd27d4cd2b1 (patch)
treee2cc737d1c962cca801d61aa7a609df9dfc3bdef /drivers/net/wireless/ath/ath9k/wmi.h
parenteac8e385e9446e591aacbc9ef2c2a3b0836dd2d4 (diff)
downloadlinux-6ce34ec11c6297562e70e27c57a24cd27d4cd2b1.tar.xz
ath9k_htc: Handle WMI timeouts properly
If a WMI command has timed out for some reason, a late WMI response would end up updating the response region of a new WMI request that has been issued in the meantime. Fix this race condition by dropping a WMI response if a new WMI command has been issued. Signed-off-by: Sujith <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.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/net/wireless/ath/ath9k/wmi.h b/drivers/net/wireless/ath/ath9k/wmi.h
index fd8c9c5f4a05..611357158ecf 100644
--- a/drivers/net/wireless/ath/ath9k/wmi.h
+++ b/drivers/net/wireless/ath/ath9k/wmi.h
@@ -97,6 +97,7 @@ struct wmi {
enum htc_endpoint_id ctrl_epid;
struct mutex op_mutex;
struct completion cmd_wait;
+ enum wmi_cmd_id last_cmd_id;
u16 tx_seq_id;
u8 *cmd_rsp_buf;
u32 cmd_rsp_len;