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

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

?? ixqmgrqcfg.c

?? 針對(duì)OpenJtag通用調(diào)試板的Uboot程序
?? C
字號(hào):
/** * @file    QMgrQCfg.c * * @author Intel Corporation * @date    30-Oct-2001 *  * @brief   This modules provides an interface for setting up the static * configuration of AQM queues.This file contains the following * functions: * *  *  * @par * IXP400 SW Release version 2.0 *  * -- Copyright Notice -- *  * @par * Copyright 2001-2005, Intel Corporation. * All rights reserved. *  * @par * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright *    notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright *    notice, this list of conditions and the following disclaimer in the *    documentation and/or other materials provided with the distribution. * 3. Neither the name of the Intel Corporation nor the names of its contributors *    may be used to endorse or promote products derived from this software *    without specific prior written permission. *  * @par * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS ``AS IS'' * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE * ARE DISCLAIMED.  IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. *  * @par * -- End of Copyright Notice --*//* * System defined include files. *//* * User defined include files. */#include "IxOsal.h"#include "IxQMgr.h"#include "IxQMgrAqmIf_p.h"#include "IxQMgrQCfg_p.h"#include "IxQMgrDefines_p.h"/* * #defines and macros used in this file. */#define IX_QMGR_MIN_ENTRY_SIZE_IN_WORDS 16/* Total size of SRAM */#define IX_QMGR_AQM_SRAM_SIZE_IN_BYTES 0x4000/* * Check that qId is a valid queue identifier. This is provided to * make the code easier to read. */#define IX_QMGR_QID_IS_VALID(qId) \(((qId) >= (IX_QMGR_MIN_QID)) && ((qId) <= (IX_QMGR_MAX_QID)))/* * Typedefs whose scope is limited to this file. *//* * This struct describes an AQM queue. * N.b. bufferSizeInWords and qEntrySizeInWords are stored in the queue * as these are requested by Access in the data path. sizeInEntries is * not required by the data path so it can be calculated dynamically. *  */typedef struct{    char qName[IX_QMGR_MAX_QNAME_LEN+1];       /* Textual description of a queue*/    IxQMgrQSizeInWords qSizeInWords;           /* The number of words in the queue */    IxQMgrQEntrySizeInWords qEntrySizeInWords; /* Number of words per queue entry*/    BOOL isConfigured;                         /* This flag is TRUE if the queue has                                                *   been configured                                                */} IxQMgrCfgQ;/* * Variable declarations global to this file. Externs are followed by * statics. */extern UINT32 * ixQMgrAqmIfQueAccRegAddr[]; /* Store data required to inline read and write access */IxQMgrQInlinedReadWriteInfo ixQMgrQInlinedReadWriteInfo[IX_QMGR_MAX_NUM_QUEUES];static IxQMgrCfgQ cfgQueueInfo[IX_QMGR_MAX_NUM_QUEUES];/* This pointer holds the starting address of AQM SRAM not used by * the AQM queues. */static UINT32 freeSramAddress=0;/* 4 words of zeroed memory for inline access */static UINT32 zeroedPlaceHolder[4] = { 0, 0, 0, 0 };static BOOL cfgInitialized = FALSE;static IxOsalMutex ixQMgrQCfgMutex;/* * Statistics */static IxQMgrQCfgStats stats;/* * Function declarations */PRIVATE BOOLwatermarkLevelIsOk (IxQMgrQId qId, IxQMgrWMLevel level);PRIVATE BOOLqSizeInWordsIsOk (IxQMgrQSizeInWords qSize);PRIVATE BOOLqEntrySizeInWordsIsOk (IxQMgrQEntrySizeInWords entrySize);/* * Function definitions. */voidixQMgrQCfgInit (void){    int loopIndex;        for (loopIndex=0; loopIndex < IX_QMGR_MAX_NUM_QUEUES;loopIndex++)    {	/* info for code inlining */	ixQMgrAqmIfQueAccRegAddr[loopIndex] = zeroedPlaceHolder;	/* info for code inlining */	ixQMgrQInlinedReadWriteInfo[loopIndex].qReadCount = 0;	ixQMgrQInlinedReadWriteInfo[loopIndex].qWriteCount = 0;	ixQMgrQInlinedReadWriteInfo[loopIndex].qAccRegAddr = zeroedPlaceHolder;	ixQMgrQInlinedReadWriteInfo[loopIndex].qUOStatRegAddr = zeroedPlaceHolder;	ixQMgrQInlinedReadWriteInfo[loopIndex].qUflowStatBitMask = 0;	ixQMgrQInlinedReadWriteInfo[loopIndex].qOflowStatBitMask = 0;	ixQMgrQInlinedReadWriteInfo[loopIndex].qEntrySizeInWords = 0;	ixQMgrQInlinedReadWriteInfo[loopIndex].qSizeInEntries = 0;	ixQMgrQInlinedReadWriteInfo[loopIndex].qConfigRegAddr = zeroedPlaceHolder;   }    /* Initialise the AqmIf component */    ixQMgrAqmIfInit ();       /* Reset all queues to have queue name = NULL, entry size = 0 and     * isConfigured = false     */    for (loopIndex=0; loopIndex < IX_QMGR_MAX_NUM_QUEUES;loopIndex++)    {	strcpy (cfgQueueInfo[loopIndex].qName, "");	cfgQueueInfo[loopIndex].qSizeInWords = 0;	cfgQueueInfo[loopIndex].qEntrySizeInWords = 0;	cfgQueueInfo[loopIndex].isConfigured = FALSE;	/* Statistics */	stats.qStats[loopIndex].isConfigured = FALSE;	stats.qStats[loopIndex].qName = cfgQueueInfo[loopIndex].qName;    }    /* Statistics */    stats.wmSetCnt = 0;    ixQMgrAqmIfSramBaseAddressGet (&freeSramAddress);        ixOsalMutexInit(&ixQMgrQCfgMutex);    cfgInitialized = TRUE;}voidixQMgrQCfgUninit (void){    cfgInitialized = FALSE;    /* Uninitialise the AqmIf component */    ixQMgrAqmIfUninit ();}IX_STATUSixQMgrQConfig (char *qName,	      IxQMgrQId qId,	      IxQMgrQSizeInWords qSizeInWords,	      IxQMgrQEntrySizeInWords qEntrySizeInWords){    UINT32 aqmLocalBaseAddress;    if (!cfgInitialized)    {        return IX_FAIL;    }        if (!IX_QMGR_QID_IS_VALID(qId))    {	return IX_QMGR_INVALID_Q_ID;    }        else if (NULL == qName)    {	return IX_QMGR_PARAMETER_ERROR;    }        else if (strlen (qName) > IX_QMGR_MAX_QNAME_LEN)    {	return IX_QMGR_PARAMETER_ERROR;    }    else if (!qSizeInWordsIsOk (qSizeInWords))    {	return IX_QMGR_INVALID_QSIZE;    }    else if (!qEntrySizeInWordsIsOk (qEntrySizeInWords))    {	return IX_QMGR_INVALID_Q_ENTRY_SIZE;    }        else if (cfgQueueInfo[qId].isConfigured)    {	return IX_QMGR_Q_ALREADY_CONFIGURED;    }       ixOsalMutexLock(&ixQMgrQCfgMutex, IX_OSAL_WAIT_FOREVER);    /* Write the config register */    ixQMgrAqmIfQueCfgWrite (qId,			   qSizeInWords,			   qEntrySizeInWords,			   freeSramAddress);    strcpy (cfgQueueInfo[qId].qName, qName);    cfgQueueInfo[qId].qSizeInWords = qSizeInWords;    cfgQueueInfo[qId].qEntrySizeInWords = qEntrySizeInWords;    /* store pre-computed information in the same cache line     * to facilitate inlining of QRead and QWrite functions      * in IxQMgr.h     */    ixQMgrQInlinedReadWriteInfo[qId].qReadCount = 0;    ixQMgrQInlinedReadWriteInfo[qId].qWriteCount = 0;    ixQMgrQInlinedReadWriteInfo[qId].qEntrySizeInWords = qEntrySizeInWords;    ixQMgrQInlinedReadWriteInfo[qId].qSizeInEntries = 		(UINT32)qSizeInWords / (UINT32)qEntrySizeInWords;    /* Calculate the new freeSramAddress from the size of the queue     * currently being configured.     */    freeSramAddress += (qSizeInWords * IX_QMGR_NUM_BYTES_PER_WORD);    /* Get the virtual SRAM address */    ixQMgrAqmIfBaseAddressGet (&aqmLocalBaseAddress);    IX_OSAL_ASSERT((freeSramAddress - (aqmLocalBaseAddress + (IX_QMGR_QUEBUFFER_SPACE_OFFSET))) <=	      IX_QMGR_QUE_BUFFER_SPACE_SIZE);    /* The queue is now configured */    cfgQueueInfo[qId].isConfigured = TRUE;    ixOsalMutexUnlock(&ixQMgrQCfgMutex);#ifndef NDEBUG    /* Update statistics */    stats.qStats[qId].isConfigured = TRUE;    stats.qStats[qId].qName = cfgQueueInfo[qId].qName;#endif    return IX_SUCCESS;}IxQMgrQSizeInWordsixQMgrQSizeInWordsGet (IxQMgrQId qId){    /* No parameter checking as this is used on the data path */    return (cfgQueueInfo[qId].qSizeInWords);}IX_STATUSixQMgrQSizeInEntriesGet (IxQMgrQId qId,			 unsigned *qSizeInEntries){    if (!ixQMgrQIsConfigured(qId))    {        return IX_QMGR_Q_NOT_CONFIGURED;    }    if(NULL == qSizeInEntries)    {        return IX_QMGR_PARAMETER_ERROR;    }    *qSizeInEntries = (UINT32)(cfgQueueInfo[qId].qSizeInWords) /        (UINT32)cfgQueueInfo[qId].qEntrySizeInWords;    return IX_SUCCESS;}IxQMgrQEntrySizeInWordsixQMgrQEntrySizeInWordsGet (IxQMgrQId qId){    /* No parameter checking as this is used on the data path */    return (cfgQueueInfo[qId].qEntrySizeInWords);}IX_STATUSixQMgrWatermarkSet (IxQMgrQId qId,		    IxQMgrWMLevel ne,		    IxQMgrWMLevel nf){        IxQMgrQStatus qStatusOnEntry;/* The queue status on entry/exit */    IxQMgrQStatus qStatusOnExit; /* to this function               */    if (!ixQMgrQIsConfigured(qId))    {        return IX_QMGR_Q_NOT_CONFIGURED;    }    if (!watermarkLevelIsOk (qId, ne))    {	return IX_QMGR_INVALID_Q_WM;    }    if (!watermarkLevelIsOk (qId, nf))    {	return IX_QMGR_INVALID_Q_WM;    }    /* Get the current queue status */    ixQMgrAqmIfQueStatRead (qId, &qStatusOnEntry);#ifndef NDEBUG    /* Update statistics */    stats.wmSetCnt++;#endif    ixQMgrAqmIfWatermarkSet (qId,			    ne,			    nf);    /* Get the current queue status */    ixQMgrAqmIfQueStatRead (qId, &qStatusOnExit);      /* If the status has changed return a warning */    if (qStatusOnEntry != qStatusOnExit)    {	return IX_QMGR_WARNING;    }    return IX_SUCCESS;}IX_STATUSixQMgrAvailableSramAddressGet (UINT32 *address,			      unsigned *sizeOfFreeRam){    UINT32 aqmLocalBaseAddress;    if ((NULL == address)||(NULL == sizeOfFreeRam))     {	return IX_QMGR_PARAMETER_ERROR;    }    if (!cfgInitialized)    {	return IX_FAIL;    }    *address = freeSramAddress;    /* Get the virtual SRAM address */    ixQMgrAqmIfBaseAddressGet (&aqmLocalBaseAddress);    /*      * Calculate the size in bytes of free sram      * i.e. current free SRAM virtual pointer from     *      (base + total size)     */    *sizeOfFreeRam = 	(aqmLocalBaseAddress +	IX_QMGR_AQM_SRAM_SIZE_IN_BYTES) -	freeSramAddress;    if (0 == *sizeOfFreeRam)    {	return IX_QMGR_NO_AVAILABLE_SRAM;    }    return IX_SUCCESS;}BOOLixQMgrQIsConfigured (IxQMgrQId qId){    if (!IX_QMGR_QID_IS_VALID(qId))    {	return FALSE;    }    return cfgQueueInfo[qId].isConfigured;}IxQMgrQCfgStats*ixQMgrQCfgStatsGet (void){    return &stats;}IxQMgrQCfgStats*ixQMgrQCfgQStatsGet (IxQMgrQId qId){    unsigned int ne;    unsigned int nf;    UINT32 baseAddress;    UINT32 readPtr;    UINT32 writePtr;    stats.qStats[qId].qSizeInWords = cfgQueueInfo[qId].qSizeInWords;    stats.qStats[qId].qEntrySizeInWords = cfgQueueInfo[qId].qEntrySizeInWords;        if (IX_SUCCESS != ixQMgrQNumEntriesGet (qId, &stats.qStats[qId].numEntries))    {        if (IX_QMGR_WARNING != ixQMgrQNumEntriesGet (qId, &stats.qStats[qId].numEntries))        {	   IX_QMGR_LOG_WARNING1("Failed to get the number of entries in queue.... %d\n", qId);        }    }    ixQMgrAqmIfQueCfgRead (qId,			   stats.qStats[qId].numEntries,			   &baseAddress,			   &ne,			   &nf,			   &readPtr,			   &writePtr);            stats.qStats[qId].baseAddress = baseAddress;    stats.qStats[qId].ne = ne;    stats.qStats[qId].nf = nf;    stats.qStats[qId].readPtr = readPtr;    stats.qStats[qId].writePtr = writePtr;    return &stats;}/*  * Static function definitions */PRIVATE BOOLwatermarkLevelIsOk (IxQMgrQId qId, IxQMgrWMLevel level){    unsigned qSizeInEntries;    switch (level)    {	case IX_QMGR_Q_WM_LEVEL0: 	case IX_QMGR_Q_WM_LEVEL1: 	case IX_QMGR_Q_WM_LEVEL2: 	case IX_QMGR_Q_WM_LEVEL4: 	case IX_QMGR_Q_WM_LEVEL8: 	case IX_QMGR_Q_WM_LEVEL16:	case IX_QMGR_Q_WM_LEVEL32:	case IX_QMGR_Q_WM_LEVEL64:	    break;	default:	    return FALSE;    }    /* Check watermark is not bigger than the qSizeInEntries */    ixQMgrQSizeInEntriesGet(qId, &qSizeInEntries);    if ((unsigned)level > qSizeInEntries)    {	return FALSE;    }    return TRUE;}PRIVATE BOOLqSizeInWordsIsOk (IxQMgrQSizeInWords qSize){    BOOL status;    switch (qSize)    {		case IX_QMGR_Q_SIZE16:	case IX_QMGR_Q_SIZE32:	case IX_QMGR_Q_SIZE64:	case IX_QMGR_Q_SIZE128:	    status = TRUE;	    break;	default:	    status = FALSE;	    break;    }    return status;}PRIVATE BOOLqEntrySizeInWordsIsOk (IxQMgrQEntrySizeInWords entrySize){    BOOL status;    switch (entrySize)    {	case IX_QMGR_Q_ENTRY_SIZE1:	case IX_QMGR_Q_ENTRY_SIZE2:	case IX_QMGR_Q_ENTRY_SIZE4:	    status = TRUE;	    break;	default:	    status = FALSE;	    break;    }    return status;}

