Lines Matching refs:pSession

2837                 NiSession* pSession = NULL;  in gnssNiResponseCommand()  local
2840 pSession = &niData.sessionEs; in gnssNiResponseCommand()
2852 pSession = &niData.session; in gnssNiResponseCommand()
2855 if (pSession) { in gnssNiResponseCommand()
2858 pthread_mutex_lock(&pSession->tLock); in gnssNiResponseCommand()
2859 pSession->resp = mResponse; in gnssNiResponseCommand()
2860 pSession->respRecvd = true; in gnssNiResponseCommand()
2861 pthread_cond_signal(&pSession->tCond); in gnssNiResponseCommand()
2862 pthread_mutex_unlock(&pSession->tLock); in gnssNiResponseCommand()
3606 NiSession* pSession = (NiSession*)args; in niThreadProc() local
3612 pthread_mutex_lock(&pSession->tLock); in niThreadProc()
3615 expire_time.tv_sec = present_time.tv_sec + pSession->respTimeLeft; in niThreadProc()
3618 __func__, (long)expire_time.tv_sec, pSession->respTimeLeft); in niThreadProc()
3620 while (!pSession->respRecvd) { in niThreadProc()
3621 rc = pthread_cond_timedwait(&pSession->tCond, in niThreadProc()
3622 &pSession->tLock, in niThreadProc()
3625 pSession->resp = GNSS_NI_RESPONSE_NO_RESPONSE; in niThreadProc()
3632 "pthread_cond_timedwait = %d pSession->resp is %u", __func__, rc, pSession->resp); in niThreadProc()
3633 pSession->respRecvd = false; /* Reset the user response flag for the next session*/ in niThreadProc()
3638 GnssAdapter* adapter = pSession->adapter; in niThreadProc()
3643 if (NULL != pSession->rawRequest) { in niThreadProc()
3644 if (pSession->resp != GNSS_NI_RESPONSE_IGNORE) { in niThreadProc()
3645 resp = pSession->resp; in niThreadProc()
3646 rawRequest = pSession->rawRequest; in niThreadProc()
3649 free(pSession->rawRequest); in niThreadProc()
3651 pSession->rawRequest = NULL; in niThreadProc()
3653 pthread_mutex_unlock(&pSession->tLock); in niThreadProc()
3655 pSession->respTimeLeft = 0; in niThreadProc()
3656 pSession->reqID = 0; in niThreadProc()
3668 NiSession* pSession = NULL; in requestNiNotify() local
3690 pSession = &mNiData.sessionEs; in requestNiNotify()
3701 pSession = &mNiData.session; in requestNiNotify()
3705 if (pSession) { in requestNiNotify()
3707 pSession->rawRequest = (void*)data; in requestNiNotify()
3708 pSession->reqID = ++mNiData.reqIDCounter; in requestNiNotify()
3709 pSession->adapter = this; in requestNiNotify()
3711 int sessionId = pSession->reqID; in requestNiNotify()
3716 pSession->respTimeLeft = in requestNiNotify()
3720 rc = pthread_create(&pSession->thread, NULL, niThreadProc, pSession); in requestNiNotify()
3724 rc = pthread_detach(pSession->thread); in requestNiNotify()