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

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? ixethdbfeatures.c

?? 友善mini2440嵌入式
?? C
?? 第 1 頁 / 共 2 頁
字號:
/** * @file IxEthDBFeatures.c * * @brief Implementation of the EthDB feature control API * * @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 -- */#include "IxNpeDl.h"#include "IxEthDBQoS.h"#include "IxEthDB_p.h"/** * @brief scans the capabilities of the loaded NPE images * * This function MUST be called by the ixEthDBInit() function. * No EthDB features (including learning and filtering) are enabled * before this function is called. * * @return none * * @internal */IX_ETH_DB_PUBLICvoid ixEthDBFeatureCapabilityScan(void){    IxNpeDlImageId imageId, npeAImageId;    IxEthDBPortId portIndex;    PortInfo *portInfo;    IxEthDBPriorityTable defaultPriorityTable;    IX_STATUS result;    UINT32 queueIndex;    UINT32 queueStructureIndex;    UINT32 trafficClassDefinitionIndex;    /* read version of NPE A - required to set the AQM queues for B and C */    npeAImageId.functionalityId = 0;    ixNpeDlLoadedImageGet(IX_NPEDL_NPEID_NPEA, &npeAImageId);    for (portIndex = 0 ; portIndex < IX_ETH_DB_NUMBER_OF_PORTS ; portIndex++)    {        IxNpeMhMessage msg;        portInfo = &ixEthDBPortInfo[portIndex];        /* check and bypass if NPE B or C is fused out */        if (ixEthDBSingleEthNpeCheck(portIndex) != IX_ETH_DB_SUCCESS) continue;        /* all ports are capable of LEARNING by default */        portInfo->featureCapability |= IX_ETH_DB_LEARNING;        portInfo->featureStatus     |= IX_ETH_DB_LEARNING;        if (ixEthDBPortDefinitions[portIndex].type == IX_ETH_NPE)        {            if (ixNpeDlLoadedImageGet(IX_ETH_DB_PORT_ID_TO_NPE(portIndex), &imageId) != IX_SUCCESS)            {                WARNING_LOG("DB: (FeatureScan) NpeDl did not provide the image ID for NPE port %d\n", portIndex);            }            else            {                /* initialize and empty NPE response mutex */                ixOsalMutexInit(&portInfo->npeAckLock);                ixOsalMutexLock(&portInfo->npeAckLock, IX_OSAL_WAIT_FOREVER);                /* check NPE response to GetStatus */                msg.data[0] = IX_ETHNPE_NPE_GETSTATUS << 24;                msg.data[1] = 0;                IX_ETHDB_SEND_NPE_MSG(IX_ETH_DB_PORT_ID_TO_NPE(portIndex), msg, result);                if (result != IX_SUCCESS)                {                    WARNING_LOG("DB: (FeatureScan) warning, could not send message to the NPE\n");                    continue;                }                if (imageId.functionalityId == 0x00                    || imageId.functionalityId == 0x03                    || imageId.functionalityId == 0x04                    || imageId.functionalityId == 0x80)                {                    portInfo->featureCapability |= IX_ETH_DB_FILTERING;                    portInfo->featureCapability |= IX_ETH_DB_FIREWALL;                    portInfo->featureCapability |= IX_ETH_DB_SPANNING_TREE_PROTOCOL;                }                else if (imageId.functionalityId == 0x01                         || imageId.functionalityId == 0x81)                {                    portInfo->featureCapability |= IX_ETH_DB_FILTERING;                    portInfo->featureCapability |= IX_ETH_DB_FIREWALL;                    portInfo->featureCapability |= IX_ETH_DB_SPANNING_TREE_PROTOCOL;                    portInfo->featureCapability |= IX_ETH_DB_VLAN_QOS;                }                else if (imageId.functionalityId == 0x02                         || imageId.functionalityId == 0x82)                {                    portInfo->featureCapability |= IX_ETH_DB_WIFI_HEADER_CONVERSION;                    portInfo->featureCapability |= IX_ETH_DB_FIREWALL;                    portInfo->featureCapability |= IX_ETH_DB_SPANNING_TREE_PROTOCOL;                    portInfo->featureCapability |= IX_ETH_DB_VLAN_QOS;                }                /* reset AQM queues */                memset(portInfo->ixEthDBTrafficClassAQMAssignments, 0, sizeof (portInfo->ixEthDBTrafficClassAQMAssignments));                /* ensure there's at least one traffic class record in the definition table, otherwise we have no default case, hence no queues */                IX_ENSURE(sizeof (ixEthDBTrafficClassDefinitions) != 0, "DB: no traffic class definitions found, check IxEthDBQoS.h");                /* find the traffic class definition index compatible with the current NPE A functionality ID */                for (trafficClassDefinitionIndex = 0 ;                    trafficClassDefinitionIndex < sizeof (ixEthDBTrafficClassDefinitions) / sizeof (ixEthDBTrafficClassDefinitions[0]);                    trafficClassDefinitionIndex++)                {                    if (ixEthDBTrafficClassDefinitions[trafficClassDefinitionIndex][IX_ETH_DB_NPE_A_FUNCTIONALITY_ID_INDEX] == npeAImageId.functionalityId)                    {                        /* found it */                        break;                    }                }                /* select the default case if we went over the array boundary */                if (trafficClassDefinitionIndex == sizeof (ixEthDBTrafficClassDefinitions) / sizeof (ixEthDBTrafficClassDefinitions[0]))                {                    trafficClassDefinitionIndex = 0; /* the first record is the default case */                }                /* select queue assignment structure based on the traffic class configuration index */                queueStructureIndex = ixEthDBTrafficClassDefinitions[trafficClassDefinitionIndex][IX_ETH_DB_QUEUE_ASSIGNMENT_INDEX];                /* only traffic class 0 is active at initialization time */                portInfo->ixEthDBTrafficClassCount = 1;                /* enable port, VLAN and Firewall feature bits to initialize QoS/VLAN/Firewall configuration */                portInfo->featureStatus |= IX_ETH_DB_VLAN_QOS;                portInfo->featureStatus |= IX_ETH_DB_FIREWALL;                portInfo->enabled        = TRUE;#define CONFIG_WITH_VLAN  /* test-only: VLAN support not included to save space!!! */#ifdef CONFIG_WITH_VLAN /* test-only: VLAN support not included to save space!!! */                /* set VLAN initial configuration (permissive) */                if ((portInfo->featureCapability & IX_ETH_DB_VLAN_QOS) != 0) /* QoS-enabled image */                {                    /* QoS capable */                    portInfo->ixEthDBTrafficClassAvailable = ixEthDBTrafficClassDefinitions[trafficClassDefinitionIndex][IX_ETH_DB_TRAFFIC_CLASS_COUNT_INDEX];                    /* set AQM queues */                    for (queueIndex = 0 ; queueIndex < IX_IEEE802_1Q_QOS_PRIORITY_COUNT ; queueIndex++)                    {                        portInfo->ixEthDBTrafficClassAQMAssignments[queueIndex] = ixEthDBQueueAssignments[queueStructureIndex][queueIndex];                    }                    /* set default PVID (0) and default traffic class 0 */                    ixEthDBPortVlanTagSet(portIndex, 0);                    /* enable reception of all frames */                    ixEthDBAcceptableFrameTypeSet(portIndex, IX_ETH_DB_ACCEPT_ALL_FRAMES);                    /* clear full VLAN membership */                    ixEthDBPortVlanMembershipRangeRemove(portIndex, 0, IX_ETH_DB_802_1Q_MAX_VLAN_ID);                    /* clear TTI table - no VLAN tagged frames will be transmitted */                    ixEthDBEgressVlanRangeTaggingEnabledSet(portIndex, 0, 4094, FALSE);                    /* set membership on 0, otherwise no Tx or Rx is working */                    ixEthDBPortVlanMembershipAdd(portIndex, 0);                }                else /* QoS not available in this image */#endif /* test-only */                {                    /* initialize traffic class availability (only class 0 is available) */                    portInfo->ixEthDBTrafficClassAvailable = 1;                    /* point all AQM queues to traffic class 0 */                    for (queueIndex = 0 ; queueIndex < IX_IEEE802_1Q_QOS_PRIORITY_COUNT ; queueIndex++)                    {                        portInfo->ixEthDBTrafficClassAQMAssignments[queueIndex] =                            ixEthDBQueueAssignments[queueStructureIndex][0];                    }                }#ifdef CONFIG_WITH_VLAN /* test-only: VLAN support not included to save space!!! */                /* download priority mapping table and Rx queue configuration */                memset (defaultPriorityTable, 0, sizeof (defaultPriorityTable));                ixEthDBPriorityMappingTableSet(portIndex, defaultPriorityTable);#endif                /* by default we turn off invalid source MAC address filtering */                ixEthDBFirewallInvalidAddressFilterEnable(portIndex, FALSE);                /* disable port, VLAN, Firewall feature bits */                portInfo->featureStatus &= ~IX_ETH_DB_VLAN_QOS;                portInfo->featureStatus &= ~IX_ETH_DB_FIREWALL;                portInfo->enabled        = FALSE;                /* enable filtering by default if present */                if ((portInfo->featureCapability & IX_ETH_DB_FILTERING) != 0)                {                    portInfo->featureStatus |= IX_ETH_DB_FILTERING;                }            }        }    }}/** * @brief returns the capability of a port * * @param portID ID of the port * @param featureSet location to store the port capability in * * This function will save the capability set of the given port * into the given location. Capabilities are bit-ORed, each representing * a bit of the feature set. * * Note that this function is documented in the main component * public header file, IxEthDB.h. * * @return IX_ETH_DB_SUCCESS if the operation completed successfully * or IX_ETH_DB_INVALID_PORT if the given port is invalid */IX_ETH_DB_PUBLICIxEthDBStatus ixEthDBFeatureCapabilityGet(IxEthDBPortId portID, IxEthDBFeature *featureSet){    IX_ETH_DB_CHECK_PORT_INITIALIZED(portID);    IX_ETH_DB_CHECK_REFERENCE(featureSet);    *featureSet = ixEthDBPortInfo[portID].featureCapability;    return IX_ETH_DB_SUCCESS;}/** * @brief enables or disables a port capability * * @param portID ID of the port * @param feature feature to enable or disable * @param enabled TRUE to enable the selected feature or FALSE to disable it * * Note that this function is documented in the main component * header file, IxEthDB.h. * * @return IX_ETH_DB_SUCCESS if the operation completed * successfully or an appropriate error message otherwise */IX_ETH_DB_PUBLICIxEthDBStatus ixEthDBFeatureEnable(IxEthDBPortId portID, IxEthDBFeature feature, BOOL enable){    PortInfo *portInfo;    IxEthDBPriorityTable defaultPriorityTable;    IxEthDBVlanSet vlanSet;    IxEthDBStatus status = IX_ETH_DB_SUCCESS;    BOOL portEnabled;    IX_ETH_DB_CHECK_PORT_INITIALIZED(portID);    portInfo    = &ixEthDBPortInfo[portID];    portEnabled = portInfo->enabled;    /* check that only one feature is selected */    if (!ixEthDBCheckSingleBitValue(feature))    {        return IX_ETH_DB_FEATURE_UNAVAILABLE;    }    /* port capable of this feature? */    if ((portInfo->featureCapability & feature) == 0)    {        return IX_ETH_DB_FEATURE_UNAVAILABLE;    }    /* mutual exclusion between learning and WiFi header conversion */    if (enable && ((feature | portInfo->featureStatus) & (IX_ETH_DB_FILTERING | IX_ETH_DB_WIFI_HEADER_CONVERSION))            == (IX_ETH_DB_FILTERING | IX_ETH_DB_WIFI_HEADER_CONVERSION))    {        return IX_ETH_DB_NO_PERMISSION;    }    /* learning must be enabled before filtering */    if (enable && (feature == IX_ETH_DB_FILTERING) && ((portInfo->featureStatus & IX_ETH_DB_LEARNING) == 0))    {        return IX_ETH_DB_NO_PERMISSION;    }    /* filtering must be disabled before learning */    if (!enable && (feature == IX_ETH_DB_LEARNING) && ((portInfo->featureStatus & IX_ETH_DB_FILTERING) != 0))    {        return IX_ETH_DB_NO_PERMISSION;    }    /* redundant enabling or disabling */    if ((!enable && ((portInfo->featureStatus & feature) == 0))        || (enable && ((portInfo->featureStatus & feature) != 0)))    {        /* do nothing */        return IX_ETH_DB_SUCCESS;

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
欧美在线综合视频| 亚洲视频综合在线| 日韩欧美亚洲另类制服综合在线| 日本vs亚洲vs韩国一区三区二区 | 国产视频911| 日韩欧美一级特黄在线播放| 日本欧美大码aⅴ在线播放| 亚洲精品视频一区| 亚洲日本护士毛茸茸| 国产精品青草久久| 国产精品天干天干在线综合| 国产午夜亚洲精品羞羞网站| 91在线视频在线| 亚洲va欧美va天堂v国产综合| 一区二区三区蜜桃| 亚洲国产激情av| 欧美日韩精品欧美日韩精品一 | 欧美激情在线观看视频免费| 精品系列免费在线观看| 亚洲国产一区在线观看| 亚洲精品videosex极品| 亚洲国产综合人成综合网站| 亚洲国产综合色| 91亚洲男人天堂| 欧美色图一区二区三区| 国内不卡的二区三区中文字幕 | 国产中文一区二区三区| 成人午夜视频在线| 色婷婷综合久久久久中文 | 精品久久久久久久久久久久包黑料| 欧美二区三区的天堂| 日韩欧美黄色影院| 国产亚洲精品aa| 日本人妖一区二区| 99精品国产91久久久久久| 欧美中文字幕亚洲一区二区va在线| 欧美精品乱码久久久久久按摩| 欧美精品一区二区久久婷婷| 2021久久国产精品不只是精品| 国产精品乱码一区二区三区软件 | 激情欧美一区二区三区在线观看| 国产69精品久久777的优势| av电影在线观看不卡| 日韩免费视频一区二区| 亚洲在线观看免费| 国产成人精品www牛牛影视| 欧美理论片在线| 欧美高清在线一区二区| 久久精品二区亚洲w码| 欧美丝袜丝交足nylons| 久久久91精品国产一区二区精品| 亚洲最大的成人av| 国产91精品一区二区| 欧美一区二区三区色| 亚洲国产中文字幕| 国产欧美一区二区三区网站| 香港成人在线视频| 婷婷中文字幕综合| 欧洲一区二区av| 亚洲精品综合在线| 日本一区中文字幕| 制服丝袜中文字幕一区| 三级欧美在线一区| 有码一区二区三区| 欧美色图片你懂的| 亚洲成年人影院| 欧美军同video69gay| 夜夜爽夜夜爽精品视频| 欧美日韩中文国产| 日韩va亚洲va欧美va久久| 欧美丰满嫩嫩电影| 精品在线视频一区| 欧美日韩久久久久久| 日韩成人免费电影| 精品毛片乱码1区2区3区| 蜜臀国产一区二区三区在线播放| 欧美成人猛片aaaaaaa| 国产精品夜夜爽| 亚洲色图欧美激情| 国产高清视频一区| 欧美韩国日本不卡| 色综合久久综合中文综合网| 婷婷成人激情在线网| 久久免费精品国产久精品久久久久| 午夜激情综合网| 中文字幕av一区二区三区免费看| 91搞黄在线观看| 久久精品国产成人一区二区三区 | 日韩欧美国产小视频| 欧美日韩国产一区| 精品影视av免费| 国产精品美女久久久久aⅴ国产馆| 欧美性生交片4| 国产91精品精华液一区二区三区 | 精品国产免费视频| 欧美综合欧美视频| 久久精品国产精品亚洲精品| 国产精品美日韩| 欧美日韩国产综合视频在线观看| 国产精品毛片无遮挡高清| 7777精品伊人久久久大香线蕉的 | 欧美一级黄色片| 久久久久久一级片| 1024成人网| 日韩av一区二| 国产老女人精品毛片久久| 成人性生交大片免费看中文| 在线观看av一区二区| 欧美群妇大交群的观看方式| 精品91自产拍在线观看一区| 国产精品伦一区二区三级视频| 亚洲柠檬福利资源导航| 日本美女一区二区三区视频| 国产精品一区二区久激情瑜伽| 波多野结衣中文字幕一区二区三区| 一道本成人在线| 久久欧美中文字幕| 亚洲一级二级在线| 高清av一区二区| 日韩一区二区免费电影| 美女爽到高潮91| 欧美日韩中文字幕一区| 国产日产欧美一区二区视频| 亚洲一区二区视频在线观看| 国产专区欧美精品| 91.麻豆视频| 亚洲精品欧美二区三区中文字幕| 九九热在线视频观看这里只有精品| 成人av电影在线| 国产日韩精品一区二区三区在线| 五月天中文字幕一区二区| 91在线观看成人| 中文无字幕一区二区三区| 久久er99精品| 91精品国产一区二区三区| 夜夜亚洲天天久久| 日本乱人伦一区| 中文字幕亚洲成人| 国产综合一区二区| 久久午夜电影网| 激情av综合网| 亚洲精品一区二区在线观看| 免费欧美在线视频| 91精品国产综合久久久久久漫画 | 久久免费电影网| 国产一区二区三区高清播放| 日韩免费成人网| 久久99九九99精品| 久久婷婷国产综合国色天香| 国产精品一卡二卡| 中文幕一区二区三区久久蜜桃| 国产精品1区二区.| 国产亚洲欧美日韩在线一区| 成熟亚洲日本毛茸茸凸凹| 中文字幕欧美日本乱码一线二线| 国产suv一区二区三区88区| 国产校园另类小说区| 成+人+亚洲+综合天堂| 最新热久久免费视频| 精品视频1区2区| 久久aⅴ国产欧美74aaa| 国产精品高潮呻吟久久| 色婷婷久久99综合精品jk白丝| 亚洲国产精品欧美一二99| 欧美一区在线视频| 成人一区二区视频| 午夜私人影院久久久久| 久久久久国色av免费看影院| 99re视频精品| 久久成人免费日本黄色| 亚洲人成精品久久久久久| 欧美精品一二三四| 国产成+人+日韩+欧美+亚洲| 亚洲午夜精品网| 精品电影一区二区| 欧美精品一卡两卡| youjizz国产精品| 毛片av一区二区| 国产精品毛片a∨一区二区三区| 欧美日韩精品三区| 9人人澡人人爽人人精品| 亚洲美女屁股眼交| 91精品久久久久久久久99蜜臂| 国产高清精品网站| 免费一级片91| 亚洲r级在线视频| 国产亚洲午夜高清国产拍精品 | 精品裸体舞一区二区三区| 欧美日韩中文字幕一区二区| 不卡免费追剧大全电视剧网站| 久久不见久久见免费视频1| 日本欧美在线看| 免费亚洲电影在线| 亚洲va欧美va人人爽| 亚洲国产精品影院| 亚洲色欲色欲www在线观看| 国产欧美一区视频| 中文字幕的久久| 中文字幕欧美三区| 中文字幕av资源一区|