提交 8d44f2bd 编写于 作者: S Stanislaw Gruszka 提交者: John W. Linville

iwlegacy: move qos_data out of ctx structure

Signed-off-by: NStanislaw Gruszka <sgruszka@redhat.com>
Signed-off-by: NJohn W. Linville <linville@tuxdriver.com>
上级 8c9c48d5
...@@ -4496,15 +4496,15 @@ il_mac_conf_tx(struct ieee80211_hw *hw, struct ieee80211_vif *vif, u16 queue, ...@@ -4496,15 +4496,15 @@ il_mac_conf_tx(struct ieee80211_hw *hw, struct ieee80211_vif *vif, u16 queue,
spin_lock_irqsave(&il->lock, flags); spin_lock_irqsave(&il->lock, flags);
il->ctx.qos_data.def_qos_parm.ac[q].cw_min = il->qos_data.def_qos_parm.ac[q].cw_min =
cpu_to_le16(params->cw_min); cpu_to_le16(params->cw_min);
il->ctx.qos_data.def_qos_parm.ac[q].cw_max = il->qos_data.def_qos_parm.ac[q].cw_max =
cpu_to_le16(params->cw_max); cpu_to_le16(params->cw_max);
il->ctx.qos_data.def_qos_parm.ac[q].aifsn = params->aifs; il->qos_data.def_qos_parm.ac[q].aifsn = params->aifs;
il->ctx.qos_data.def_qos_parm.ac[q].edca_txop = il->qos_data.def_qos_parm.ac[q].edca_txop =
cpu_to_le16((params->txop * 32)); cpu_to_le16((params->txop * 32));
il->ctx.qos_data.def_qos_parm.ac[q].reserved1 = 0; il->qos_data.def_qos_parm.ac[q].reserved1 = 0;
spin_unlock_irqrestore(&il->lock, flags); spin_unlock_irqrestore(&il->lock, flags);
...@@ -5230,20 +5230,20 @@ il_update_qos(struct il_priv *il, struct il_rxon_context *ctx) ...@@ -5230,20 +5230,20 @@ il_update_qos(struct il_priv *il, struct il_rxon_context *ctx)
if (!ctx->is_active) if (!ctx->is_active)
return; return;
ctx->qos_data.def_qos_parm.qos_flags = 0; il->qos_data.def_qos_parm.qos_flags = 0;
if (ctx->qos_data.qos_active) if (il->qos_data.qos_active)
ctx->qos_data.def_qos_parm.qos_flags |= il->qos_data.def_qos_parm.qos_flags |=
QOS_PARAM_FLG_UPDATE_EDCA_MSK; QOS_PARAM_FLG_UPDATE_EDCA_MSK;
if (ctx->ht.enabled) if (ctx->ht.enabled)
ctx->qos_data.def_qos_parm.qos_flags |= QOS_PARAM_FLG_TGN_MSK; il->qos_data.def_qos_parm.qos_flags |= QOS_PARAM_FLG_TGN_MSK;
D_QOS("send QoS cmd with Qos active=%d FLAGS=0x%X\n", D_QOS("send QoS cmd with Qos active=%d FLAGS=0x%X\n",
ctx->qos_data.qos_active, ctx->qos_data.def_qos_parm.qos_flags); il->qos_data.qos_active, il->qos_data.def_qos_parm.qos_flags);
il_send_cmd_pdu_async(il, C_QOS_PARAM, sizeof(struct il_qosparam_cmd), il_send_cmd_pdu_async(il, C_QOS_PARAM, sizeof(struct il_qosparam_cmd),
&ctx->qos_data.def_qos_parm, NULL); &il->qos_data.def_qos_parm, NULL);
} }
/** /**
...@@ -5596,7 +5596,7 @@ il_mac_bss_info_changed(struct ieee80211_hw *hw, struct ieee80211_vif *vif, ...@@ -5596,7 +5596,7 @@ il_mac_bss_info_changed(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
unsigned long flags; unsigned long flags;
spin_lock_irqsave(&il->lock, flags); spin_lock_irqsave(&il->lock, flags);
ctx->qos_data.qos_active = bss_conf->qos; il->qos_data.qos_active = bss_conf->qos;
il_update_qos(il, ctx); il_update_qos(il, ctx);
spin_unlock_irqrestore(&il->lock, flags); spin_unlock_irqrestore(&il->lock, flags);
} }
......
...@@ -1165,8 +1165,6 @@ struct il_rxon_context { ...@@ -1165,8 +1165,6 @@ struct il_rxon_context {
*/ */
bool always_active, is_active; bool always_active, is_active;
struct il_qos_info qos_data;
struct { struct {
bool non_gf_sta_present; bool non_gf_sta_present;
u8 protection; u8 protection;
...@@ -1278,6 +1276,8 @@ struct il_priv { ...@@ -1278,6 +1276,8 @@ struct il_priv {
struct il_rxon_context ctx; struct il_rxon_context ctx;
struct il_qos_info qos_data;
/* /*
* We declare this const so it can only be * We declare this const so it can only be
* changed via explicit cast within the * changed via explicit cast within the
......
...@@ -644,7 +644,6 @@ il_dbgfs_qos_read(struct file *file, char __user *user_buf, size_t count, ...@@ -644,7 +644,6 @@ il_dbgfs_qos_read(struct file *file, char __user *user_buf, size_t count,
loff_t *ppos) loff_t *ppos)
{ {
struct il_priv *il = file->private_data; struct il_priv *il = file->private_data;
struct il_rxon_context *ctx = &il->ctx;
int pos = 0, i; int pos = 0, i;
char buf[256]; char buf[256];
const size_t bufsz = sizeof(buf); const size_t bufsz = sizeof(buf);
...@@ -656,10 +655,10 @@ il_dbgfs_qos_read(struct file *file, char __user *user_buf, size_t count, ...@@ -656,10 +655,10 @@ il_dbgfs_qos_read(struct file *file, char __user *user_buf, size_t count,
pos += pos +=
scnprintf(buf + pos, bufsz - pos, scnprintf(buf + pos, bufsz - pos,
"AC[%d]\t%u\t%u\t%u\t%u\n", i, "AC[%d]\t%u\t%u\t%u\t%u\n", i,
ctx->qos_data.def_qos_parm.ac[i].cw_min, il->qos_data.def_qos_parm.ac[i].cw_min,
ctx->qos_data.def_qos_parm.ac[i].cw_max, il->qos_data.def_qos_parm.ac[i].cw_max,
ctx->qos_data.def_qos_parm.ac[i].aifsn, il->qos_data.def_qos_parm.ac[i].aifsn,
ctx->qos_data.def_qos_parm.ac[i].edca_txop); il->qos_data.def_qos_parm.ac[i].edca_txop);
} }
return simple_read_from_buffer(user_buf, count, ppos, buf, pos); return simple_read_from_buffer(user_buf, count, ppos, buf, pos);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册