• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

C++ PS_MEM_SET函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了C++中PS_MEM_SET函数的典型用法代码示例。如果您正苦于以下问题:C++ PS_MEM_SET函数的具体用法?C++ PS_MEM_SET怎么用?C++ PS_MEM_SET使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。



在下文中一共展示了PS_MEM_SET函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C++代码示例。

示例1: NAS_UTRANCTRL_InitFsmPlmnSearchCtrlCtx

VOS_VOID  NAS_UTRANCTRL_InitFsmPlmnSearchCtrlCtx(
    NAS_UTRANCTRL_PLMN_SEARCH_CTRL_CTX_STRU       *pstPlmnSearchCtrl
)
{
    /* 初始化搜网控制结构上下文 */
    pstPlmnSearchCtrl->ucSearchedSpecTdMccFlg = VOS_FALSE;

    PS_MEM_SET( pstPlmnSearchCtrl->aucReserve,
                (VOS_UINT8)0x00,
                sizeof(pstPlmnSearchCtrl->aucReserve) );

    return;
}
开发者ID:magnusjjj,项目名称:android_kernel_huawei_rle,代码行数:13,代码来源:NasUtranCtrlCtx.c


示例2: TAF_SPM_SendUsimCallEnvelopeReq_Call

VOS_UINT32  TAF_SPM_SendUsimCallEnvelopeReq_Call(
    VOS_UINT16                          usClientId,
    struct MsgCB                       *pstMsg
)
{
    MN_CALL_CS_DATA_CFG_INFO_STRU       stDataCfgInfo;
    MN_CALL_CALLED_NUM_STRU             stCalledNumber;
#if (FEATURE_ON == FEATURE_IMS)
    VOS_UINT32                          ulEventType;
#endif
    MN_CALL_TYPE_ENUM_U8                enCallType;
    MN_CALL_MODE_ENUM_U8                enCallMode;

    PS_MEM_SET(&stCalledNumber, 0x0, sizeof(stCalledNumber));
    PS_MEM_SET(&stDataCfgInfo, 0x0, sizeof(MN_CALL_CS_DATA_CFG_INFO_STRU));
#if (FEATURE_ON == FEATURE_IMS)
    ulEventType         = TAF_SPM_GetEventTypeFromCurrEntityFsmEntryMsg();
#endif

    /* 由于增强型多方通话已经解析过了,这里不再需要解析  */
#if (FEATURE_ON == FEATURE_IMS)
    if (ulEventType == TAF_BuildEventType(WUEPS_PID_AT, TAF_CALL_APP_ECONF_DIAL_REQ))
    {
        return TAF_SPM_SendUsimEconfEnvelopeReq(usClientId, pstMsg);
    }
    else
#endif
    {
        /* 从消息中获取电话号码相关信息 */
        TAF_SPM_GetCallInfoFromFsmEntryMsg(&stCalledNumber, &enCallType, &enCallMode, (MN_CALL_CS_DATA_CFG_STRU *)&stDataCfgInfo);

        /* 发起检查 */
        return TAF_SPM_SendUsimCallEnvelopeReq(&stCalledNumber,
                                               &stDataCfgInfo,
                                               usClientId,
                                               enCallType,
                                               enCallMode);
    }
}
开发者ID:debbiche,项目名称:android_kernel_huawei_p8,代码行数:39,代码来源:TafSpmSndUsim.c


示例3: AT_InitModemAgpsCtx

VOS_VOID AT_InitModemAgpsCtx(MODEM_ID_ENUM_UINT16 enModemId)
{
    AT_MODEM_AGPS_CTX_STRU             *pstAgpsCtx = VOS_NULL_PTR;

    pstAgpsCtx = AT_GetModemAgpsCtxAddrFromModemId(enModemId);

    PS_MEM_SET(&(pstAgpsCtx->stXml), 0, sizeof(pstAgpsCtx->stXml));

    pstAgpsCtx->enCposrReport = AT_CPOSR_DISABLE;
    pstAgpsCtx->enXcposrReport = AT_XCPOSR_DISABLE;

    return;
}
开发者ID:herryfan,项目名称:kernel-huawei-h60,代码行数:13,代码来源:AtCtx.c


示例4: NAS_UTRANCTRL_InitCustomCfgInfo

VOS_VOID  NAS_UTRANCTRL_InitCustomCfgInfo(
    NAS_UTRANCTRL_CUSTOM_CFG_INFO_STRU   *pstCustomCfg
)
{
    NAS_UTRANCTRL_UTRAN_MODE_AUTO_SWITCH_STRU              *pstUtranModeAutoSwitch;

    pstUtranModeAutoSwitch                      = &(pstCustomCfg->stUtranModeAutoSwitch);

    /* 默认初始化为TDD模式 */
    pstCustomCfg->enCurrUtranMode               = NAS_UTRANCTRL_UTRAN_MODE_TDD;
    pstCustomCfg->enPreUtranMode                = NAS_UTRANCTRL_UTRAN_MODE_BUTT;

    pstCustomCfg->ucIsUtranTddCsSmcNeeded       = VOS_TRUE;
    pstCustomCfg->ucIsUtranTddPsSmcNeeded       = VOS_TRUE;

    pstCustomCfg->enCurUtranSwitchMode          = NAS_UTRANCTRL_UTRAN_SWITCH_MODE_FDD_ONLY;
    pstUtranModeAutoSwitch->ucUtranSwitchMode   = NAS_UTRANCTRL_UTRAN_SWITCH_MODE_FDD_ONLY;

    /* 默认中国网络列表个数为0个 */
    pstUtranModeAutoSwitch->ucTdMccListNum      = 0;

    /* 默认IMSI中的网络列表个数为0个 */
    pstUtranModeAutoSwitch->ucImsiPlmnListNum   = 0;

    /* 初始化保留字段 */
    PS_MEM_SET( pstUtranModeAutoSwitch->aucReserve,
                0,
                sizeof(pstUtranModeAutoSwitch->aucReserve) );

    /* 初始化TD网络国家列表 */
    PS_MEM_SET( pstUtranModeAutoSwitch->aulTdMccList,
                0,
                sizeof(pstUtranModeAutoSwitch->aulTdMccList) );

    /* 初始化IMSI PLMN LIST国家列表 */
    PS_MEM_SET( pstUtranModeAutoSwitch->astImsiPlmnList,
                0,
                sizeof(pstUtranModeAutoSwitch->astImsiPlmnList) );
}
开发者ID:magnusjjj,项目名称:android_kernel_huawei_rle,代码行数:39,代码来源:NasUtranCtrlCtx.c


