Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 300823
b: refs/heads/master
c: 03bdeb0
h: refs/heads/master
i:
  300821: 73502d0
  300819: 83ae4a6
  300815: fe58fb4
v: v3
  • Loading branch information
Vasanthakumar Thiagarajan authored and Kalle Valo committed Mar 26, 2012
1 parent 3807f9e commit bf70c66
Show file tree
Hide file tree
Showing 5 changed files with 42 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 0564161ea902c6c3e7e45ffd2df37bcb0d235acb
refs/heads/master: 03bdeb0d545340f7c2768e11c294d067e76de8c9
11 changes: 11 additions & 0 deletions trunk/drivers/net/wireless/ath/ath6kl/cfg80211.c
Original file line number Diff line number Diff line change
Expand Up @@ -2617,6 +2617,13 @@ static int ath6kl_start_ap(struct wiphy *wiphy, struct net_device *dev,
p.nw_subtype = SUBTYPE_NONE;
}

if (info->inactivity_timeout) {
res = ath6kl_wmi_set_inact_period(ar->wmi, vif->fw_vif_idx,
info->inactivity_timeout);
if (res < 0)
return res;
}

res = ath6kl_wmi_ap_profile_commit(ar->wmi, vif->fw_vif_idx, &p);
if (res < 0)
return res;
Expand Down Expand Up @@ -3283,6 +3290,10 @@ int ath6kl_cfg80211_init(struct ath6kl *ar)
if (test_bit(ATH6KL_FW_CAPABILITY_SCHED_SCAN, ar->fw_capabilities))
ar->wiphy->flags |= WIPHY_FLAG_SUPPORTS_SCHED_SCAN;

if (test_bit(ATH6KL_FW_CAPABILITY_INACTIVITY_TIMEOUT,
ar->fw_capabilities))
ar->wiphy->features = NL80211_FEATURE_INACTIVITY_TIMER;

ar->wiphy->probe_resp_offload =
NL80211_PROBE_RESP_OFFLOAD_SUPPORT_WPS |
NL80211_PROBE_RESP_OFFLOAD_SUPPORT_WPS2 |
Expand Down
6 changes: 6 additions & 0 deletions trunk/drivers/net/wireless/ath/ath6kl/core.h
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,12 @@ enum ath6kl_fw_capability {
*/
ATH6KL_FW_CAPABILITY_STA_P2PDEV_DUPLEX,

/*
* Firmware has support to cleanup inactive stations
* in AP mode.
*/
ATH6KL_FW_CAPABILITY_INACTIVITY_TIMEOUT,

/* this needs to be last */
ATH6KL_FW_CAPABILITY_MAX,
};
Expand Down
17 changes: 17 additions & 0 deletions trunk/drivers/net/wireless/ath/ath6kl/wmi.c
Original file line number Diff line number Diff line change
Expand Up @@ -3395,6 +3395,23 @@ int ath6kl_wmi_cancel_remain_on_chnl_cmd(struct wmi *wmi, u8 if_idx)
WMI_CANCEL_REMAIN_ON_CHNL_CMDID);
}

int ath6kl_wmi_set_inact_period(struct wmi *wmi, u8 if_idx, int inact_timeout)
{
struct sk_buff *skb;
struct wmi_set_inact_period_cmd *cmd;

skb = ath6kl_wmi_get_new_buf(sizeof(*cmd));
if (!skb)
return -ENOMEM;

cmd = (struct wmi_set_inact_period_cmd *) skb->data;
cmd->inact_period = cpu_to_le32(inact_timeout);
cmd->num_null_func = 0;

return ath6kl_wmi_cmd_send(wmi, if_idx, skb, WMI_AP_CONN_INACT_CMDID,
NO_SYNC_WMIFLAG);
}

static int ath6kl_wmi_control_rx_xtnd(struct wmi *wmi, struct sk_buff *skb)
{
struct wmix_cmd_hdr *cmd;
Expand Down
7 changes: 7 additions & 0 deletions trunk/drivers/net/wireless/ath/ath6kl/wmi.h
Original file line number Diff line number Diff line change
Expand Up @@ -2141,6 +2141,11 @@ struct wmi_ap_hidden_ssid_cmd {
u8 hidden_ssid;
} __packed;

struct wmi_set_inact_period_cmd {
__le32 inact_period;
u8 num_null_func;
} __packed;

/* AP mode events */
struct wmi_ap_set_apsd_cmd {
u8 enable;
Expand Down Expand Up @@ -2538,6 +2543,8 @@ int ath6kl_wmi_cancel_remain_on_chnl_cmd(struct wmi *wmi, u8 if_idx);
int ath6kl_wmi_set_appie_cmd(struct wmi *wmi, u8 if_idx, u8 mgmt_frm_type,
const u8 *ie, u8 ie_len);

int ath6kl_wmi_set_inact_period(struct wmi *wmi, u8 if_idx, int inact_timeout);

void ath6kl_wmi_sscan_timer(unsigned long ptr);

struct ath6kl_vif *ath6kl_get_vif_by_index(struct ath6kl *ar, u8 if_idx);
Expand Down

0 comments on commit bf70c66

Please sign in to comment.