亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關(guān)于我們
? 蟲蟲下載站

?? zl5011xtm.c

?? Zalink50114----TDMoIP芯片驅(qū)動(dòng)源碼
?? C
?? 第 1 頁 / 共 4 頁
字號(hào):
   zlStatusE

 Remarks:
   Using magic numbers for the bit positions in the TM buffer, since the bit
   positions are unique to this function.

*******************************************************************************/

zlStatusE zl5011xTmDecodeTraceSource(zl5011xParamsS *zl5011xParams,
      Uint32T *buffer, zl5011xTmTraceMessageS *msg)
{
   zlStatusE status = ZL5011X_OK;

   ZL5011X_TRACE(ZL5011X_TM_FN_ID, "zl5011xTmDecodeTraceSource:", 0, 0, 0, 0, 0, 0);

   /* decode the first 32 bit word of the message */
   msg->headGranule = (buffer[0] >> 0) & 0x3ffff;
   msg->sourceBlock = (Uint8T)((buffer[0] >> 22) & 0x1f);
   msg->flowType = (zl5011xFlowTypeE)((buffer[0] >> 27) & 0x1f);

   /* any fields not populated are set to invalid */
   msg->timestamp = (Uint16T)ZL5011X_INVALID;
   msg->headerOffset = (Uint8T)ZL5011X_INVALID;
   msg->mpid = (Uint16T)ZL5011X_INVALID;
   msg->pktLen = (Uint16T)ZL5011X_INVALID;
   msg->tailGranule = (Uint32T)ZL5011X_INVALID;
   msg->granuleNum = (Uint8T)ZL5011X_INVALID;
   msg->miscField1 = (Uint16T)ZL5011X_INVALID;
   msg->miscField2 = (Uint32T)ZL5011X_INVALID;

   return(status);
}

/*******************************************************************************

 Function:
   zl5011xTmGetTraceMessage

 Description:
   Reads the contents of the trace buffer identified by index. The trace message
   structure is populated depending on the trace mode in use.

   For SHORT trace modes, only one 32 bit word is used for each message in the
   trace buffer, so the number of buffers available is equal to the size of the
   trace buffer.

   For PARTIAL trace, two 32 bit words are used for each message in the
   trace buffer, so the number of buffers available is half the size of the
   trace buffer.

   For FULL trace, four 32 bit words are used for each message in the
   trace buffer, so the number of buffers available is a quarter the size of the
   trace buffer.

 Inputs:
   zl5011xParams   Pointer to the structure for this device instance
   index          which entry in the trace buffer to fetch

 Outputs:
    msg           structure populated with the trace message - fields populated
                  will depend on the trace mode in operation. Unused fields will
                  be set to all 1's

 Returns:
   zlStatusE

 Remarks:
    None

*******************************************************************************/

zlStatusE zl5011xTmGetTraceMessage(zl5011xParamsS *zl5011xParams,
      Uint32T index, zl5011xTmTraceMessageS *msg)
{
   Uint32T readValue[4], loop, offset = 0;
   zlStatusE status = ZL5011X_OK;

   ZL5011X_TRACE(ZL5011X_TM_FN_ID, "zl5011xTmGetTraceMessage: index %4d",
         index, 0, 0, 0, 0, 0);

   if (msg == NULL)
   {
      status = ZL5011X_PARAMETER_INVALID;
   }

   if (status == ZL5011X_OK)
   {
      if (index > (ZL5011X_TM_TRACE_BUFFER_SIZE / zl5011xParams->taskManager.tmBufferSize))
      {
         status = ZL5011X_PARAMETER_INVALID;
      }
      else
      {
         offset = index * zl5011xParams->taskManager.tmBufferSize * sizeof(Uint32T);
      }
   }

   /* read the 32 bit words from the trace buffer that make up the
      message */
   for (loop = 0; loop < zl5011xParams->taskManager.tmBufferSize; loop++)
   {
      if (status != ZL5011X_OK)
      {
         break;
      }

      status = zl5011xRead(zl5011xParams,
            ZL5011X_TM_TRACE_BUFFER + offset + (loop * sizeof(Uint32T)),
            readValue + loop);
   }

   if (status == ZL5011X_OK)
   {
      /* populate the statistics structure using the values read from the
         device */
      switch (zl5011xParams->taskManager.tmTraceMode)
      {
         case ZL5011X_TM_TRACE_FULL :
            status = zl5011xTmDecodeTraceFull(zl5011xParams, readValue, msg);
            break;

         case ZL5011X_TM_TRACE_PARTIAL :
            status = zl5011xTmDecodeTracePartial(zl5011xParams, readValue, msg);
            break;

         case ZL5011X_TM_TRACE_SHORT_TIME :
            status = zl5011xTmDecodeTraceTime(zl5011xParams, readValue, msg);
            break;

         case ZL5011X_TM_TRACE_SHORT_SOURCE :
            status = zl5011xTmDecodeTraceSource(zl5011xParams, readValue, msg);
            break;

         default :
            status = ZL5011X_PARAMETER_INVALID;
            break;
      }
   }

   return(status);
}

