source: SVN/cambria/redboot/packages/devs/eth/intel/npe/common/current/include/IxEthDBQoS.h @ 1

Last change on this file since 1 was 1, checked in by Tim Harvey, 2 years ago

restored latest version of files from server backup

Signed-off-by: Tim Harvey <tharvey@…>

File size: 6.5 KB
Line 
1/**
2 * @file IxEthDBQoS.h
3 *
4 * @brief Public definitions for QoS traffic classes
5 *
6 * @par
7 * IXP400 SW Release version 2.3
8 *
9 * -- Copyright Notice --
10 *
11 * @par
12 * Copyright (c) 2001-2005, Intel Corporation.
13 * All rights reserved.
14 *
15 * @par
16 * Redistribution and use in source and binary forms, with or without
17 * modification, are permitted provided that the following conditions
18 * are met:
19 * 1. Redistributions of source code must retain the above copyright
20 *    notice, this list of conditions and the following disclaimer.
21 * 2. Redistributions in binary form must reproduce the above copyright
22 *    notice, this list of conditions and the following disclaimer in the
23 *    documentation and/or other materials provided with the distribution.
24 * 3. Neither the name of the Intel Corporation nor the names of its contributors
25 *    may be used to endorse or promote products derived from this software
26 *    without specific prior written permission.
27 *
28 *
29 * @par
30 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS ``AS IS''
31 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
32 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
33 * ARE DISCLAIMED.  IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE
34 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
35 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
36 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
37 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
38 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
39 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
40 * SUCH DAMAGE.
41 *
42 *
43 * @par
44 * -- End of Copyright Notice --
45 */
46
47/**
48 * @defgroup IxEthDBPortDefs Intel (R) IXP400 Software Ethernet QoS definitions
49 *
50 * @brief IXP00 Public definitions for QoS traffic classes
51 *
52 * @{
53 */
54
55#ifndef IxEthDBQoS_H
56#define IxEthDBQoS_H
57
58/**
59 * @def IX_ETH_DB_QUEUE_UNAVAILABLE
60 * @brief alias to indicate a queue (traffic class) is not available
61 */
62#define IX_ETH_DB_QUEUE_UNAVAILABLE  (0)
63
64#ifndef IX_IEEE802_1Q_QOS_PRIORITY_COUNT
65/**
66 * @def IX_IEEE802_1Q_QOS_PRIORITY_COUNT
67 * @brief number of QoS priorities, according to IEEE 802.1Q
68 */
69#define IX_IEEE802_1Q_QOS_PRIORITY_COUNT (8)
70#endif
71
72/**
73 * @brief array containing all the supported traffic class configurations
74 */
75static const
76UINT8 ixEthDBQueueAssignments[][IX_IEEE802_1Q_QOS_PRIORITY_COUNT] = 
77{
78    { 4, 5, 6, 7, IX_ETH_DB_QUEUE_UNAVAILABLE, IX_ETH_DB_QUEUE_UNAVAILABLE, IX_ETH_DB_QUEUE_UNAVAILABLE, IX_ETH_DB_QUEUE_UNAVAILABLE },
79    { 15, 16, 17, 18, IX_ETH_DB_QUEUE_UNAVAILABLE, IX_ETH_DB_QUEUE_UNAVAILABLE, IX_ETH_DB_QUEUE_UNAVAILABLE, IX_ETH_DB_QUEUE_UNAVAILABLE },
80    { 11, 23, 26, IX_ETH_DB_QUEUE_UNAVAILABLE, IX_ETH_DB_QUEUE_UNAVAILABLE, IX_ETH_DB_QUEUE_UNAVAILABLE, IX_ETH_DB_QUEUE_UNAVAILABLE,  IX_ETH_DB_QUEUE_UNAVAILABLE },
81    { 4, 5, 6, 7, 8, 9, 10, 11 }
82    /* add here all other cases of queue configuration structures and update ixEthDBTrafficClassDefinitions to use them */
83};
84
85/**
86 * @brief value used to index the NPE A functionality ID in the traffic class definition table
87 */
88#define IX_ETH_DB_NPE_A_FUNCTIONALITY_ID_INDEX    (0)
89
90/**
91 * @brief value used to index the traffic class count in the traffic class definition table
92 */
93#define IX_ETH_DB_TRAFFIC_CLASS_COUNT_INDEX       (1)
94
95/**
96 * @brief value used to index the queue assignment index in the traffic class definition table
97 */
98#define IX_ETH_DB_QUEUE_ASSIGNMENT_INDEX          (2)
99
100/**
101 * @brief traffic class definitions
102 *
103 * This array contains the default traffic class definition configuration,
104 * as well as any special cases dictated by the functionality ID of NPE A.
105 *
106 * The default case should not be removed (otherwise the Ethernet
107 * components will assert a fatal failure on initialization).
108 */
109static const
110UINT8 ixEthDBTrafficClassDefinitions[][3] = 
111{
112    /* NPE A functionality ID | traffic class count | queue assignment index (points to the queue enumeration in ixEthDBQueueAssignments) */
113    {            0x00,                      4,                    0 }, /* default case 1 - DO NOT REMOVE */
114    {            0xFF,                      8,                    3 }, /* default case 2 - DO NOT REMOVE */
115    {            0x04,                      4,                    1 }, /* NPE A image ID 0.4.0.0 */
116    {            0x09,                      3,                    2 }, /* NPE A image ID 0.9.0.0 */
117    {            0x80,                      8,                    3 }, /* NPE A image ID 10.80.02.0 */
118    {            0x81,                      8,                    3 }, /* NPE A image ID 10.81.02.0 */
119    {            0x82,                      8,                    3 }, /* NPE A image ID 10.82.02.0 */
120    {            0x8B,                      8,                    3 }, /* NPE A image ID 10.8B.02.0 */
121    {            0x8C,                      8,                    3 }, /* NPE A image ID 10.8C.02.0 */
122    {            0x8D,                      8,                    3 }, /* NPE A image ID 10.8D.02.0 */
123    {            0x90,                      8,                    3 }, /* NPE A image ID 10.90.00.0 */
124    {            0x91,                      8,                    3 }  /* NPE A image ID 10.91.00.0 */ 
125};
126
127/**
128 * @brief IEEE 802.1Q recommended QoS Priority => traffic class maps
129 *
130 * @verbatim
131                    Number of available traffic classes
132                    1 2 3 4 5 6 7 8
133    QoS Priority
134        0           0 0 0 1 1 1 1 2
135        1           0 0 0 0 0 0 0 0
136        2           0 0 0 0 0 0 0 1
137        3           0 0 0 1 1 2 2 3
138        4           0 1 1 2 2 3 3 4
139        5           0 1 1 2 3 4 4 5
140        6           0 1 2 3 4 5 5 6
141        7           0 1 2 3 4 5 6 7
142
143    @endverbatim
144 */
145static const
146UINT8 ixEthIEEE802_1QUserPriorityToTrafficClassMapping[IX_IEEE802_1Q_QOS_PRIORITY_COUNT][IX_IEEE802_1Q_QOS_PRIORITY_COUNT] = 
147 {
148     { 0, 0, 0, 0, 0, 0, 0, 0 }, /* 1 traffic class available */
149     { 0, 0, 0, 0, 1, 1, 1, 1 }, /* 2 traffic classes available */
150     { 0, 0, 0, 0, 1, 1, 2, 2 }, /* 3 traffic classes available */
151     { 1, 0, 0, 1, 2, 2, 3, 3 }, /* 4 traffic classes available */
152     { 1, 0, 0, 1, 2, 3, 4, 4 }, /* 5 traffic classes available */
153     { 1, 0, 0, 2, 3, 4, 5, 5 }, /* 6 traffic classes available */
154     { 1, 0, 0, 2, 3, 4, 5, 6 }, /* 7 traffic classes available */
155     { 2, 0, 1, 3, 4, 5, 6, 7 }  /* 8 traffic classes available */
156 };
157
158#endif /* IxEthDBQoS_H */
159
160/**
161 *@}
162 */
Note: See TracBrowser for help on using the repository browser.