]> rtime.felk.cvut.cz Git - sojka/nv-tegra/linux-3.10.git/commitdiff
net: wireless: bcmdhd: Avoid data pkt processing if credits is low
authorRamanathan R <ramanat@broadcom.com>
Mon, 25 Jan 2016 18:28:47 +0000 (10:28 -0800)
committerWinnie Hsu <whsu@nvidia.com>
Thu, 4 Feb 2016 23:41:03 +0000 (15:41 -0800)
When running the EU wifi adaptivity test, ioctl timeouts are
observed as ctrl frames are out of bus credits and do not get sent
to the wifi chip. As a result, the OS resets the wifi chip to recover
the ioctl timeout. This results in EU wifi adaptivity test failure.

To prevent this from happening, avoid processing the data frames if
available credits is low.

Bug 1700549

Change-Id: Iaaf46112b1673088c27bfc5126b874dcdeb82b2d
Signed-off-by: Srinivas Ramachandran <srinivasra@nvidia.com>
Reviewed-on: http://git-master/r/999523
GVS: Gerrit_Virtual_Submit
Reviewed-by: Winnie Hsu <whsu@nvidia.com>
drivers/net/wireless/bcmdhd/dhd_wlfc.c

index a6c3cc598ff8d5af8efa6052989ad3ea353897d4..cd8dc675e05c4a4a00adb0fc17d2ee69ce8aab8d 100644 (file)
@@ -2891,6 +2891,11 @@ dhd_wlfc_transfer_packets(void *data)
                        continue;
                }
 
+               if (ctx->FIFO_credit[ac] < 3) {
+                       DHD_EVENT(("Avoid pkt processing if credit is low (<3)\n"));
+                       continue;
+               }
+
                tx_map |= (1 << ac);
                single_ac = ac + 1;
                while (FALSE == dhdp->proptxstatus_txoff) {