From: Johannes Berg Date: Thu, 22 Sep 2011 22:14:55 +0000 (-0700) Subject: iwlagn: fix slot programming X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=325a7ddf7b27ed3ded3d7fb7c3313266e510a978;p=openwrt%2Fstaging%2Fblogic.git iwlagn: fix slot programming When an AP mode interface is added with a DTIM period of two, the slot programming is wrong. Fix it by taking into account the DTIM period. Signed-off-by: Johannes Berg Signed-off-by: Wey-Yi Guy Signed-off-by: John W. Linville --- diff --git a/drivers/net/wireless/iwlwifi/iwl-agn-rxon.c b/drivers/net/wireless/iwlwifi/iwl-agn-rxon.c index 00e6fc59e459..ca632f9b1cc8 100644 --- a/drivers/net/wireless/iwlwifi/iwl-agn-rxon.c +++ b/drivers/net/wireless/iwlwifi/iwl-agn-rxon.c @@ -370,7 +370,7 @@ int iwlagn_set_pan_params(struct iwl_priv *priv) slot1 = IWL_MIN_SLOT_TIME; } else if (!ctx_pan->vif->bss_conf.idle && !ctx_pan->vif->bss_conf.assoc) { - slot1 = bcnint * 3 - IWL_MIN_SLOT_TIME; + slot1 = dtim * bcnint * 3 - IWL_MIN_SLOT_TIME; slot0 = IWL_MIN_SLOT_TIME; } } else if (ctx_pan->vif) {