VOS_VOID NAS_MMC_SndGmmWasSysInfoInd( VOS_UINT32 ulForbiddenFlg, VOS_UINT32 ulUserSrchFlg, struct MsgCB *pstMsg ) { MMCGMM_SYS_INFO_IND_STRU *pstInternalMsg = VOS_NULL_PTR; RRMM_SYS_INFO_IND_STRU *pstRrMmSysInfoInd = VOS_NULL_PTR; pstInternalMsg = (MMCGMM_SYS_INFO_IND_STRU *)NAS_MML_GetIntMsgSendBuf(sizeof(MMCGMM_SYS_INFO_IND_STRU)); if ( VOS_NULL_PTR == pstInternalMsg) { return; } PS_MEM_SET(pstInternalMsg, 0x00, sizeof(MMCGMM_SYS_INFO_IND_STRU)); pstRrMmSysInfoInd = (RRMM_SYS_INFO_IND_STRU *)pstMsg; /* 填充发送消息 */ pstInternalMsg->MsgHeader.ulSenderCpuId = VOS_LOCAL_CPUID; pstInternalMsg->MsgHeader.ulSenderPid = WUEPS_PID_MMC; pstInternalMsg->MsgHeader.ulReceiverCpuId = VOS_LOCAL_CPUID; pstInternalMsg->MsgHeader.ulReceiverPid = WUEPS_PID_GMM; pstInternalMsg->MsgHeader.ulMsgName = MMCGMM_SYS_INFO_IND; pstInternalMsg->MsgHeader.ulLength = sizeof(MMCGMM_SYS_INFO_IND_STRU) - VOS_MSG_HEAD_LENGTH; pstInternalMsg->ulCellId = pstRrMmSysInfoInd->ulCellId; /* 根据系统消息的内容,填充Mask值 */ pstInternalMsg->ulMask = NAS_MMC_GetOptMask_WasSysinfo(pstRrMmSysInfoInd); /* 拷贝Common信息 */ pstInternalMsg->ulCnCommonSize = (VOS_UINT32)pstRrMmSysInfoInd->ucCnCommonSize; PS_MEM_CPY(pstInternalMsg->aucCnCommonInfo, pstRrMmSysInfoInd->aucCnCommonInfo, RRC_NAS_MAX_SIZE_NAS_GSM_MAP); PS_MEM_CPY(pstInternalMsg->aulPsInfo, pstRrMmSysInfoInd->aucPsInfo, RRC_NAS_MAX_SIZE_NAS_GSM_MAP); pstInternalMsg->ulPsInfoSize = (VOS_UINT32)pstRrMmSysInfoInd->ucPsInfoSize; pstInternalMsg->PlmnId.ulMcc = pstRrMmSysInfoInd->PlmnId.ulMcc; pstInternalMsg->PlmnId.ulMnc = pstRrMmSysInfoInd->PlmnId.ulMnc; pstInternalMsg->ulPsDrxLength = pstRrMmSysInfoInd->ulPsDrxLength; pstInternalMsg->ulUserSrchFlg = VOS_FALSE; pstInternalMsg->ulForbiddenMask = ulForbiddenFlg; /* 在Hplmn上CS注册被拒后,非E5时,不在发起注册 ,E5时,HplmnRejlist不记录值 */ if (VOS_TRUE == NAS_MML_ComparePlmnIdWithHplmn(NAS_MML_GetCurrCampPlmnId())) { if (VOS_FALSE == NAS_MMC_GetHPlmnSpecDomainAccessCapa(NAS_MMC_REG_DOMAIN_PS)) { if (MMCMM_NO_FORBIDDEN == ulForbiddenFlg) { pstInternalMsg->ulForbiddenMask = MMCMM_FORBIDDEN_PLMN; } if (VOS_TRUE == NAS_MML_GetHplmnRegisterCtrlFlg()) { pstInternalMsg->ulForbiddenMask &= (~MMCMM_FORBIDDEN_PLMN); } } } /* 从bar转为不bar的标志位 */ pstInternalMsg->ucCsChanged2UnBarFlg = (VOS_UINT8)NAS_MML_GetCsRegisterBarToUnBarFlg(); pstInternalMsg->ucPsChanged2UnBarFlg = (VOS_UINT8)NAS_MML_GetPsRegisterBarToUnBarFlg(); NAS_MML_SndInternalMsg(pstInternalMsg); return; }
VOS_VOID NAS_MMC_SndMmWasSysInfoInd( VOS_UINT32 ulForbiddenFlg, VOS_UINT32 ulUserSpecSrchPlmnFlg, struct MsgCB *pstMsg ) { MMCMM_SYS_INFO_IND_STRU *pstInternalMsg = VOS_NULL_PTR; RRMM_SYS_INFO_IND_STRU *pstRrMmSysInfoInd = VOS_NULL_PTR; pstInternalMsg = (MMCMM_SYS_INFO_IND_STRU *)NAS_MML_GetIntMsgSendBuf(sizeof(MMCMM_SYS_INFO_IND_STRU)); if ( VOS_NULL_PTR == pstInternalMsg) { return; } PS_MEM_SET(pstInternalMsg, 0x00, sizeof(MMCMM_SYS_INFO_IND_STRU)); pstRrMmSysInfoInd = (RRMM_SYS_INFO_IND_STRU *)pstMsg; pstInternalMsg->MsgHeader.ulSenderCpuId = VOS_LOCAL_CPUID; pstInternalMsg->MsgHeader.ulSenderPid = WUEPS_PID_MMC; pstInternalMsg->MsgHeader.ulReceiverCpuId = VOS_LOCAL_CPUID; pstInternalMsg->MsgHeader.ulReceiverPid = WUEPS_PID_MM; pstInternalMsg->MsgHeader.ulMsgName = MMCMM_SYS_INFO_IND; pstInternalMsg->MsgHeader.ulLength = sizeof(MMCMM_SYS_INFO_IND_STRU) - VOS_MSG_HEAD_LENGTH; pstInternalMsg->ulMask = NAS_MMC_GetOptMask_WasSysinfo(pstRrMmSysInfoInd); pstInternalMsg->enSysInfoType = pstRrMmSysInfoInd->enSysInfoType; pstInternalMsg->ucCnCommonSize = pstRrMmSysInfoInd->ucCnCommonSize; /* aucCnCommonInfo[0] 和 aucCnCommonInfo[1] 代表 lac[0] 和 Lac[1]*/ pstInternalMsg->usLac = (VOS_UINT16)pstRrMmSysInfoInd->aucCnCommonInfo[1]; pstInternalMsg->usLac |= (VOS_UINT16)(pstRrMmSysInfoInd->aucCnCommonInfo[0]<< NAS_MML_OCTET_MOVE_EIGHT_BITS); pstInternalMsg->ucCsInfoSize = pstRrMmSysInfoInd->ucCsInfoSize; pstInternalMsg->ucLRTimerT3212 = pstRrMmSysInfoInd->aucCsInfo[0]; /* aucCsInfo[1]的最低Bit代表当前是否允许注册 */ if (0 == (pstRrMmSysInfoInd->aucCsInfo[1] & NAS_MML_ATTATCH_IND_BIT_MASK_WAS_SYS_INFO)) { pstInternalMsg->ucAttachDetach = VOS_FALSE; } else { pstInternalMsg->ucAttachDetach = VOS_TRUE; } pstInternalMsg->ucPsInfoSize = pstRrMmSysInfoInd->ucPsInfoSize; pstInternalMsg->ucRac = pstRrMmSysInfoInd->aucPsInfo[0]; if (0 == (pstRrMmSysInfoInd->aucPsInfo[1] & NAS_MML_NET_MODE_BIT_MASK_WAS_SYS_INFO)) { pstInternalMsg->ucNetworkOperationMode = GRRMM_NW_OP_MODE_I; } else { pstInternalMsg->ucNetworkOperationMode = GRRMM_NW_OP_MODE_II; } if (0 == pstRrMmSysInfoInd->ucPsInfoSize) { pstInternalMsg->ucGprsSupportInd = VOS_FALSE; } else { pstInternalMsg->ucGprsSupportInd = VOS_TRUE; } pstInternalMsg->PlmnId.ulMcc = pstRrMmSysInfoInd->PlmnId.ulMcc; pstInternalMsg->PlmnId.ulMnc = pstRrMmSysInfoInd->PlmnId.ulMnc; pstInternalMsg->ulCsDrxLength = pstRrMmSysInfoInd->ulCsDrxLength; pstInternalMsg->ulPsDrxLength = pstRrMmSysInfoInd->ulPsDrxLength; pstInternalMsg->ulForbiddenFlg = ulForbiddenFlg; /* 删除设置用户指定搜时,将ulForbiddenFlg设置为NULL的处理 */ pstInternalMsg->ulForbiddenFlg = ulForbiddenFlg; /* 在Hplmn上CS注册被拒后,非E5时,不在发起注册 ,E5时,HplmnRejlist不记录值 */ if (VOS_TRUE == NAS_MML_ComparePlmnIdWithHplmn(NAS_MML_GetCurrCampPlmnId())) { if (VOS_FALSE == NAS_MMC_GetHPlmnSpecDomainAccessCapa(NAS_MMC_REG_DOMAIN_CS)) { if (MMCMM_NO_FORBIDDEN == ulForbiddenFlg) { pstInternalMsg->ulForbiddenFlg = MMCMM_FORBIDDEN_PLMN; } if ( VOS_TRUE == NAS_MML_GetHplmnRegisterCtrlFlg()) { pstInternalMsg->ulForbiddenFlg &= (~MMCMM_FORBIDDEN_PLMN); } } } pstInternalMsg->ulCellId = pstRrMmSysInfoInd->ulCellId; pstInternalMsg->ucUserSpecificSearchFlg = (VOS_UINT8)ulUserSpecSrchPlmnFlg; /* 从bar转为不bar的标志位 */ pstInternalMsg->ucCsChanged2UnBarFlg = (VOS_UINT8)NAS_MML_GetCsRegisterBarToUnBarFlg(); pstInternalMsg->ucPsChanged2UnBarFlg = (VOS_UINT8)NAS_MML_GetPsRegisterBarToUnBarFlg(); NAS_MML_SndInternalMsg(pstInternalMsg); return; }