summaryrefslogtreecommitdiff
path: root/drivers/net/wireless/broadcom
diff options
context:
space:
mode:
authorDouble Lo <double.lo@cypress.com>2020-06-10 10:21:05 -0500
committerKalle Valo <kvalo@codeaurora.org>2020-07-14 12:46:46 +0300
commitbbf7ae3dcb42b720943a2589cf4d0061ab3ac129 (patch)
tree9c35d11ac22bd440f31d83e867713e03df8e82f0 /drivers/net/wireless/broadcom
parentd843246ee7614828ac5ff1d58b21b1fce853044e (diff)
brcmfmac: fix throughput zero stalls on PM 1 mode due to credit map
This patch move the credit map setting to right place to avoid brcmf_fws_return_credits() return without setting the credit map. It fix the thoughput zero stalls issue in softAP mode when STA using PM 1 mode. Signed-off-by: Double Lo <double.lo@cypress.com> Signed-off-by: Chi-hsien Lin <chi-hsien.lin@cypress.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> Link: https://lore.kernel.org/r/20200610152106.175257-6-chi-hsien.lin@cypress.com
Diffstat (limited to 'drivers/net/wireless/broadcom')
-rw-r--r--drivers/net/wireless/broadcom/brcm80211/brcmfmac/fwsignal.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/fwsignal.c b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/fwsignal.c
index 2758e704ad54..4fefa7c0b892 100644
--- a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/fwsignal.c
+++ b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/fwsignal.c
@@ -1193,6 +1193,8 @@ static void brcmf_fws_return_credits(struct brcmf_fws_info *fws,
if (!credits)
return;
+ fws->fifo_credit_map |= 1 << fifo;
+
if (fifo > BRCMF_FWS_FIFO_AC_BK &&
fifo <= BRCMF_FWS_FIFO_AC_VO) {
for (lender_ac = BRCMF_FWS_FIFO_AC_VO; lender_ac >= 0;
@@ -1216,7 +1218,6 @@ static void brcmf_fws_return_credits(struct brcmf_fws_info *fws,
if (credits) {
fws->fifo_credit[fifo] += credits;
- fws->fifo_credit_map |= 1 << fifo;
}
if (fws->fifo_credit[fifo] > fws->init_fifo_credit[fifo])