示例5: NAS_UTRANCTRL_InitCurrFsmCtx

VOS_VOID  NAS_UTRANCTRL_InitCurrFsmCtx(
    NAS_UTRANCTRL_FSM_CTX_STRU         *pstCurrFsmCtx
)
{
    pstCurrFsmCtx->enFsmId                = NAS_UTRANCTRL_FSM_MAIN;
    pstCurrFsmCtx->pstFsmDesc             = NAS_UTRANCTRL_GetMainFsmDescAddr();
    pstCurrFsmCtx->ulState                = NAS_UTRANCTRL_MAIN_STA_INIT;
    pstCurrFsmCtx->stEntryMsg.ulEventType = 0;

    PS_MEM_SET(pstCurrFsmCtx->stEntryMsg.aucEntryMsgBuffer,
               0x00,
               NAS_UTRANCTRL_MAX_MSG_BUFFER_LEN);
}
开发者ID:magnusjjj,项目名称:android_kernel_huawei_rle,代码行数:13,代码来源:NasUtranCtrlCtx.c


示例6: TAF_APS_FindAllDeActIndTearDownPdp

VOS_VOID    TAF_APS_FindAllDeActIndTearDownPdp(
    VOS_UINT8                           ucPdpId,
    TAF_APS_PDPID_LIST_STRU            *pstPdpIdList
)
{

    VOS_UINT8                           i;
    VOS_UINT8                           ucTmpPdpId;
    VOS_UINT32                          ulIpAddrCmpRslt;         /* IP地址比较结果 */
    VOS_UINT32                          ulApnCmpRslt;            /* APN比较结果 */

    i = 0;

    if ( TAF_APS_STA_INACTIVE != TAF_APS_GetPdpIdMainFsmState(ucPdpId) )
    {
        TAF_NORMAL_LOG(WUEPS_PID_TAF,"TAF_APS_FindAllDeActIndTearDownPdp:PDP is already inactive.");
        return;
    }

    /* 清空需要送出的PDP操作列表的变量pstPdpIdList */
    PS_MEM_SET(pstPdpIdList, 0, sizeof(TAF_APS_PDPID_LIST_STRU));

    /* 找出所有需要去激活的PDP ID */
    ucTmpPdpId = 0;
    while(ucTmpPdpId < TAF_APS_MAX_PDPID )
    {
        if ( ucTmpPdpId == APS_FREE_ENTITY_NUM)
        {
            ucTmpPdpId++;
        }

        if ( TAF_APS_STA_INACTIVE != TAF_APS_GetPdpIdMainFsmState(ucTmpPdpId) )
        {
            /*比较ucPdpId和ucTmpPdpId的ADDR和APN是否相同*/
            /*包含TEARDOWN自己的那个PDP*/
            ulIpAddrCmpRslt = Aps_CompAddr(ucPdpId, ucTmpPdpId);
            ulApnCmpRslt    = Aps_CompApn(ucPdpId, ucTmpPdpId);

            if ((APS_ADDR_SAME == ulIpAddrCmpRslt)
                 && (APS_APN_SAME == ulApnCmpRslt))      /*相同*/
            {
                pstPdpIdList[ucPdpId].ucPdpNum++;
                pstPdpIdList[ucPdpId].aucPdpId[i++] = ucTmpPdpId;
            }
        }

        ucTmpPdpId++;
    }

    return;
}
开发者ID:herryfan,项目名称:kernel-huawei-h60,代码行数:51,代码来源:TafApsGetPdpIdList.c


示例7: NAS_PsDomainTcDataReq

VOS_INT32 NAS_PsDomainTcDataReq(
    VOS_UINT8                           ucRbId,
    VOS_UINT32                          ulDataBitLen,
    TTF_MEM_ST                         *pstDataMem
)
{
    RABM_PDCP_TC_DATA_REQ_STRU *pMsg;
    VOS_UINT32                  ulRet;

    if (WUE_RLC_MODE_BUTT == NAS_GetRbTxMode(RRC_NAS_PS_DOMAIN, (VOS_INT8)ucRbId))
    {
        return AS_RB_NO_EXIST;
    }

    pMsg = (RABM_PDCP_TC_DATA_REQ_STRU*)PS_ALLOC_MSG_WITH_HEADER_LEN(
               WUEPS_PID_RABM,sizeof(RABM_PDCP_TC_DATA_REQ_STRU));
    if( VOS_NULL_PTR == pMsg )
    {
        return AS_NO_MEMORY;
    }

    PS_MEM_SET((VOS_INT8*)pMsg + VOS_MSG_HEAD_LENGTH,0,
               sizeof(RABM_PDCP_TC_DATA_REQ_STRU) - VOS_MSG_HEAD_LENGTH);

    pMsg->ulSenderCpuId   = VOS_LOCAL_CPUID;
    pMsg->ulSenderPid     = WUEPS_PID_RABM;
    pMsg->ulReceiverCpuId = VOS_LOCAL_CPUID;
    pMsg->ulReceiverPid   = WUEPS_PID_PDCP;
    pMsg->ulLength        = sizeof(RABM_PDCP_TC_DATA_REQ_STRU) - VOS_MSG_HEAD_LENGTH;

    pMsg->enMsgName       = ID_RABM_PDCP_TC_DATA_REQ;
    pMsg->ucRbId          = ucRbId;
    pMsg->pstDataMem      = pstDataMem;
    pMsg->ulDataBitLen    = ulDataBitLen;

    if (VOS_NULL_PTR == pMsg->pstDataMem)
    {
        /*释放消息结构体*/
        PS_FREE_MSG(WUEPS_PID_RABM, pMsg);

        return AS_NO_MEMORY;
    }

    ulRet = PS_SEND_MSG(WUEPS_PID_RABM, pMsg);
    if ( VOS_OK != ulRet )
    {
        PS_LOG(WUEPS_PID_RABM, 0, PS_PRINT_ERROR,
               "NAS_PsDomainTcDataReq, Error, call PS_SEND_MSG fail\n");
    }
    return AS_SUCCESS;
}
开发者ID:debbiche,项目名称:android_kernel_huawei_p8,代码行数:51,代码来源:asnasapi.c


