summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAly Hirani <ahirani@nvidia.com>2014-07-01 22:28:20 -0700
committerMandar Padmawar <mpadmawar@nvidia.com>2014-07-10 02:05:29 -0700
commitea12ab572c85afc9157802c32bfc50e2c6054d8c (patch)
tree64f11b13f064ce44b179e9325e11330831ea6bb7
parent18e24631245a49bc522154eee4574f4564d9e3af (diff)
bcmdhd: Override fw's check for flowcontrol
The broadcom firmware sends a flowcontrol status in the rx packet indicating that it is running short on tx buffers. This bit is used to tell the driver to stop sending packets (based on their priority). However, there seems to be a significantly large delay (~100ms) in the fw updating the driver with the new flowcontrol bits. Ozmo's audio traffic is marked as 0x106 priority which translates to priority=0x40. This change overrides the flowcontrol bits sent by the fw and makes it so that the 0x40 priority traffic is never blocked from flowcontrol. The DATAOK(bus) check on the bus ensures that we always have enough tx buffers on the chip (despite the flowcontrol being set) and that we don't end up clobbering packets on the fw. Change-Id: I26c2d6f3b66d2e2f23c4c5327ed2577025bc089c Signed-off-by: Aly Hirani <ahirani@nvidia.com> Reviewed-on: http://git-master/r/433463 (cherry picked from commit 98ab3dfb5c46e48a140d0888540d48b8770c9f4d) Reviewed-on: http://git-master/r/435729 GVS: Gerrit_Virtual_Submit Reviewed-by: Anshul Jain (SW) <anshulj@nvidia.com> Tested-by: Anshul Jain (SW) <anshulj@nvidia.com>
-rwxr-xr-xdrivers/net/wireless/bcmdhd/dhd_sdio.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/net/wireless/bcmdhd/dhd_sdio.c b/drivers/net/wireless/bcmdhd/dhd_sdio.c
index 30c4c0c2668a..a6cb1b06b27a 100755
--- a/drivers/net/wireless/bcmdhd/dhd_sdio.c
+++ b/drivers/net/wireless/bcmdhd/dhd_sdio.c
@@ -5581,7 +5581,7 @@ dhdsdio_readframes(dhd_bus_t *bus, uint maxframes, bool *finished)
if (delta) {
bus->fc_rcvd++;
- bus->flowcontrol = fcbits;
+ bus->flowcontrol = fcbits & ~(1 << 6);
}
/* Check and update sequence number */
@@ -5739,7 +5739,7 @@ dhdsdio_readframes(dhd_bus_t *bus, uint maxframes, bool *finished)
if (delta) {
bus->fc_rcvd++;
- bus->flowcontrol = fcbits;
+ bus->flowcontrol = fcbits & ~(1 << 6);
}
/* Check and update sequence number */
@@ -5998,7 +5998,7 @@ dhdsdio_hostmail(dhd_bus_t *bus)
bus->fc_xon++;
bus->fc_rcvd++;
- bus->flowcontrol = fcbits;
+ bus->flowcontrol = fcbits & ~(1 << 6);
}
#ifdef DHD_DEBUG