From: Kalle Valo <kvalo@qca.qualcomm.com>
To: Michal Kazior <michal.kazior@tieto.com>
Cc: <ath10k@lists.infradead.org>, <linux-wireless@vger.kernel.org>
Subject: Re: [PATCH 1/2] ath10k: implement channel switching
Date: Fri, 24 Jan 2014 10:20:34 +0200 [thread overview]
Message-ID: <87ob314wq5.fsf@kamboji.qca.qualcomm.com> (raw)
In-Reply-To: <1390473506-15677-2-git-send-email-michal.kazior@tieto.com> (Michal Kazior's message of "Thu, 23 Jan 2014 11:38:25 +0100")
Michal Kazior <michal.kazior@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@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
next prev parent reply other threads:[~2014-01-24 8:20 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-01-23 10:38 [PATCH 0/2] ath10k: add CSA support Michal Kazior
2014-01-23 10:38 ` [PATCH 1/2] ath10k: implement channel switching Michal Kazior
2014-01-24 8:20 ` Kalle Valo [this message]
2014-01-23 10:38 ` [PATCH 2/2] ath10k: implement AP CSA Michal Kazior
2014-01-23 11:59 ` [PATCH 0/2] ath10k: add CSA support Kalle Valo
2014-01-23 12:10 ` Michal Kazior
2014-01-24 8:24 ` Kalle Valo
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87ob314wq5.fsf@kamboji.qca.qualcomm.com \
--to=kvalo@qca.qualcomm.com \
--cc=ath10k@lists.infradead.org \
--cc=linux-wireless@vger.kernel.org \
--cc=michal.kazior@tieto.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).