示例8: NAS_SM_SndRabmBearerActivateInd

VOS_UINT32 NAS_SM_SndRabmBearerActivateInd(
    VOS_UINT8                           ucNsapi,
    NAS_SM_PDP_CONTEXT_INFO_STRU       *pstPdpCtxInfo
)
{
    SM_RABM_BEARER_ACTIVATE_IND_STRU   *pstBearerActivateInd;
    VOS_UINT8                           ucAddrIndex;

    ucAddrIndex = pstPdpCtxInfo->ucAddrIndex;

    /* 构造消息 */
    pstBearerActivateInd = (SM_RABM_BEARER_ACTIVATE_IND_STRU *)PS_ALLOC_MSG_WITH_HEADER_LEN(
                            WUEPS_PID_SM,
                            sizeof(SM_RABM_BEARER_ACTIVATE_IND_STRU));
    if (VOS_NULL_PTR == pstBearerActivateInd)
    {
        NAS_ERROR_LOG(WUEPS_PID_SM,
            "NAS_SM_SndRabmBearerActivateInd: Memory alloc failed.");
        return VOS_ERR;
    }

    /* 初始化消息 */
    PS_MEM_SET((VOS_CHAR*)pstBearerActivateInd + VOS_MSG_HEAD_LENGTH,
               0x00,
               sizeof(SM_RABM_BEARER_ACTIVATE_IND_STRU) - VOS_MSG_HEAD_LENGTH);

    /* 填写消息头 */
    pstBearerActivateInd->stMsgHeader.ulReceiverCpuId = VOS_LOCAL_CPUID;
    pstBearerActivateInd->stMsgHeader.ulReceiverPid   = WUEPS_PID_RABM;
    pstBearerActivateInd->stMsgHeader.ulMsgName       = ID_SM_RABM_BEARER_ACTIVATE_IND;

    /* 填写消息内容 */
    pstBearerActivateInd->ulNsapi         = ucNsapi;
    pstBearerActivateInd->ulLinkdNsapi    = NAS_SM_GetPdpLinkedNsapi(ucAddrIndex);
    pstBearerActivateInd->stQos.ulLength  = pstPdpCtxInfo->QoS.ulQosLength;

    PS_MEM_CPY(pstBearerActivateInd->stQos.aucQosValue,
               pstPdpCtxInfo->QoS.aucQosValue,
               pstPdpCtxInfo->QoS.ulQosLength);

    /* 发送消息 */
    if (VOS_OK != PS_SEND_MSG(WUEPS_PID_SM, pstBearerActivateInd))
    {
        NAS_ERROR_LOG(WUEPS_PID_SM,
            "NAS_SM_SndRabmBearerActivateInd: Send message failed.");
        return VOS_ERR;
    }

    return VOS_OK;

}
开发者ID:herryfan,项目名称:kernel-huawei-h60,代码行数:51,代码来源:NasSmMultiMode.c


示例9: RNIC_WriteIdleTimerOutFile

ssize_t RNIC_WriteIdleTimerOutFile(
    struct file                        *file,
    const char __user                  *buf,
    size_t                              len,
    loff_t                             *ppos
)
{
    RNIC_DIAL_MODE_STRU                *pstDialMode;
    RNIC_DIAL_MODE_STRU                 stDialMode;
    VOS_CHAR                            acIdleTimeTemp[RNIC_IDLETIMEROUT_FILE_LEN];

    PS_MEM_SET(acIdleTimeTemp, 0x00, RNIC_IDLETIMEROUT_FILE_LEN);

    if (len >= RNIC_IDLETIMEROUT_FILE_LEN)
    {
        RNIC_ERROR_LOG1(ACPU_PID_RNIC, "RNIC_WriteIdleTimerOutFile:len is!", len);
        return -ENOSPC;
    }

    /*拷贝用户空间数据到内核空间上面*/
    if (copy_from_user((VOS_VOID *)acIdleTimeTemp, (VOS_VOID *)buf, len) > 0)
    {
        RNIC_ERROR_LOG(ACPU_PID_RNIC, "RNIC_WriteIdleTimerOutFile:copy_from_user ERR!");
        return -EFAULT;
    }

    acIdleTimeTemp[len]= '\0';

    stDialMode.ulIdleTime = RNIC_TransferStringToInt(acIdleTimeTemp);

    /* 获取按需拨号的模式以及时长的地址 */
    pstDialMode                         = RNIC_GetDialModeAddr();

    if (AT_RNIC_DIAL_MODE_DEMAND_DISCONNECT == pstDialMode->enDialMode)
    {

        /* PDP激活,且与上次设置的时长不一致,需要启动拨号断开定时器 */
        if ( pstDialMode->ulIdleTime != stDialMode.ulIdleTime)
        {
            RNIC_StopTimer(TI_RNIC_DEMAND_DIAL_DISCONNECT);
            RNIC_StartTimer(TI_RNIC_DEMAND_DIAL_DISCONNECT, TI_RNIC_DEMAND_DIAL_DISCONNECT_LEN);
        }
    }

    pstDialMode->ulIdleTime             = stDialMode.ulIdleTime;


    RNIC_SendDialInfoMsg(ID_RNIC_MNTN_IDLE_TIMEOUT_INFO);

    return (ssize_t)len;
}
开发者ID:debbiche,项目名称:android_kernel_huawei_p8,代码行数:51,代码来源:RnicDemandDialFileIO.c


