Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 236747
b: refs/heads/master
c: 311dce7
h: refs/heads/master
i:
  236745: e52ace1
  236743: 978b10f
v: v3
  • Loading branch information
Johannes Berg authored and John W. Linville committed Jan 21, 2011
1 parent ba7de0b commit b66bdd8
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 4 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 7194207ceea7a54c846e0865d2459f4887fe1e0d
refs/heads/master: 311dce71b6af263a630717d77bd49cffc0d122a5
15 changes: 12 additions & 3 deletions trunk/drivers/net/wireless/iwlwifi/iwl-agn-rxon.c
Original file line number Diff line number Diff line change
Expand Up @@ -52,22 +52,31 @@ static int iwlagn_disable_pan(struct iwl_priv *priv,
struct iwl_rxon_context *ctx,
struct iwl_rxon_cmd *send)
{
struct iwl_notification_wait disable_wait;
__le32 old_filter = send->filter_flags;
u8 old_dev_type = send->dev_type;
int ret;

iwlagn_init_notification_wait(priv, &disable_wait, NULL,
REPLY_WIPAN_DEACTIVATION_COMPLETE);

send->filter_flags &= ~RXON_FILTER_ASSOC_MSK;
send->dev_type = RXON_DEV_TYPE_P2P;
ret = iwl_send_cmd_pdu(priv, ctx->rxon_cmd, sizeof(*send), send);

send->filter_flags = old_filter;
send->dev_type = old_dev_type;

if (ret)
if (ret) {
IWL_ERR(priv, "Error disabling PAN (%d)\n", ret);
iwlagn_remove_notification(priv, &disable_wait);
} else {
signed long wait_res;

/* FIXME: WAIT FOR PAN DISABLE */
msleep(300);
wait_res = iwlagn_wait_notification(priv, &disable_wait, HZ);
if (wait_res == 0)
IWL_ERR(priv, "Timed out waiting for PAN disable\n");
}

return ret;
}
Expand Down
1 change: 1 addition & 0 deletions trunk/drivers/net/wireless/iwlwifi/iwl-commands.h
Original file line number Diff line number Diff line change
Expand Up @@ -189,6 +189,7 @@ enum {
REPLY_WIPAN_WEPKEY = 0xb8, /* use REPLY_WEPKEY structure */
REPLY_WIPAN_P2P_CHANNEL_SWITCH = 0xb9,
REPLY_WIPAN_NOA_NOTIFICATION = 0xbc,
REPLY_WIPAN_DEACTIVATION_COMPLETE = 0xbd,

REPLY_MAX = 0xff
};
Expand Down
1 change: 1 addition & 0 deletions trunk/drivers/net/wireless/iwlwifi/iwl-hcmd.c
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,7 @@ const char *get_cmd_string(u8 cmd)
IWL_CMD(REPLY_WIPAN_WEPKEY);
IWL_CMD(REPLY_WIPAN_P2P_CHANNEL_SWITCH);
IWL_CMD(REPLY_WIPAN_NOA_NOTIFICATION);
IWL_CMD(REPLY_WIPAN_DEACTIVATION_COMPLETE);
default:
return "UNKNOWN";

Expand Down

0 comments on commit b66bdd8

Please sign in to comment.