Search Linux Wireless

Re: [PATCH 1/2] ath10k: implement channel switching

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Michal Kazior <michal.kazior@xxxxxxxxx> 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@xxxxxxxxx>

[...]

> @@ -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
--
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Wireless Personal Area Network]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite Hiking]     [MIPS Linux]     [ARM Linux]     [Linux RAID]

  Powered by Linux