示例10: TAF_APS_SaveDsFlowInfoToNv

VOS_VOID  TAF_APS_SaveDsFlowInfoToNv( VOS_VOID )
{
    TAF_APS_DSFLOW_STATS_CTX_STRU      *pstApsDsFlowCtx;
    TAF_APS_DSFLOW_NV_STRU              stApsDsflowNv;
    TAF_DSFLOW_QUERY_INFO_STRU          stDsFlowQryInfo;

    /* 初始化 */
    pstApsDsFlowCtx = TAF_APS_GetDsFlowCtxAddr();
    PS_MEM_SET(&stApsDsflowNv, 0, sizeof(TAF_APS_DSFLOW_NV_STRU));
    PS_MEM_SET(&stDsFlowQryInfo, 0, sizeof(TAF_DSFLOW_QUERY_INFO_STRU));

    if (VOS_TRUE == pstApsDsFlowCtx->ucApsDsFlowSave2NvFlg)
    {

        /* 获取历史流量信息项 */
        TAF_APS_QryAllRabDsFlowStats(&stDsFlowQryInfo);

        /* 刷新流量信息相关NV项 */
        stApsDsflowNv.ulDSLastLinkTime          = stDsFlowQryInfo.stCurrentFlowInfo.ulDSLinkTime;
        stApsDsflowNv.ulDSTotalLinkTime         = stDsFlowQryInfo.stTotalFlowInfo.ulDSLinkTime;
        stApsDsflowNv.ulDSTotalReceiveFluxHigh  = stDsFlowQryInfo.stTotalFlowInfo.ulDSReceiveFluxHigh;
        stApsDsflowNv.ulDSTotalReceiveFluxLow   = stDsFlowQryInfo.stTotalFlowInfo.ulDSReceiveFluxLow;
        stApsDsflowNv.ulDSTotalSendFluxHigh     = stDsFlowQryInfo.stTotalFlowInfo.ulDSSendFluxHigh;
        stApsDsflowNv.ulDSTotalSendFluxLow      = stDsFlowQryInfo.stTotalFlowInfo.ulDSSendFluxLow;

        /* 写NV项 */
        if (NV_OK != NV_Write(en_NV_Item_DSFLOW_REPORT, &stApsDsflowNv, sizeof(TAF_APS_DSFLOW_NV_STRU)))
        {
            TAF_ERROR_LOG(WUEPS_PID_TAF, "TAF_APS_SaveDsFlowInfoToNv: Write NVIM Failed");
        }
    }
    else
    {
        TAF_NORMAL_LOG(WUEPS_PID_TAF, "TAF_APS_SaveDsFlowInfoToNv: Save2NvFlg is not set.");
    }

    return;
}
开发者ID:herryfan,项目名称:kernel-huawei-h60,代码行数:38,代码来源:TafApsProcNvim.c


示例11: MTC_IntrusionEnableB3

VOS_VOID MTC_IntrusionEnableB3(VOS_VOID)
{
    RRC_MTC_MS_BAND_INFO_STRU           stForbiddenBandInfo;

    PS_MEM_SET(&stForbiddenBandInfo, 0, sizeof(stForbiddenBandInfo));

    /* 给GAS接入层发送启用B3指示 */
    if (VOS_TRUE == MTC_IsSupportRatType(MODEM_ID_1, MTC_RATMODE_GSM))
    {
        MTC_SndRrcIntrusionBandSetReq(I1_UEPS_PID_GAS, &stForbiddenBandInfo);
    }

    return;
}
开发者ID:magnusjjj,项目名称:android_kernel_huawei_rle,代码行数:14,代码来源:MtcIntrusion.c


示例12: TAF_SPM_SendImsaSupsCmdReq