?? 快捷鍵說(shuō)明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號(hào) Ctrl + =
減小字號(hào) Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
国产一区二区不卡老阿姨| 成人国产精品视频| 日本一区二区电影| 91精品欧美一区二区三区综合在| 国产成人av自拍| 偷偷要91色婷婷| 亚洲欧美色综合| 久久久久国产成人精品亚洲午夜| 欧美日韩亚洲综合| 成人激情开心网| 狠狠色综合日日| 天堂资源在线中文精品| 成人欧美一区二区三区1314| 欧美精品一区二区久久婷婷| 欧美丰满嫩嫩电影| 色噜噜偷拍精品综合在线| 成人午夜av影视| 国产一区不卡在线| 蜜桃精品视频在线观看| 亚洲国产一区二区视频| 亚洲免费电影在线| 中文字幕亚洲一区二区va在线| 久久久亚洲精品一区二区三区| 717成人午夜免费福利电影| 在线观看不卡视频| 一本久久精品一区二区| 不卡一区中文字幕| www.欧美色图| av亚洲精华国产精华| 成人污视频在线观看| 风间由美性色一区二区三区| 国产精品亚洲а∨天堂免在线| 久久99国产精品麻豆| 毛片不卡一区二区| 精品亚洲国内自在自线福利| 美女视频网站久久| 久久国产精品99精品国产 | 欧美精品一二三区| 欧美日韩一二三| 欧美三级蜜桃2在线观看| 在线视频观看一区| 欧美亚洲国产一区二区三区va| 色拍拍在线精品视频8848| 色哟哟一区二区在线观看| 色综合久久天天| 欧美视频在线一区| 欧美另类高清zo欧美| 欧美一区二区久久| 久久一区二区三区国产精品| 国产欧美视频一区二区三区| 国产精品亲子乱子伦xxxx裸| 《视频一区视频二区| 亚洲情趣在线观看| 午夜影院久久久| 精品中文字幕一区二区小辣椒 | 色系网站成人免费| 欧美日韩三级视频| 91精品国产91热久久久做人人| 日韩欧美一级二级三级| 国产亚洲女人久久久久毛片| 国产精品国产三级国产专播品爱网 | 欧美在线观看一区| 91精品婷婷国产综合久久竹菊| 精品盗摄一区二区三区| 国产精品第五页| 亚洲国产欧美在线| 久久 天天综合| 99精品欧美一区二区三区小说 | 日韩欧美一级片| 国产精品三级av在线播放| 夜夜亚洲天天久久| 久久97超碰国产精品超碰| 99九九99九九九视频精品| 欧美日韩精品系列| 国产亚洲成aⅴ人片在线观看| 亚洲视频一二三| 日本欧美肥老太交大片| 成人午夜碰碰视频| 在线电影一区二区三区| 国产欧美日韩视频在线观看| 亚洲资源中文字幕| 国产成人自拍网| 欧美精品 日韩| 国产精品精品国产色婷婷| 日韩电影在线免费看| 不卡的av在线播放| 欧美一级艳片视频免费观看| 国产精品美女久久福利网站| 五月开心婷婷久久| 国产成人精品1024| 91麻豆精品国产91久久久资源速度| 国产欧美日韩久久| 免费一级片91| 欧美亚洲禁片免费| 欧美国产综合一区二区| 免费人成精品欧美精品| 91免费视频网| 欧美国产精品久久| 久久国产精品一区二区| 欧美中文字幕一区二区三区| 亚洲激情一二三区| 国产精品中文欧美| 欧美日韩大陆在线| 亚洲三级在线免费观看| 国产精品1区2区| 日韩一区二区三区四区| 亚洲国产婷婷综合在线精品| 成人国产精品免费观看| 精品国精品国产| 奇米精品一区二区三区四区| 天天影视网天天综合色在线播放| av一二三不卡影片| 欧美激情一区二区三区不卡| 精品制服美女丁香| 欧美一区三区四区| 午夜久久久久久| 色8久久人人97超碰香蕉987| 国产精品久久久一区麻豆最新章节| 久久国产人妖系列| 日韩欧美www| 欧美aaa在线| 7777精品伊人久久久大香线蕉 | 欧美猛男超大videosgay| 椎名由奈av一区二区三区| 成人激情黄色小说| 中文字幕欧美国产| 国产91丝袜在线播放0| 2024国产精品视频| 国产一区二区三区四区五区入口| 精品理论电影在线观看| 免费高清成人在线| 日韩免费高清电影| 美女高潮久久久| 精品理论电影在线| 国产揄拍国内精品对白| 久久婷婷久久一区二区三区| 久草这里只有精品视频| 26uuu国产日韩综合| 国产精品小仙女| 国产免费成人在线视频| 成人av电影在线观看| 国产精品久线观看视频| 91色婷婷久久久久合中文| 亚洲乱码日产精品bd| 欧美丝袜丝交足nylons| 性欧美疯狂xxxxbbbb| 日韩欧美激情四射| 国产一区视频在线看| 中文无字幕一区二区三区 | 91麻豆福利精品推荐| 亚洲一区二区在线免费看| 欧美福利视频一区| 久久成人av少妇免费| 欧美国产精品中文字幕| 91网站视频在线观看| 亚洲国产日韩一区二区| 日韩视频一区二区三区| 国产乱码精品一区二区三区忘忧草| 日本一区免费视频| 在线观看亚洲专区| 蜜臀av国产精品久久久久 | 亚洲天堂免费看| 在线成人av影院| 国产一区二区三区美女| 中文字幕制服丝袜成人av| 中文字幕日本不卡| 91久久精品网| 久久精品99国产国产精| 国产精品天天看| 欧美日韩综合在线免费观看| 精品在线免费视频| 亚洲三级久久久| 欧美一级二级三级乱码| 国产91丝袜在线播放0| 亚洲综合在线五月| 精品久久久久久久久久久院品网| 99精品黄色片免费大全| 青娱乐精品视频在线| 国产免费成人在线视频| 欧美日韩一本到| 国产v综合v亚洲欧| 婷婷综合五月天| 国产精品青草久久| 制服丝袜成人动漫| 不卡一区二区三区四区| 久久国产综合精品| 亚洲综合激情小说| 国产亚洲欧美一区在线观看| 欧美日本一区二区在线观看| 国产成人在线网站| 日韩电影在线免费| 亚洲精品免费电影| 欧美极品另类videosde| 91精品国产一区二区人妖| 99精品在线观看视频| 国产一区二区三区美女| 日本三级亚洲精品| 亚洲综合激情网| 1000部国产精品成人观看| 精品国产青草久久久久福利|