/*******************************************************************************

 Function:
   zl5011xTmDumpTraceMessage

 Description:
   Displays the contents of the trace buffer identified by index using the OS
   log message function.

 Inputs:
   zl5011xParams   Pointer to the structure for this device instance
   index          which entry in the trace buffer to display

 Outputs:
   None

 Returns:
   zlStatusE

 Remarks:
   None

*******************************************************************************/

zlStatusE zl5011xTmDumpTraceMessage(zl5011xParamsS *zl5011xParams,
      Uint32T index)
{
   zl5011xTmTraceMessageS msg;
   zlStatusE status = ZL5011X_OK;

   ZL5011X_TRACE(ZL5011X_TM_FN_ID, "zl5011xTmDumpTraceMessage: index %4d", index, 0, 0, 0, 0, 0);

   status = zl5011xTmGetTraceMessage(zl5011xParams, index, &msg);

   if (status == ZL5011X_OK)
   {
      OS_LOG_MSG("TM buffer %4d" ZL5011X_NEWLINE
            "flow   %02X,       length        %04X, mpid         %04X" ZL5011X_NEWLINE,
            index, msg.flowType, msg.pktLen, msg.mpid, 0, 0);

      OS_LOG_MSG("block  %02X,       header offset %02X,   head granule %08X" ZL5011X_NEWLINE,
            msg.sourceBlock, msg.headerOffset, msg.headGranule, 0, 0, 0);

      OS_LOG_MSG("misc 1 %04X,     granule count %02X,   tail granule %08X" ZL5011X_NEWLINE,
            msg.miscField1, msg.granuleNum, msg.tailGranule, 0, 0, 0);

      OS_LOG_MSG("misc 2 %08X, timestamp     %04X" ZL5011X_NEWLINE,
            msg.miscField2, msg.timestamp, 0, 0, 0, 0);
   }

   return(status);
}

/*******************************************************************************

 Function:
   zl5011xTmEnableInterrupts

 Description:

 Inputs:
   zl5011xParams   Pointer to the structure for this device instance
   interruptBits  a ONE to enable the interrupt

 Outputs:
   None

 Returns:
   zlStatusE

 Remarks:
   None

*******************************************************************************/

zlStatusE zl5011xTmEnableInterrupts(zl5011xParamsS *zl5011xParams,
      Uint32T interruptBits)
{
   zlStatusE status = ZL5011X_OK;
   Uint32T regBits=0;

   ZL5011X_TRACE(ZL5011X_TM_FN_ID, "zl5011xTmEnableInterrupts: index %4d",
               interruptBits, 0, 0, 0, 0, 0);

   status = zl5011xTmClearInterrupts(zl5011xParams, interruptBits);

   if( status== ZL5011X_OK)
   {
      status = zl5011xRead(zl5011xParams, ZL5011X_TM_INTERRUPT_MASK, &regBits);
   }

   /* write ONES to the mask reg  */
   if( status== ZL5011X_OK)
   {
      regBits |= interruptBits;
      status = zl5011xWrite(zl5011xParams, ZL5011X_TM_INTERRUPT_MASK, regBits);
   }

   /* store value in the structure  */
   if( status== ZL5011X_OK)
   {
      zl5011xParams->interruptMasks.tmInterruptsEnabled= regBits;
   }

   return(status);
}

/*******************************************************************************

 Function:
   zl5011xTmDisableInterrupts

 Description:
   writes to the the TM intr mask reg  to disable interrupts
 Inputs:
   zl5011xParams   Pointer to the structure for this device instance
   interruptBits  a ONE to disable the interrupt

 Outputs:
   None

 Returns:
   zlStatusE

 Remarks:
   None

*******************************************************************************/