VOS_UINT32 TAF_SPM_SendImsaSupsCmdReq(
    MN_CALL_APP_REQ_MSG_STRU           *pstAppMsg
)
{
    SPM_IMSA_CALL_SUPS_CMD_REQ_STRU        *pstSendImsaMsg = VOS_NULL_PTR;

    /* 构造消息 */
    pstSendImsaMsg = (SPM_IMSA_CALL_SUPS_CMD_REQ_STRU *)PS_ALLOC_MSG_WITH_HEADER_LEN(
                                                                WUEPS_PID_TAF,
                                                                sizeof(SPM_IMSA_CALL_SUPS_CMD_REQ_STRU));
    if (VOS_NULL_PTR == pstSendImsaMsg)
    {
        TAF_ERROR_LOG(WUEPS_PID_TAF,
            "TAF_SPM_SendImsaSupsCmdReq: ERROR:Memory Alloc Error for pstMsg!");

        return VOS_FALSE;
    }

    /* 初始化消息 */
    PS_MEM_SET(((VOS_UINT8*)pstSendImsaMsg) + VOS_MSG_HEAD_LENGTH,
               0x00,
               sizeof(SPM_IMSA_CALL_SUPS_CMD_REQ_STRU) - VOS_MSG_HEAD_LENGTH);

    /* 填写消息头 */
    pstSendImsaMsg->ulSenderCpuId               = VOS_LOCAL_CPUID;
    pstSendImsaMsg->ulSenderPid                 = WUEPS_PID_TAF;
    pstSendImsaMsg->ulReceiverCpuId             = VOS_LOCAL_CPUID;
    pstSendImsaMsg->ulReceiverPid               = PS_PID_IMSA;
    pstSendImsaMsg->ulLength                    = sizeof(SPM_IMSA_CALL_SUPS_CMD_REQ_STRU) - VOS_MSG_HEAD_LENGTH;

    /* 填写消息内容 */
    pstSendImsaMsg->ulMsgId                     = ID_SPM_IMSA_CALL_SUPS_CMD_REQ;
    pstSendImsaMsg->usClientId                  = pstAppMsg->clientId;
    pstSendImsaMsg->ucOpId                      = pstAppMsg->opId;

    PS_MEM_CPY(&(pstSendImsaMsg->stCallMgmtCmd),
                &(pstAppMsg->unParm.stCallMgmtCmd),
                sizeof(MN_CALL_SUPS_PARAM_STRU));

    /* 发送消息 */
    if (VOS_OK != PS_SEND_MSG(WUEPS_PID_TAF, pstSendImsaMsg))
    {
        TAF_ERROR_LOG(WUEPS_PID_TAF,
            "TAF_SPM_SendImsaSupsCmdReq: Send message failed.");

        return VOS_FALSE;
    }

    return VOS_TRUE;
}
开发者ID:debbiche,项目名称:android_kernel_huawei_p8,代码行数:50,代码来源:TafSpmSndImsa.c


示例13: TAF_SPM_SendImsaCallAnswerRemoteModifyReq

VOS_UINT32 TAF_SPM_SendImsaCallAnswerRemoteModifyReq(
    MN_CALL_APP_REQ_MSG_STRU           *pstAppMsg
)
{
    SPM_IMSA_CALL_ANSWER_REMOTE_MODIFY_REQ_STRU         *pstSendImsaMsg = VOS_NULL_PTR;

    /* 构造消息 */
    pstSendImsaMsg = (SPM_IMSA_CALL_ANSWER_REMOTE_MODIFY_REQ_STRU *)PS_ALLOC_MSG_WITH_HEADER_LEN(
                                                      WUEPS_PID_TAF,
                                                      sizeof(SPM_IMSA_CALL_ANSWER_REMOTE_MODIFY_REQ_STRU));
    if (VOS_NULL_PTR == pstSendImsaMsg)
    {
        TAF_ERROR_LOG(WUEPS_PID_TAF,
                "TAF_SPM_SendImsaCallAnswerRemoteModifyReq: ERROR:Memory Alloc Error for pstMsg!");

        return VOS_FALSE;
    }

    /* 初始化消息 */
    PS_MEM_SET(((VOS_UINT8 *)pstSendImsaMsg) + VOS_MSG_HEAD_LENGTH,
               0x00,
               (sizeof(SPM_IMSA_CALL_ANSWER_REMOTE_MODIFY_REQ_STRU) - VOS_MSG_HEAD_LENGTH));

    /* 填写消息头 */
    pstSendImsaMsg->ulSenderCpuId       = VOS_LOCAL_CPUID;
    pstSendImsaMsg->ulSenderPid         = WUEPS_PID_TAF;
    pstSendImsaMsg->ulReceiverCpuId     = VOS_LOCAL_CPUID;
    pstSendImsaMsg->ulReceiverPid       = PS_PID_IMSA;
    pstSendImsaMsg->ulLength            = sizeof(SPM_IMSA_CALL_ANSWER_REMOTE_MODIFY_REQ_STRU) - VOS_MSG_HEAD_LENGTH;

    /* 填写消息内容 */
    pstSendImsaMsg->ulMsgId             = ID_SPM_IMSA_CALL_ANSWER_REMOTE_MODIFY_REQ;
    pstSendImsaMsg->usClientId          = pstAppMsg->clientId;
    pstSendImsaMsg->ucOpId              = pstAppMsg->opId;

    pstSendImsaMsg->callId              = pstAppMsg->callId;
    pstSendImsaMsg->enCurrCallType      = pstAppMsg->unParm.stModifyReq.enCurrCallType;
    pstSendImsaMsg->enExpectCallType    = pstAppMsg->unParm.stModifyReq.enExpectCallType;

    /* 发送消息 */
    if (VOS_OK != PS_SEND_MSG(WUEPS_PID_TAF, pstSendImsaMsg))
    {
        TAF_ERROR_LOG(WUEPS_PID_TAF,
                "TAF_SPM_SendImsaCallAnswerRemoteModifyReq: Send message failed.");

        return VOS_FALSE;
    }

    return VOS_TRUE;
}
开发者ID:debbiche,项目名称:android_kernel_huawei_p8,代码行数:50,代码来源:TafSpmSndImsa.c


示例14: NFExt_FlowCtrlInit

VOS_VOID NFExt_FlowCtrlInit(VOS_VOID)
{
    if (NFExt_RegHooks(NF_EXT_DEF_FLOW_CTRL_HOOK_ON_MASK))
    {
        vos_printf("NFExt_FlowCtrlInit NFExt_RegHooks fail");

        return;
    }

    g_stExFlowCtrlEntity.ulFlowCtrlMsk = 0;
    g_stExFlowCtrlEntity.pstBrDev      = NULL;

    PS_MEM_SET(g_stExFlowCtrlEntity.aulTxBytesCnt, 0, sizeof(g_stExFlowCtrlEntity.aulTxBytesCnt));
}
开发者ID:herryfan,项目名称:kernel-huawei-h60,代码行数:14,代码来源:NetfilterExCtrl.c


示例15: TAF_MMA_ReadSimLockPlmnNvim

