qcacmn: Fix RX dead loop for SDIO WLAN

There is a dead loop when nbuf allocation failed for SDIO WLAN.
Do not change the status back to OK when E_RESOURCE is triggered.

CRs-Fixed: 2112323
Change-Id: I50b8fff99707cdccb1e5e837558131d6777ec9c0
This commit is contained in:
chenguo 2017-09-19 16:27:24 +08:00 • committed by snandini
commit ebc085458b

View file

@ -283,10 +283,6 @@ QDF_STATUS hif_dev_alloc_and_prepare_rx_packets(struct hif_sdio_device *pdev,
}
if (QDF_IS_STATUS_ERROR(status)) {
if (QDF_STATUS_E_RESOURCES == status) {
/* this is actually okay */
status = QDF_STATUS_SUCCESS;
}
break;
}
@ -294,7 +290,9 @@ QDF_STATUS hif_dev_alloc_and_prepare_rx_packets(struct hif_sdio_device *pdev,
UNLOCK_HIF_DEV_RX(pdev);
if (QDF_IS_STATUS_ERROR(status)) {
/* for NO RESOURCE error, no need to flush data queue */
if (QDF_IS_STATUS_ERROR(status)
&& (status != QDF_STATUS_E_RESOURCES)) {
while (!HTC_QUEUE_EMPTY(queue))
packet = htc_packet_dequeue(queue);
}