Lines Matching refs:pTxResult
114 static void txResult_Restart (TTxResultObj *pTxResult);
115 static void txResult_HandleNewResults (TTxResultObj *pTxResult);
133 TTxResultObj *pTxResult;
135 pTxResult = os_memoryAlloc(hOs, sizeof(TTxResultObj));
136 if (pTxResult == NULL)
139 os_memoryZero(hOs, pTxResult, sizeof(TTxResultObj));
141 pTxResult->hOs = hOs;
143 return( (TI_HANDLE)pTxResult );
160 TTxResultObj *pTxResult = (TTxResultObj *)hTxResult;
162 if (pTxResult)
163 os_memoryFree(pTxResult->hOs, pTxResult, sizeof(TTxResultObj));
178 TTxResultObj *pTxResult = (TTxResultObj *)hTxResult;
181 pTxResult->hReport = hReport;
182 pTxResult->hTwIf = hTwIf;
185 pTxn = &pTxResult->tHostCounterWriteTxn.tTxnStruct;
187 BUILD_TTxnStruct(pTxn, 0, &pTxResult->tHostCounterWriteTxn.uCounter, REGISTER_SIZE, NULL, NULL)
190 pTxn = &pTxResult->tResultsInfoReadTxn.tTxnStruct;
194 &pTxResult->tResultsInfoReadTxn.tTxResultInfo,
199 txResult_Restart (pTxResult);
215 static void txResult_Restart (TTxResultObj *pTxResult)
217 pTxResult->uHostResultsCounter = 0;
218 pTxResult->eState = TX_RESULT_STATE_IDLE;
231 TTxResultObj *pTxResult = (TTxResultObj *)hTxResult;
233 pTxResult->uTxResultInfoAddr = (TI_UINT32)(pDmaParams->fwTxResultInterface);
234 pTxResult->uTxResultHostCounterAddr = pTxResult->uTxResultInfoAddr +
237 txResult_Restart (pTxResult);
258 TTxResultObj *pTxResult = (TTxResultObj *)hTxResult;
263 pTxResult->uInterruptsCounter++;
265 if (pTxResult->eState != TX_RESULT_STATE_IDLE)
267 TRACE1(pTxResult->hReport, REPORT_SEVERITY_INFORMATION, ": called in eState %d, so exit\n", pTxResult->eState);
275 if (pFwStatusCounters->txResultsCntr == (TI_UINT8)pTxResult->uHostResultsCounter)
277 TRACE0(pTxResult->hReport, REPORT_SEVERITY_INFORMATION, ": No new Tx results\n");
307 TTxResultObj *pTxResult = (TTxResultObj *)hTxResult;
309 TTxnStruct *pTxn = &(pTxResult->tResultsInfoReadTxn.tTxnStruct);
314 TRACE2(pTxResult->hReport, REPORT_SEVERITY_INFORMATION, ": eState = %d, eTwifStatus = %d\n", pTxResult->eState, eTwifStatus);
316 switch(pTxResult->eState)
320 pTxn->uHwAddr = pTxResult->uTxResultInfoAddr;
321 eTwifStatus = twIf_Transact (pTxResult->hTwIf, pTxn);
323 pTxResult->eState = TX_RESULT_STATE_READING;
328 txResult_HandleNewResults (pTxResult);
329 pTxResult->eState = TX_RESULT_STATE_IDLE;
333 TRACE1(pTxResult->hReport, REPORT_SEVERITY_ERROR, ": Unknown eState = %d\n", pTxResult->eState);
340 TRACE2(pTxResult->hReport, REPORT_SEVERITY_ERROR, ": returning ERROR in eState %d, eTwifStatus=%d !!!\n", pTxResult->eState, eTwifStatus);
355 static void txResult_HandleNewResults (TTxResultObj *pTxResult)
362 TTxnStruct *pTxn = &(pTxResult->tHostCounterWriteTxn.tTxnStruct);
370 uFwResultsCounter = ENDIAN_HANDLE_LONG(pTxResult->tResultsInfoReadTxn.tTxResultInfo.TxResultControl.TxResultFwCounter);
371 uNumNewResults = uFwResultsCounter - pTxResult->uHostResultsCounter;
377 TRACE2(pTxResult->hReport, REPORT_SEVERITY_WARNING, ": No New Results although indicated by FwStatus!! HostCount=%d, FwCount=%d\n", pTxResult->uHostResultsCounter, uFwResultsCounter);
383 pTxResult->tHostCounterWriteTxn.uCounter = ENDIAN_HANDLE_LONG(uFwResultsCounter);
384 pTxn->uHwAddr = pTxResult->uTxResultHostCounterAddr;
385 twIf_Transact(pTxResult->hTwIf, pTxn);
387 TRACE3(pTxResult->hReport, REPORT_SEVERITY_INFORMATION, ": NumResults=%d, OriginalHostCount=%d, FwCount=%d\n", uNumNewResults, pTxResult->uHostResultsCounter, uFwResultsCounter);
393 uTableIndex = pTxResult->uHostResultsCounter & TX_RESULT_QUEUE_DEPTH_MASK;
394 pCurrentResult = &(pTxResult->tResultsInfoReadTxn.tTxResultInfo.TxResultQueue[uTableIndex]);
395 pTxResult->uHostResultsCounter++;
397 TRACE1(pTxResult->hReport, REPORT_SEVERITY_INFORMATION , ": call upper layer CB, Status = %d\n", pCurrentResult->status);
399 pTxResult->fSendPacketCompleteCb (pTxResult->hSendPacketCompleteHndl, pCurrentResult);
411 TTxResultObj* pTxResult = (TTxResultObj*)hTxResult;
417 pTxResult->fSendPacketCompleteCb = (TSendPacketCompleteCb)CBFunc;
418 pTxResult->hSendPacketCompleteHndl = hCbObj;
422 TRACE0(pTxResult->hReport, REPORT_SEVERITY_ERROR, ": Illegal value\n");
438 TTxResultObj* pTxResult = (TTxResultObj*)hTxResult;
442 WLAN_OS_REPORT(("uInterruptsCounter: %d\n", pTxResult->uInterruptsCounter));
443 WLAN_OS_REPORT(("uHostResultsCounter: %d\n", pTxResult->uHostResultsCounter));
456 TTxResultObj* pTxResult = (TTxResultObj*)hTxResult;
458 pTxResult->uInterruptsCounter = 0;