zlStatusE zl5011xTmDisableInterrupts(zl5011xParamsS *zl5011xParams,
      Uint32T interruptBits)
{
   zlStatusE status = ZL5011X_OK;
   Uint32T regBits=0;

   ZL5011X_TRACE(ZL5011X_TM_FN_ID, "zl5011xTmDisableInterrupts: index %4d",
               interruptBits, 0, 0, 0, 0, 0);

   status = zl5011xRead(zl5011xParams, ZL5011X_TM_INTERRUPT_MASK, &regBits);

   /* write ZEROS to the mask reg (0 = Mask on (disable interrupt)) */
   if( status== ZL5011X_OK)
   {
      regBits &= ~interruptBits;
      status = zl5011xWrite(zl5011xParams, ZL5011X_TM_INTERRUPT_MASK, regBits);
   }

   /* store value in the structure  */
   if( status== ZL5011X_OK)
   {
      zl5011xParams->interruptMasks.tmInterruptsEnabled= regBits;
   }


   return(status);
}

/*******************************************************************************

 Function:
    zl5011xTmGetInterruptStatus

 Description:
   This function reads back the  interrupt status register

 Inputs:
    zl5011xParams      Pointer to the structure for this device instance

 Outputs:
    pIntrStatus      the state of the interrupt register

 Returns:
    zlStatusE

 Remarks:

*******************************************************************************/

zlStatusE zl5011xTmGetInterruptStatus(zl5011xParamsS *zl5011xParams,
      Uint32T *pIntrStatus)
{
   zlStatusE status = ZL5011X_OK;

   ZL5011X_TRACE(ZL5011X_TM_FN_ID, "zl5011xTmGetInterruptStatus:",0, 0, 0, 0, 0, 0);

   if (status == ZL5011X_OK)
   {
      status = zl5011xRead(zl5011xParams, ZL5011X_TM_INTERRUPT_STATUS, pIntrStatus);

      ZL5011X_TRACE(ZL5011X_TM_FN_ID, "zl5011xTmGetInterruptStatus: %08X",
            *pIntrStatus, 0, 0, 0, 0, 0);
   }

   return status;
}

/*******************************************************************************

 Function:
    zl5011xTmClearInterrupts

 Description:
    Set a bit to 1 to clear the interrupt.

 Inputs:
    zl5011xParams     Pointer to the structure for this device instance
    interruptBits    interrupts to clear

 Outputs:

 Returns:
    zlStatusE

 Remarks:

*******************************************************************************/

zlStatusE zl5011xTmClearInterrupts(zl5011xParamsS *zl5011xParams, Uint32T interruptBits)
{
   zlStatusE status = ZL5011X_OK;

   ZL5011X_TRACE(ZL5011X_TM_FN_ID,
          "zl5011xTmClearInterrupts: bits %08X",
          interruptBits, 0, 0, 0, 0, 0);

   /* write a 1 to the interrupt source to clear the interrupt */
   if( status== ZL5011X_OK)
   {
      status = zl5011xWrite(zl5011xParams, ZL5011X_TM_INTERRUPT_CLEAR, interruptBits);
   }

   return(status);
}