VOS_VOID  TAF_MMA_ReadSimLockPlmnNvim( VOS_VOID )
{
    TAF_CUSTOM_SIM_LOCK_PLMN_INFO_STRU          stSimLockPlmnInfo;
    VOS_UINT32                                  ulResult;

    PS_MEM_SET(&stSimLockPlmnInfo, 0x00, sizeof(stSimLockPlmnInfo));

    ulResult = NV_Read(en_NV_Item_CustomizeSimLockPlmnInfo,
                       &stSimLockPlmnInfo,
                       sizeof(stSimLockPlmnInfo));
    if (NV_OK != ulResult)
    {
        g_MmaNewValue.stSimLockPlmnInfo.ulStatus = VOS_FALSE;
        PS_MEM_SET(g_MmaNewValue.stSimLockPlmnInfo.astSimLockPlmnRange, (VOS_CHAR)0xaa,
                       sizeof(g_MmaNewValue.stSimLockPlmnInfo.astSimLockPlmnRange));
    }
    else
    {
        g_MmaNewValue.stSimLockPlmnInfo = stSimLockPlmnInfo;
    }

    return;
}
开发者ID:debbiche,项目名称:android_kernel_huawei_p8,代码行数:23,代码来源:TafMmaProcNvim.c


示例16: TAF_SPM_SendImsaEconfDialReq

VOS_UINT32 TAF_SPM_SendImsaEconfDialReq(
    MN_CALL_APP_REQ_MSG_STRU           *pstAppMsg
)
{
    SPM_IMSA_CALL_ECONF_DIAL_REQ_STRU  *pstSendImsaMsg = VOS_NULL_PTR;
    VOS_UINT32                          ulMsgLen;

    ulMsgLen       = sizeof(SPM_IMSA_CALL_ECONF_DIAL_REQ_STRU);

    /* 构造消息 */
    pstSendImsaMsg = (SPM_IMSA_CALL_ECONF_DIAL_REQ_STRU *)PS_ALLOC_MSG_WITH_HEADER_LEN(
                                                          WUEPS_PID_TAF,
                                                          ulMsgLen);
    if (VOS_NULL_PTR == pstSendImsaMsg)
    {
        TAF_ERROR_LOG(WUEPS_PID_TAF,
                "TAF_SPM_SendImsaEconfDialReq: ERROR:Memory Alloc Error for pstMsg!");

        return VOS_FALSE;
    }

    /* 初始化消息 */
    PS_MEM_SET(((VOS_UINT8 *)pstSendImsaMsg) + VOS_MSG_HEAD_LENGTH,
               0x00,
               (ulMsgLen - VOS_MSG_HEAD_LENGTH));

    /* 填写消息头 */
    pstSendImsaMsg->ulSenderCpuId       = VOS_LOCAL_CPUID;
    pstSendImsaMsg->ulSenderPid         = WUEPS_PID_TAF;
    pstSendImsaMsg->ulReceiverCpuId     = VOS_LOCAL_CPUID;
    pstSendImsaMsg->ulReceiverPid       = PS_PID_IMSA;
    pstSendImsaMsg->ulLength            = ulMsgLen - VOS_MSG_HEAD_LENGTH;

    /* 填写消息内容 */
    pstSendImsaMsg->ulMsgId             = ID_SPM_IMSA_CALL_ECONF_DIAL_REQ;
    pstSendImsaMsg->usClientId          = pstAppMsg->clientId;
    pstSendImsaMsg->ucOpId              = pstAppMsg->opId;
    pstSendImsaMsg->stDialReq           = pstAppMsg->unParm.stEconfDial;

    /* 发送消息 */
    if (VOS_OK != PS_SEND_MSG(WUEPS_PID_TAF, pstSendImsaMsg))
    {
        TAF_ERROR_LOG(WUEPS_PID_TAF,
                "TAF_SPM_SendImsaEconfDialReq: Send message failed.");

        return VOS_FALSE;
    }

    return VOS_TRUE;
}
开发者ID:debbiche,项目名称:android_kernel_huawei_p8,代码行数:50,代码来源:TafSpmSndImsa.c


示例17: TAF_APS_SndL4aPppDialReq

VOS_UINT32 TAF_APS_SndL4aPppDialReq(
    TAF_PS_PPP_DIAL_ORIG_REQ_STRU      *pstPppDialOrigReq,
    TAF_APS_AUTH_INFO_STRU             *pstAuthInfo,
    TAF_APS_IPCP_INFO_STRU             *pstIpcpInfo
)
{
    APS_L4A_PPP_DIAL_REQ_STRU          *pstPppDialReq;

    /* 构造消息 */
    pstPppDialReq = (APS_L4A_PPP_DIAL_REQ_STRU*)PS_ALLOC_MSG_WITH_HEADER_LEN(
                            WUEPS_PID_TAF,
                            sizeof(APS_L4A_PPP_DIAL_REQ_STRU));
    if (VOS_NULL_PTR == pstPppDialReq)
    {
        TAF_ERROR_LOG(WUEPS_PID_TAF, "TAF_APS_SndL4aPppDialReq: Memory alloc failed.");
        return VOS_ERR;
    }

    /* 初始化消息 */
    PS_MEM_SET((VOS_CHAR*)pstPppDialReq + VOS_MSG_HEAD_LENGTH,
                0x00,
                (sizeof(APS_L4A_PPP_DIAL_REQ_STRU) - VOS_MSG_HEAD_LENGTH));

    /* 填写消息头 */
    pstPppDialReq->ulReceiverCpuId         = VOS_LOCAL_CPUID;
    pstPppDialReq->ulReceiverPid           = MSP_L4_L4A_PID;
    pstPppDialReq->enMsgId                 = ID_APS_L4A_PPP_DIAL_REQ;

    /* 填写消息内容 */
    pstPppDialReq->stAppCtrl.ulPid         = WUEPS_PID_TAF;
    pstPppDialReq->stAppCtrl.ulClientId    = pstPppDialOrigReq->stCtrl.usClientId;
    pstPppDialReq->stAppCtrl.ulOpId        = pstPppDialOrigReq->stCtrl.ucOpId;
    pstPppDialReq->ulCid                   = pstPppDialOrigReq->stPppDialParaInfo.ucCid;

    PS_MEM_CPY((VOS_UINT8*)(&pstPppDialReq->stPppInfo.stAuthInfo),
               (VOS_UINT8*)(pstAuthInfo),
               sizeof(TAF_APS_AUTH_INFO_STRU));

    PS_MEM_CPY((VOS_UINT8*)(&pstPppDialReq->stPppInfo.stIpcpInfo),
               (VOS_UINT8*)(pstIpcpInfo),
               sizeof(TAF_APS_IPCP_INFO_STRU));

    /* 发送消息 */
    if (VOS_OK != PS_SEND_MSG(WUEPS_PID_TAF, pstPppDialReq))
    {
        TAF_WARNING_LOG(WUEPS_PID_TAF, "TAF_APS_SndL4aPppDialReq():WARNING:SEND MSG FIAL");
    }
    return VOS_OK;

}
开发者ID:debbiche,项目名称:android_kernel_huawei_p8,代码行数:50,代码来源:TafApsSndL4a.c


