From 37cf36d2e635c8f945e0da74c0e8eb9513d54cbe Mon Sep 17 00:00:00 2001 From: Chris Guo Date: Thu, 6 Jul 2017 18:56:32 +0800 Subject: [PATCH] qcacmn: Fix TX Bus bundle error for SDIO WLAN For SDIO WLAN, the creditsize is different for data EP than other EPs. This change using alt credit size to replace of original credit size. CRs-Fixed: 2072158 Change-Id: I105db55da66e6123b2a53326d53758c24eca21ec --- htc/htc.c | 1 + htc/htc_internal.h | 6 ++++++ 2 files changed, 7 insertions(+) diff --git a/htc/htc.c b/htc/htc.c index af70af46b1e1..96bf64b8d0d3 100644 --- a/htc/htc.c +++ b/htc/htc.c @@ -564,6 +564,7 @@ QDF_STATUS htc_wait_target(HTC_HANDLE HTCHandle) (int)HTC_GET_FIELD(rdy_msg, HTC_READY_MSG, CREDITSIZE); target->MaxMsgsPerHTCBundle = (uint8_t) pReadyMsg->MaxMsgsPerHTCBundle; + UPDATE_ALT_CREDIT(target, pReadyMsg->AltDataCreditSize); /* for old fw this value is set to 0. But the minimum value * should be 1, i.e., no bundling */ diff --git a/htc/htc_internal.h b/htc/htc_internal.h index 9c27af10ae84..097055bb8d9a 100644 --- a/htc/htc_internal.h +++ b/htc/htc_internal.h @@ -57,6 +57,12 @@ extern "C" { #define HTC_MAX_MSG_PER_BUNDLE_TX 32 #endif +#ifdef HIF_SDIO +#define UPDATE_ALT_CREDIT(tar, val) (tar->AltDataCreditSize = (uint16_t) val) +#else +#define UPDATE_ALT_CREDIT(tar, val) /* no-op */ +#endif + /* * HTC_MAX_TX_BUNDLE_SEND_LIMIT - * This value is in units of tx frame fragments.