aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/mwifiex/11ac.c
diff options
context:
space:
mode:
authorJohn W. Linville <linville@tuxdriver.com>2013-04-10 10:39:27 -0400
committerJohn W. Linville <linville@tuxdriver.com>2013-04-10 10:39:27 -0400
commitd3641409a05dcb8e28116bb2ad638f5a42805d9d (patch)
tree1d43a5e0129709502edb631a4fd66de369ee5620 /drivers/net/wireless/mwifiex/11ac.c
parent953c96e0d85615d1ab1f100e525d376053294dc2 (diff)
parent6fe5468f452c0c40348ebd4e737758a842286ca8 (diff)
Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-next into for-davem
Conflicts: drivers/net/wireless/rt2x00/rt2x00pci.c net/mac80211/sta_info.c net/wireless/core.h
Diffstat (limited to 'drivers/net/wireless/mwifiex/11ac.c')
-rw-r--r--drivers/net/wireless/mwifiex/11ac.c41
1 files changed, 41 insertions, 0 deletions
diff --git a/drivers/net/wireless/mwifiex/11ac.c b/drivers/net/wireless/mwifiex/11ac.c
index cf43b3c29250..966a78f8e21a 100644
--- a/drivers/net/wireless/mwifiex/11ac.c
+++ b/drivers/net/wireless/mwifiex/11ac.c
@@ -259,3 +259,44 @@ int mwifiex_cmd_append_11ac_tlv(struct mwifiex_private *priv,
259 259
260 return ret_len; 260 return ret_len;
261} 261}
262
263int mwifiex_cmd_11ac_cfg(struct mwifiex_private *priv,
264 struct host_cmd_ds_command *cmd, u16 cmd_action,
265 struct mwifiex_11ac_vht_cfg *cfg)
266{
267 struct host_cmd_11ac_vht_cfg *vhtcfg = &cmd->params.vht_cfg;
268
269 cmd->command = cpu_to_le16(HostCmd_CMD_11AC_CFG);
270 cmd->size = cpu_to_le16(sizeof(struct host_cmd_11ac_vht_cfg) +
271 S_DS_GEN);
272 vhtcfg->action = cpu_to_le16(cmd_action);
273 vhtcfg->band_config = cfg->band_config;
274 vhtcfg->misc_config = cfg->misc_config;
275 vhtcfg->cap_info = cpu_to_le32(cfg->cap_info);
276 vhtcfg->mcs_tx_set = cpu_to_le32(cfg->mcs_tx_set);
277 vhtcfg->mcs_rx_set = cpu_to_le32(cfg->mcs_rx_set);
278
279 return 0;
280}
281
282/* This function initializes the BlockACK setup information for given
283 * mwifiex_private structure for 11ac enabled networks.
284 */
285void mwifiex_set_11ac_ba_params(struct mwifiex_private *priv)
286{
287 priv->add_ba_param.timeout = MWIFIEX_DEFAULT_BLOCK_ACK_TIMEOUT;
288
289 if (GET_BSS_ROLE(priv) == MWIFIEX_BSS_ROLE_UAP) {
290 priv->add_ba_param.tx_win_size =
291 MWIFIEX_11AC_UAP_AMPDU_DEF_TXWINSIZE;
292 priv->add_ba_param.rx_win_size =
293 MWIFIEX_11AC_UAP_AMPDU_DEF_RXWINSIZE;
294 } else {
295 priv->add_ba_param.tx_win_size =
296 MWIFIEX_11AC_STA_AMPDU_DEF_TXWINSIZE;
297 priv->add_ba_param.rx_win_size =
298 MWIFIEX_11AC_STA_AMPDU_DEF_RXWINSIZE;
299 }
300
301 return;
302}