?? 快捷鍵說明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號(hào) Ctrl + =
減小字號(hào) Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
欧美视频在线播放| 一区二区三区四区精品在线视频| 欧美精品乱人伦久久久久久| 色综合欧美在线| 99r精品视频| 91香蕉视频mp4| 99久久99久久久精品齐齐| av在线播放一区二区三区| 成人福利视频网站| 春色校园综合激情亚洲| 国产高清精品久久久久| 国产成人综合网| caoporn国产精品| 欧洲精品在线观看| 欧美日韩国产精选| 欧美电影在哪看比较好| 日韩欧美一区二区免费| 欧美不卡123| 国产精品欧美一级免费| 亚洲图片你懂的| 午夜欧美2019年伦理| 欧美aaaaa成人免费观看视频| 精品亚洲国内自在自线福利| 国产精品18久久久久久久久久久久 | 日韩精品影音先锋| 精品国产电影一区二区| 国产日本一区二区| 亚洲免费观看高清完整版在线观看熊| 玉足女爽爽91| 秋霞电影网一区二区| 国产曰批免费观看久久久| 丁香六月久久综合狠狠色| 91视频.com| 91精品国产福利在线观看| 精品福利一二区| 国产精品蜜臀av| 亚洲午夜免费视频| 精品系列免费在线观看| 成人午夜短视频| 欧美私人免费视频| 久久精品一区四区| 亚洲男人的天堂在线aⅴ视频| 午夜一区二区三区视频| 国产一区在线看| 色综合天天综合网国产成人综合天| 欧美美女一区二区在线观看| 国产日本欧美一区二区| 亚洲第一综合色| 国产精品羞羞答答xxdd| 欧美日韩成人高清| 国产欧美一区二区三区鸳鸯浴| 亚洲电影视频在线| 国产白丝精品91爽爽久久| 欧美日韩一级二级三级| 亚洲国产成人午夜在线一区| 亚洲午夜一二三区视频| 国产69精品久久777的优势| 337p亚洲精品色噜噜噜| 亚洲欧洲成人av每日更新| 免费观看在线综合色| 色综合久久综合| 国产三级一区二区| 日韩国产成人精品| 日本大香伊一区二区三区| 国产女主播在线一区二区| 日韩av电影天堂| 欧美性极品少妇| 国产精品伦理一区二区| 美国三级日本三级久久99| 在线免费视频一区二区| 国产蜜臀av在线一区二区三区| 日韩高清不卡一区二区三区| 91丝袜呻吟高潮美腿白嫩在线观看| 日韩美女视频在线| 亚洲成a人片在线观看中文| 成人av小说网| 久久精品免视看| 久久精品国产免费| 欧美日韩不卡视频| 亚洲码国产岛国毛片在线| 成人综合日日夜夜| 久久这里只有精品视频网| 日本不卡高清视频| 欧美色视频在线| 一区二区三区久久久| av资源网一区| 亚洲国产精品成人综合| 国产精品一区一区| 精品91自产拍在线观看一区| 日本中文在线一区| 欧美一区二区在线免费播放| 亚洲二区视频在线| 欧美亚洲一区三区| 亚洲综合久久久久| 在线免费观看一区| 一区二区三区在线视频观看58| 91视频免费观看| 亚洲蜜桃精久久久久久久| 91小视频在线免费看| 亚洲三级电影网站| 欧美中文字幕久久| 亚洲在线观看免费| 欧美日韩激情一区二区三区| 亚洲国产三级在线| 欧美精品三级日韩久久| 日本中文字幕一区二区视频| 日韩欧美的一区| 久草在线在线精品观看| www国产精品av| 国产精品亚洲一区二区三区妖精| 国产日韩三级在线| 成人avav在线| 一区二区三区免费| 7777女厕盗摄久久久| 免费欧美高清视频| 精品国产91洋老外米糕| 国产91精品露脸国语对白| 国产精品乱码久久久久久| 91日韩精品一区| 日日摸夜夜添夜夜添亚洲女人| 日韩午夜激情免费电影| 国产美女娇喘av呻吟久久| 国产精品理论在线观看| 91视频免费播放| 午夜欧美2019年伦理| 精品国免费一区二区三区| 国产白丝网站精品污在线入口| 亚洲人精品午夜| 在线不卡一区二区| 韩国精品久久久| 亚洲三级在线看| 777色狠狠一区二区三区| 国产一区二区三区av电影| 国产精品剧情在线亚洲| 欧美性色综合网| 国产一区二区三区最好精华液| 国产欧美日韩在线| 91国产精品成人| 麻豆精品一区二区综合av| 国产女人aaa级久久久级| 91在线国内视频| 日韩精品色哟哟| 中文成人av在线| 欧美三级视频在线观看| 黄一区二区三区| 亚洲情趣在线观看| 精品成人在线观看| 99国产欧美另类久久久精品| 亚洲va欧美va天堂v国产综合| 精品粉嫩超白一线天av| 91论坛在线播放| 麻豆国产欧美一区二区三区| 中文字幕在线不卡一区| 欧美一区在线视频| 91亚洲精品久久久蜜桃| 精品一区二区三区在线播放 | 国产伦精一区二区三区| 亚洲人成人一区二区在线观看| 欧美一卡二卡在线观看| 不卡av免费在线观看| 日日欢夜夜爽一区| 亚洲三级免费观看| 久久精品视频网| 欧美精品电影在线播放| 99久久综合99久久综合网站| 久久精品av麻豆的观看方式| 亚洲三级视频在线观看| 国产亚洲短视频| 欧美一区二区三区婷婷月色| 91免费国产视频网站| 国产麻豆精品视频| 视频在线在亚洲| 亚洲欧美日韩国产综合| 国产亚洲综合色| 欧美r级电影在线观看| 欧美日韩卡一卡二| 99久久99久久综合| 成人小视频在线观看| 久久精品国产精品亚洲综合| 午夜日韩在线观看| 亚洲综合图片区| 亚洲欧洲国产日韩| 中文字幕欧美三区| 久久久www成人免费无遮挡大片| 欧美人与禽zozo性伦| 色中色一区二区| 播五月开心婷婷综合| 国产成人av一区二区三区在线观看| 日本一不卡视频| 午夜精品福利一区二区三区av | 亚洲三级在线看| 国产精品久久综合| 欧美国产精品中文字幕| 欧美精品一区二区三| 日韩欧美国产wwwww| 欧美一级在线免费| 91麻豆精品国产91久久久| 欧美日韩中文字幕一区| 欧美在线免费观看亚洲| 91麻豆成人久久精品二区三区|