Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit df912e51 authored by Johannes Berg's avatar Johannes Berg Committed by John W. Linville
Browse files

iwlagn: use per-vif AC parameters



Eliad added the ability to configure AC parameters
per virtual interface; make use of this in iwlwifi
and set the parameters in the right context. Since
storage and uploading to the device is already per
context, this is sufficient.

Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
Signed-off-by: default avatarWey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
parent 7335613a
Loading
Loading
Loading
Loading
+14 −16
Original line number Diff line number Diff line
@@ -1125,10 +1125,14 @@ int iwlagn_mac_conf_tx(struct ieee80211_hw *hw,
		    const struct ieee80211_tx_queue_params *params)
{
	struct iwl_priv *priv = hw->priv;
	struct iwl_rxon_context *ctx;
	struct iwl_vif_priv *vif_priv = (void *)vif->drv_priv;
	struct iwl_rxon_context *ctx = vif_priv->ctx;
	unsigned long flags;
	int q;

	if (WARN_ON(!ctx))
		return -EINVAL;

	IWL_DEBUG_MAC80211(priv, "enter\n");

	if (!iwl_is_ready_rf(priv->shrd)) {
@@ -1145,11 +1149,6 @@ int iwlagn_mac_conf_tx(struct ieee80211_hw *hw,

	spin_lock_irqsave(&priv->shrd->lock, flags);

	/*
	 * MULTI-FIXME
	 * This may need to be done per interface in nl80211/cfg80211/mac80211.
	 */
	for_each_context(priv, ctx) {
	ctx->qos_data.def_qos_parm.ac[q].cw_min =
		cpu_to_le16(params->cw_min);
	ctx->qos_data.def_qos_parm.ac[q].cw_max =
@@ -1159,7 +1158,6 @@ int iwlagn_mac_conf_tx(struct ieee80211_hw *hw,
			cpu_to_le16((params->txop * 32));

	ctx->qos_data.def_qos_parm.ac[q].reserved1 = 0;
	}

	spin_unlock_irqrestore(&priv->shrd->lock, flags);