* [PATCH] ath10k: fix rx_channel during hw reconfigure
@ 2016-04-07 6:41 ` Rajkumar Manoharan
0 siblings, 0 replies; 4+ messages in thread
From: Rajkumar Manoharan @ 2016-04-07 6:41 UTC (permalink / raw)
To: ath10k; +Cc: stable, linux-wireless, Rajkumar Manoharan, rmanohar
Upon firmware assert, restart work will be triggered so that mac80211
will reconfigure the driver. An issue is reported that after restart
work, survey dump data do not contain in-use (SURVEY_INFO_IN_USE) info
for operating channel. During reconfigure, since mac80211 already has
valid channel context for given radio, channel context iteration return
num_chanctx > 0. Hence rx_channel is always NULL. Fix this by assigning
channel context to rx_channel when driver restart is in progress.
Cc: stable@vger.kernel.org
Signed-off-by: Rajkumar Manoharan <rmanohar@qti.qualcomm.com>
---
drivers/net/wireless/ath/ath10k/mac.c | 8 +++++++-
1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/drivers/net/wireless/ath/ath10k/mac.c b/drivers/net/wireless/ath/ath10k/mac.c
index b0e613bc10a5..e31469dd58dd 100644
--- a/drivers/net/wireless/ath/ath10k/mac.c
+++ b/drivers/net/wireless/ath/ath10k/mac.c
@@ -6867,7 +6867,13 @@ ath10k_mac_update_rx_channel(struct ath10k *ar,
def = &vifs[0].new_ctx->def;
ar->rx_channel = def->chan;
- } else if (ctx && ath10k_mac_num_chanctxs(ar) == 0) {
+ } else if ((ctx && ath10k_mac_num_chanctxs(ar) == 0) ||
+ (ctx && (ar->state == ATH10K_STATE_RESTARTED))) {
+ /* During driver restart due to firmware assert, since mac80211
+ * already has valid channel context for given radio, channel
+ * context iteration return num_chanctx > 0. So fix rx_channel
+ * when restart is in progress.
+ */
ar->rx_channel = ctx->def.chan;
} else {
ar->rx_channel = NULL;
--
2.7.4
_______________________________________________
ath10k mailing list
ath10k@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/ath10k
^ permalink raw reply related [flat|nested] 4+ messages in thread
* [PATCH] ath10k: fix rx_channel during hw reconfigure
@ 2016-04-07 6:41 ` Rajkumar Manoharan
0 siblings, 0 replies; 4+ messages in thread
From: Rajkumar Manoharan @ 2016-04-07 6:41 UTC (permalink / raw)
To: ath10k; +Cc: linux-wireless, rmanohar, Rajkumar Manoharan, stable
Upon firmware assert, restart work will be triggered so that mac80211
will reconfigure the driver. An issue is reported that after restart
work, survey dump data do not contain in-use (SURVEY_INFO_IN_USE) info
for operating channel. During reconfigure, since mac80211 already has
valid channel context for given radio, channel context iteration return
num_chanctx > 0. Hence rx_channel is always NULL. Fix this by assigning
channel context to rx_channel when driver restart is in progress.
Cc: stable@vger.kernel.org
Signed-off-by: Rajkumar Manoharan <rmanohar@qti.qualcomm.com>
---
drivers/net/wireless/ath/ath10k/mac.c | 8 +++++++-
1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/drivers/net/wireless/ath/ath10k/mac.c b/drivers/net/wireless/ath/ath10k/mac.c
index b0e613bc10a5..e31469dd58dd 100644
--- a/drivers/net/wireless/ath/ath10k/mac.c
+++ b/drivers/net/wireless/ath/ath10k/mac.c
@@ -6867,7 +6867,13 @@ ath10k_mac_update_rx_channel(struct ath10k *ar,
def = &vifs[0].new_ctx->def;
ar->rx_channel = def->chan;
- } else if (ctx && ath10k_mac_num_chanctxs(ar) == 0) {
+ } else if ((ctx && ath10k_mac_num_chanctxs(ar) == 0) ||
+ (ctx && (ar->state == ATH10K_STATE_RESTARTED))) {
+ /* During driver restart due to firmware assert, since mac80211
+ * already has valid channel context for given radio, channel
+ * context iteration return num_chanctx > 0. So fix rx_channel
+ * when restart is in progress.
+ */
ar->rx_channel = ctx->def.chan;
} else {
ar->rx_channel = NULL;
--
2.7.4
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH] ath10k: fix rx_channel during hw reconfigure
2016-04-07 6:41 ` Rajkumar Manoharan
@ 2016-04-19 15:47 ` Valo, Kalle
-1 siblings, 0 replies; 4+ messages in thread
From: Valo, Kalle @ 2016-04-19 15:47 UTC (permalink / raw)
To: Manoharan, Rajkumar
Cc: linux-wireless@vger.kernel.org, stable@vger.kernel.org,
ath10k@lists.infradead.org, rmanohar@codeaurora.org
Rajkumar Manoharan <rmanohar@qti.qualcomm.com> writes:
> Upon firmware assert, restart work will be triggered so that mac80211
> will reconfigure the driver. An issue is reported that after restart
> work, survey dump data do not contain in-use (SURVEY_INFO_IN_USE) info
> for operating channel. During reconfigure, since mac80211 already has
> valid channel context for given radio, channel context iteration return
> num_chanctx > 0. Hence rx_channel is always NULL. Fix this by assigning
> channel context to rx_channel when driver restart is in progress.
>
> Cc: stable@vger.kernel.org
> Signed-off-by: Rajkumar Manoharan <rmanohar@qti.qualcomm.com>
Applied, thanks.
--
Kalle Valo
_______________________________________________
ath10k mailing list
ath10k@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/ath10k
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] ath10k: fix rx_channel during hw reconfigure
@ 2016-04-19 15:47 ` Valo, Kalle
0 siblings, 0 replies; 4+ messages in thread
From: Valo, Kalle @ 2016-04-19 15:47 UTC (permalink / raw)
To: Manoharan, Rajkumar
Cc: ath10k@lists.infradead.org, stable@vger.kernel.org,
linux-wireless@vger.kernel.org, rmanohar@codeaurora.org
Rajkumar Manoharan <rmanohar@qti.qualcomm.com> writes:
> Upon firmware assert, restart work will be triggered so that mac80211
> will reconfigure the driver. An issue is reported that after restart
> work, survey dump data do not contain in-use (SURVEY_INFO_IN_USE) info
> for operating channel. During reconfigure, since mac80211 already has
> valid channel context for given radio, channel context iteration return
> num_chanctx > 0. Hence rx_channel is always NULL. Fix this by assigning
> channel context to rx_channel when driver restart is in progress.
>
> Cc: stable@vger.kernel.org
> Signed-off-by: Rajkumar Manoharan <rmanohar@qti.qualcomm.com>
Applied, thanks.
--
Kalle Valo
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2016-04-19 15:47 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-04-07 6:41 [PATCH] ath10k: fix rx_channel during hw reconfigure Rajkumar Manoharan
2016-04-07 6:41 ` Rajkumar Manoharan
2016-04-19 15:47 ` Valo, Kalle
2016-04-19 15:47 ` Valo, Kalle
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.