示例18: MN_FillAndSndAppReqMsg

/*****************************************************************************
 函 数 名  : MN_FillAndSndAppReqMsg
 功能描述  :
 输入参数  : MN_CLIENT_ID_T      ClientId
             MN_OPERATION_ID_T             OpId
             VOS_UINT16   usMsgType
             VOS_VOID  *pPara
             VOS_UINT32 ulParaLen
             VOS_UINT32 ulReceiverPid
 输出参数  : 无
 返 回 值  : VOS_UINT32
 调用函数  :
 被调函数  :

 修改历史      :
  1.日    期   : 2008年7月22日
    作    者   : luojian id:107747
    修改内容   : 新生成函数

*****************************************************************************/
VOS_UINT32  MN_FillAndSndAppReqMsg(
    MN_CLIENT_ID_T                      ClientId,
    MN_OPERATION_ID_T                   OpId,
    VOS_UINT16                          usMsgType,
    VOS_VOID                            *pPara,
    VOS_UINT32                          ulParaLen,
    VOS_UINT32                          ulReceiverPid
)
{
    VOS_UINT8                          *pMsg;
    VOS_UINT32                          ulRet;
    VOS_UINT32                          ulMsgLen;
    VOS_UINT8                          *pMsgPara;

    if ((VOS_NULL_PTR == pPara) && (0 < ulParaLen))
    {
        return TAF_FAILURE;
    }

    pMsgPara = (VOS_UINT8 *)pPara;

    /* 获取消息长度 */
    MN_GetAppReqMsgLen( ulParaLen, &ulMsgLen);

    /* 申请消息 */
    pMsg = (VOS_UINT8 *)PS_ALLOC_MSG(WUEPS_PID_AT, ulMsgLen - VOS_MSG_HEAD_LENGTH);

    if (VOS_NULL_PTR == pMsg)
    {
        return TAF_FAILURE;
    }

    PS_MEM_SET( (pMsg + VOS_MSG_HEAD_LENGTH), 0, (ulMsgLen - VOS_MSG_HEAD_LENGTH));

    /* 填充消息头 */
    MN_FillAppReqMsgHeader((MN_APP_REQ_MSG_STRU *)pMsg, ClientId, OpId, usMsgType, ulReceiverPid );

    /* 填充消息参数 */
    MN_FillAppReqMsgPara( &pMsg[sizeof(MN_APP_REQ_MSG_STRU) - 4], pMsgPara, ulParaLen );

    ulRet = PS_SEND_MSG(WUEPS_PID_AT, pMsg);

    if (VOS_OK != ulRet)
    {
        return TAF_FAILURE;
    }

    return TAF_SUCCESS;
}
开发者ID:CM13-HI6210SFT,项目名称:huawei_kernel_3.10.71_hi6210sft,代码行数:69,代码来源:MnCommApi.c


示例19: MTC_DEBUG_TraceNotchInfo

