[PATCH 1/2] ath10k: implement channel switching
Kalle Valo
kvalo at qca.qualcomm.com
Fri Jan 24 03:20:34 EST 2014
Michal Kazior <michal.kazior at tieto.com> writes:
> Until now channel change wasn't propagating to FW
> directly because operational channel is abstracted
> by VDEVs and it wasn't really necessary since
> ath10k implements hwscan and hwroc.
>
> This effectively fixes STA CSA and allows for
> future AP-like CSA as well.
>
> Signed-off-by: Michal Kazior <michal.kazior at tieto.com>
[...]
> @@ -2559,15 +2676,18 @@ static void ath10k_bss_info_changed(struct ieee80211_hw *hw,
> * this is never erased as we it for crypto key
> * clearing; this is FW requirement
> */
> - memcpy(arvif->u.sta.bssid, info->bssid,
> - ETH_ALEN);
> + memcpy(arvif->bssid, info->bssid, ETH_ALEN);
>
> ath10k_dbg(ATH10K_DBG_MAC,
> "mac vdev %d start %pM\n",
> arvif->vdev_id, info->bssid);
>
> - /* FIXME: check return value */
> ret = ath10k_vdev_start(arvif);
> + if (ret)
> + ath10k_warn("failed to start vdev: %d\n",
> + ret);
> + else
> + arvif->is_started = true;
> }
I really don't like that if-else construct and I think it's just better
to bail out if an error happens, so I changed this to:
ret = ath10k_vdev_start(arvif);
if (ret) {
ath10k_warn("failed to start vdev: %d\n",
ret);
return;
}
arvif->is_started = true;
--
Kalle Valo
More information about the ath10k
mailing list