diff options
author | Samuel Ortiz <sameo@linux.intel.com> | 2009-10-16 01:18:56 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2009-10-27 16:48:27 -0400 |
commit | 56e3f085f5b5e49cca37a3d1b0aa4266b984eb12 (patch) | |
tree | ef491ba0c7ab2b0c0e717b3b8cb55e1b01791424 | |
parent | 708567e0723f3a217286c2b60805af6de360ec50 (diff) |
iwmc3200wifi: Do not handle wifi command if the interface is not ready
When resetting or bringing the interface down, we should just reject any wifi
related command.
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Signed-off-by: Zhu Yi <yi.zhu@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
-rw-r--r-- | drivers/net/wireless/iwmc3200wifi/commands.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/net/wireless/iwmc3200wifi/commands.c b/drivers/net/wireless/iwmc3200wifi/commands.c index d5125b7659a8..25fb8dfd83b5 100644 --- a/drivers/net/wireless/iwmc3200wifi/commands.c +++ b/drivers/net/wireless/iwmc3200wifi/commands.c | |||
@@ -76,6 +76,11 @@ int iwm_send_wifi_if_cmd(struct iwm_priv *iwm, void *payload, u16 payload_size, | |||
76 | int ret; | 76 | int ret; |
77 | u8 oid = hdr->oid; | 77 | u8 oid = hdr->oid; |
78 | 78 | ||
79 | if (!test_bit(IWM_STATUS_READY, &iwm->status)) { | ||
80 | IWM_ERR(iwm, "Interface is not ready yet"); | ||
81 | return -EAGAIN; | ||
82 | } | ||
83 | |||
79 | umac_cmd.id = UMAC_CMD_OPCODE_WIFI_IF_WRAPPER; | 84 | umac_cmd.id = UMAC_CMD_OPCODE_WIFI_IF_WRAPPER; |
80 | umac_cmd.resp = resp; | 85 | umac_cmd.resp = resp; |
81 | 86 | ||