VOS_VOID MTC_DEBUG_TraceNotchInfo(VOS_VOID)
{
    MTC_MSG_BUF_STRU                   *pstBufAddr          = VOS_NULL_PTR;
    RRC_MTC_MS_BAND_INFO_STRU          *pstBandInfo         = VOS_NULL_PTR;
    RRC_MTC_MS_BAND_INFO_STRU          *pstNcellBandInfo    = VOS_NULL_PTR;
    MTC_DEBUG_ALL_MODEM_NOTCH_INFO_STRU stDebugNotchInfo;
    MODEM_ID_ENUM_UINT16                enModemId;

    PS_MEM_SET(&stDebugNotchInfo, 0x0, sizeof(MTC_DEBUG_ALL_MODEM_NOTCH_INFO_STRU));

    /*  填写消息头 */
    MTC_DEBUG_CFG_MSG_HDR(&stDebugNotchInfo.stMsgHeader,
                            UEPS_PID_MTC, UEPS_PID_MTC,
                            sizeof(MTC_DEBUG_ALL_MODEM_NOTCH_INFO_STRU) - VOS_MSG_HEAD_LENGTH);

    stDebugNotchInfo.stMsgHeader.ulMsgName  = ID_DEBUG_MTC_NOTCH_INFO;

    for (enModemId = 0; enModemId < MODEM_ID_BUTT; enModemId++)
    {
        pstBufAddr          = MTC_GetBufAddr(enModemId);
        pstBandInfo         = MTC_GetModemCurBandInfo(enModemId);
        pstNcellBandInfo    = MTC_GetModemNCellBandInfo(enModemId);

        PS_MEM_CPY(&stDebugNotchInfo.stModemNotchInfo[enModemId].stModemBandInfo, pstBandInfo, sizeof(RRC_MTC_MS_BAND_INFO_STRU));
        PS_MEM_CPY(&stDebugNotchInfo.stModemNotchInfo[enModemId].stModemBufInfo.stBufBandInfo.stModemBandInfo,
                   &pstBufAddr->stBufBandInfoMsg.stIntrusionBandInfoMsg.stCurBandInfo,
                   sizeof(RRC_MTC_MS_BAND_INFO_STRU));
        PS_MEM_CPY(&stDebugNotchInfo.stModemNotchInfo[enModemId].stModemBufInfo.stBufNCellFreqInfo.stLteNcellFreqInfo,
                   &pstBufAddr->stBufUsingFreqInfoMsg.stUsingFreqInfoMsg.stLteFreqInfo,
                   sizeof(RRC_MTC_LTE_NCELL_INFO_STRU));

        PS_MEM_CPY(&stDebugNotchInfo.stModemNotchInfo[enModemId].stModemBufInfo.stBufNCellFreqInfo.stTdsNcellFreqInfo,
                   &pstBufAddr->stBufUsingFreqInfoMsg.stUsingFreqInfoMsg.stTdsFreqInfo,
                   sizeof(RRC_MTC_TDS_NCELL_INFO_STRU));

        stDebugNotchInfo.stModemNotchInfo[enModemId].stModemBufInfo.stBufNCellFreqInfo.ucBufNcellBandFlag  = pstBufAddr->stBufUsingFreqInfoMsg.enExitBufMsgFlag;
        stDebugNotchInfo.stModemNotchInfo[enModemId].stModemBufInfo.stBufNCellFreqInfo.ulSndPid            = pstBufAddr->stBufUsingFreqInfoMsg.stUsingFreqInfoMsg.stMsgHeader.ulSenderPid;
        stDebugNotchInfo.stModemNotchInfo[enModemId].stModemBufInfo.stBufBandInfo.ucBufBandInfoFlag        = pstBufAddr->stBufBandInfoMsg.enExitBufMsgFlag;
        stDebugNotchInfo.stModemNotchInfo[enModemId].stModemBufInfo.stBufBandInfo.ulSndPid                 = pstBufAddr->stBufBandInfoMsg.stIntrusionBandInfoMsg.stMsgHeader.ulSenderPid;

        PS_MEM_CPY(&stDebugNotchInfo.stModemNotchInfo[enModemId].stModemNcellBandInfo, pstNcellBandInfo,sizeof(RRC_MTC_MS_BAND_INFO_STRU));
    }

    /* 发送消息 */
    MTC_DEBUG_TraceEvent(&stDebugNotchInfo);

    return;

}
开发者ID:XePeleato,项目名称:android_kernel_huawei_venus,代码行数:49,代码来源:MtcDebug.c


示例20: TAF_MMA_ReadLcCtrlNvim

VOS_VOID TAF_MMA_ReadLcCtrlNvim( VOS_VOID )
{
    TAF_SDC_LC_CONFIG_PARA_STRU        *pstLcConfigInfo = VOS_NULL_PTR;
    TAF_NV_LC_CTRL_PARA_STRU            stLcCtrlInfo;
    VOS_UINT32                          ulResult;
    VOS_UINT32                          ulLength;

    pstLcConfigInfo = TAF_SDC_GetLcConfigPara();

    PS_MEM_SET(&stLcCtrlInfo, 0x00, sizeof(TAF_NV_LC_CTRL_PARA_STRU));

    NV_GetLength(en_NV_Item_LC_Ctrl_PARA, &ulLength);

    ulResult = NV_Read(en_NV_Item_LC_Ctrl_PARA,
                       &stLcCtrlInfo,
                       ulLength);

    if (NV_OK != ulResult)
    {
        return;
    }

    /* NV 内容异常检测,如果内容异常,则不修改当前LC值 */
    if ( (VOS_TRUE                      != stLcCtrlInfo.ucLCEnableFlg)
      && (VOS_FALSE                     != stLcCtrlInfo.ucLCEnableFlg) )
    {
        return;
    }

    if ( (TAF_NVIM_LC_RAT_COMBINED_GUL  != stLcCtrlInfo.enRatCombined)
      && (TAF_NVIM_LC_RAT_COMBINED_CL   != stLcCtrlInfo.enRatCombined)
      && (TAF_NVIM_LC_RAT_COMBINED_BUTT != stLcCtrlInfo.enRatCombined))
    {
        return;
    }

    if ( (TAF_NVIM_LC_INDEPENT_WORK     != stLcCtrlInfo.enLCWorkCfg)
      && (TAF_NVIM_LC_INTER_WORK        != stLcCtrlInfo.enLCWorkCfg)
      && (TAF_NVIM_LC_WORK_CFG_BUTT     != stLcCtrlInfo.enLCWorkCfg) )
    {
        return;
    }

    pstLcConfigInfo->ucLCEnableFlg = stLcCtrlInfo.ucLCEnableFlg;
    pstLcConfigInfo->enRatCombined = stLcCtrlInfo.enRatCombined;
    pstLcConfigInfo->enLCWorkCfg   = stLcCtrlInfo.enLCWorkCfg;

    return;
}
开发者ID:debbiche,项目名称:android_kernel_huawei_p8,代码行数:49,代码来源:TafMmaProcNvim.c



注:本文中的PS_MEM_SET函数示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C++ PS_ReadToken函数代码示例发布时间:2022-05-30
下一篇:
C++ PS_MEM_FREE函数代码示例发布时间:2022-05-30
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap