1 #ifndef __doxygen_HIDE /* This file is not part of the API */
7 * IXP400 SW Release version 2.0
9 * -- Copyright Notice --
12 * Copyright 2001-2005, Intel Corporation.
13 * All rights reserved.
16 * Redistribution and use in source and binary forms, with or without
17 * modification, are permitted provided that the following conditions
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.
29 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS ``AS IS''
30 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
31 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
32 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE
33 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
34 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
35 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
36 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
37 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
38 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
42 * -- End of Copyright Notice --
46 * @defgroup IxEthNpe IXP400 Ethernet NPE (IxEthNpe) API
48 * @brief Contains the API for Ethernet NPE.
50 * All messages given to NPE, get back an acknowledgment. The acknowledgment
51 * is identical to the message sent to the NPE (except for NPE_GETSTATUS message).
57 /*--------------------------------------------------------------------------
58 * APB Message IDs - XScale->NPE
59 *------------------------------------------------------------------------*/
62 * @def IX_ETHNPE_NPE_GETSTATUS
64 * @brief Request from the XScale client for the NPE to return the firmware
65 * version of the currently executing image.
67 * Acknowledgment message id is same as the request message id.
68 * NPE returns the firmware version ID to XScale.
70 #define IX_ETHNPE_NPE_GETSTATUS 0x00
73 * @def IX_ETHNPE_EDB_SETPORTADDRESS
75 * @brief Request from the XScale client for the NPE to set the Ethernet
76 * port's port ID and MAC address.
78 #define IX_ETHNPE_EDB_SETPORTADDRESS 0x01
81 * @def IX_ETHNPE_EDB_GETMACADDRESSDATABASE
83 * @brief Request from XScale client to the NPE requesting upload of
84 * Ethernet Filtering Database or Header Conversion Database from NPE's
85 * data memory to XScale accessible SDRAM.
87 #define IX_ETHNPE_EDB_GETMACADDRESSDATABASE 0x02
90 * @def IX_ETHNPE_EDB_SETMACADDRESSSDATABASE
92 * @brief Request from XScale client to the NPE requesting download of
93 * Ethernet Filtering Database or Header Conversion Database from SDRAM
94 * to the NPE's datamemory.
96 #define IX_ETHNPE_EDB_SETMACADDRESSSDATABASE 0x03
99 * @def IX_ETHNPE_GETSTATS
101 * @brief Request from the XScale client for the current MAC port statistics
102 * data to be written to the (empty) statistics structure and the specified
103 * location in externa memory.
105 #define IX_ETHNPE_GETSTATS 0x04
108 * @def IX_ETHNPE_RESETSTATS
110 * @brief Request from the XScale client to the NPE to reset all of its internal
111 * MAC port statistics state variables.
113 * As a side effect, this message entails an implicit request that the NPE
114 * write the current MAC port statistics into the MAC statistics structure
115 * at the specified location in external memory.
117 #define IX_ETHNPE_RESETSTATS 0x05
120 * @def IX_ETHNPE_SETMAXFRAMELENGTHS
122 * @brief Request from the XScale client to the NPE to configure maximum framelengths
123 * and block sizes in receive and transmit direction.
125 #define IX_ETHNPE_SETMAXFRAMELENGTHS 0x06
128 * @def IX_ETHNPE_VLAN_SETRXTAGMODE
130 * @brief Request from the XScale client to the NPE to configure VLAN frame type
131 * filtering and VLAN the tagging mode for the receiver.
133 #define IX_ETHNPE_VLAN_SETRXTAGMODE 0x07
136 * @def IX_ETHNPE_VLAN_SETDEFAULTRXVID
138 * @brief Request from the XScale client to the NPE to set receiver's default
139 * VLAN tag (PVID)and internal traffic class.
141 #define IX_ETHNPE_VLAN_SETDEFAULTRXVID 0x08
144 * @def IX_ETHNPE_VLAN_SETPORTVLANTABLEENTRY
146 * @brief Request from the XScale client to the NPE to configure VLAN Port
147 * membership and Tx tagging for 8 consecutive VLANID's.
149 #define IX_ETHNPE_VLAN_SETPORTVLANTABLEENTRY 0x09
152 * @def IX_ETHNPE_VLAN_SETPORTVLANTABLERANGE
154 * @brief Request from the XScale client to the NPE to configure VLAN Port
155 * membership and Tx tagging for a range of VLANID's.
157 #define IX_ETHNPE_VLAN_SETPORTVLANTABLERANGE 0x0A
160 * @def IX_ETHNPE_VLAN_SETRXQOSENTRY
162 * @brief Request from the XScale client to the NPE to map a user priority
163 * to QoS class and an AQM queue number.
165 #define IX_ETHNPE_VLAN_SETRXQOSENTRY 0x0B
168 * @def IX_ETHNPE_VLAN_SETPORTIDEXTRACTIONMODE
170 * @brief Request from the XScale client to the NPE to enable or disable
171 * portID extraction from VLAN-tagged frames for the specified port.
173 #define IX_ETHNPE_VLAN_SETPORTIDEXTRACTIONMODE 0x0C
176 * @def IX_ETHNPE_STP_SETBLOCKINGSTATE
178 * @brief Request from the XScale client to the NPE to block or unblock
179 * forwarding for spanning tree BPDUs.
181 #define IX_ETHNPE_STP_SETBLOCKINGSTATE 0x0D
184 * @def IX_ETHNPE_FW_SETFIREWALLMODE
186 * @brief Request from the XScale client to the NPE to configure firewall
187 * services modes of operation and/or download Ethernet Firewall Database from
190 #define IX_ETHNPE_FW_SETFIREWALLMODE 0x0E
193 * @def IX_ETHNPE_PC_SETFRAMECONTROLDURATIONID
195 * @brief Request from the XScale client to the NPE to set global frame control
196 * and duration/ID field for the 802.3 to 802.11 protocol header conversion
199 #define IX_ETHNPE_PC_SETFRAMECONTROLDURATIONID 0x0F
202 * @def IX_ETHNPE_PC_SETBBSID
204 * @brief Request from the XScale client to the NPE to set global BBSID field
205 * value for the 802.3 to 802.11 protocol header conversion service.
207 #define IX_ETHNPE_PC_SETBBSID 0x10
210 * @def IX_ETHNPE_PC_SETAPMACTABLE
212 * @brief Request from the XScale client to the NPE to update a block/section/
213 * range of the AP MAC Address Table.
215 #define IX_ETHNPE_PC_SETAPMACTABLE 0x11
218 * @def IX_ETHNPE_SETLOOPBACK_MODE
220 * @brief Turn on or off the NPE frame loopback.
222 #define IX_ETHNPE_SETLOOPBACK_MODE (0x12)
224 /*--------------------------------------------------------------------------
225 * APB Message IDs - NPE->XScale
226 *------------------------------------------------------------------------*/
229 * @def IX_ETHNPE_NPE_GETSTATUS_ACK
231 * @brief Acknowledgment to IX_ETHNPE_NPE_GETSTATUS message. NPE firmware version
232 * id is returned in the message.
234 #define IX_ETHNPE_NPE_GETSTATUS_ACK 0x00
237 * @def IX_ETHNPE_EDB_SETPORTADDRESS_ACK
239 * @brief Acknowledgment to IX_ETHNPE_EDB_SETPORTADDRESS message.
241 #define IX_ETHNPE_EDB_SETPORTADDRESS_ACK 0x01
244 * @def IX_ETHNPE_EDB_GETMACADDRESSDATABASE_ACK
246 * @brief Acknowledgment to IX_ETHNPE_EDB_GETMACADDRESSDATABASE message
248 #define IX_ETHNPE_EDB_GETMACADDRESSDATABASE_ACK 0x02
251 * @def IX_ETHNPE_EDB_SETMACADDRESSSDATABASE_ACK
253 * @brief Acknowledgment to IX_ETHNPE_EDB_SETMACADDRESSSDATABASE message.
255 #define IX_ETHNPE_EDB_SETMACADDRESSSDATABASE_ACK 0x03
258 * @def IX_ETHNPE_GETSTATS_ACK
260 * @brief Acknowledgment to IX_ETHNPE_GETSTATS message.
262 #define IX_ETHNPE_GETSTATS_ACK 0x04
265 * @def IX_ETHNPE_RESETSTATS_ACK
267 * @brief Acknowledgment to IX_ETHNPE_RESETSTATS message.
269 #define IX_ETHNPE_RESETSTATS_ACK 0x05
272 * @def IX_ETHNPE_SETMAXFRAMELENGTHS_ACK
274 * @brief Acknowledgment to IX_ETHNPE_SETMAXFRAMELENGTHS message.
276 #define IX_ETHNPE_SETMAXFRAMELENGTHS_ACK 0x06
279 * @def IX_ETHNPE_VLAN_SETRXTAGMODE_ACK
281 * @brief Acknowledgment to IX_ETHNPE_VLAN_SETRXTAGMODE message.
283 #define IX_ETHNPE_VLAN_SETRXTAGMODE_ACK 0x07
286 * @def IX_ETHNPE_VLAN_SETDEFAULTRXVID_ACK
288 * @brief Acknowledgment to IX_ETHNPE_VLAN_SETDEFAULTRXVID message.
290 #define IX_ETHNPE_VLAN_SETDEFAULTRXVID_ACK 0x08
293 * @def IX_ETHNPE_VLAN_SETPORTVLANTABLEENTRY_ACK
295 * @brief Acknowledgment to IX_ETHNPE_VLAN_SETPORTVLANTABLEENTRY message.
297 #define IX_ETHNPE_VLAN_SETPORTVLANTABLEENTRY_ACK 0x09
300 * @def IX_ETHNPE_VLAN_SETPORTVLANTABLERANGE_ACK
302 * @brief Acknowledgment to IX_ETHNPE_VLAN_SETPORTVLANTABLERANGE message.
304 #define IX_ETHNPE_VLAN_SETPORTVLANTABLERANGE_ACK 0x0A
307 * @def IX_ETHNPE_VLAN_SETRXQOSENTRY_ACK
309 * @brief Acknowledgment to IX_ETHNPE_VLAN_SETRXQOSENTRY message.
311 #define IX_ETHNPE_VLAN_SETRXQOSENTRY_ACK 0x0B
314 * @def IX_ETHNPE_VLAN_SETPORTIDEXTRACTIONMODE_ACK
316 * @brief Acknowledgment to IX_ETHNPE_VLAN_SETPORTIDEXTRACTIONMODE message.
318 #define IX_ETHNPE_VLAN_SETPORTIDEXTRACTIONMODE_ACK 0x0C
321 * @def IX_ETHNPE_STP_SETBLOCKINGSTATE_ACK
323 * @brief Acknowledgment to IX_ETHNPE_STP_SETBLOCKINGSTATE message.
325 #define IX_ETHNPE_STP_SETBLOCKINGSTATE_ACK 0x0D
328 * @def IX_ETHNPE_FW_SETFIREWALLMODE_ACK
330 * @brief Acknowledgment to IX_ETHNPE_FW_SETFIREWALLMODE message.
332 #define IX_ETHNPE_FW_SETFIREWALLMODE_ACK 0x0E
335 * @def IX_ETHNPE_PC_SETFRAMECONTROLDURATIONID_ACK
337 * @brief Acknowledgment to IX_ETHNPE_PC_SETFRAMECONTROLDURATIONID message.
339 #define IX_ETHNPE_PC_SETFRAMECONTROLDURATIONID_ACK 0x0F
342 * @def IX_ETHNPE_PC_SETBBSID_ACK
344 * @brief Acknowledgment to IX_ETHNPE_PC_SETBBSID message.
346 #define IX_ETHNPE_PC_SETBBSID_ACK 0x10
349 * @def IX_ETHNPE_PC_SETAPMACTABLE_ACK
351 * @brief Acknowledgment to IX_ETHNPE_PC_SETAPMACTABLE message.
353 #define IX_ETHNPE_PC_SETAPMACTABLE_ACK 0x11
356 * @def IX_ETHNPE_SETLOOPBACK_MODE_ACK
358 * @brief Acknowledgment to IX_ETHNPE_SETLOOPBACK_MODE message.
360 #define IX_ETHNPE_SETLOOPBACK_MODE_ACK (0x12)
362 /*--------------------------------------------------------------------------
363 * Queue Manager Queue entry bit field boundary definitions
364 *------------------------------------------------------------------------*/
369 * @brief Macro for mask
371 #define MASK(hi,lo) (((1 << (1 + ((hi) - (lo)))) - 1) << (lo))
376 * @brief Macro for bits
378 #define BITS(x,hi,lo) (((x) & MASK(hi,lo)) >> (lo))
381 * @def IX_ETHNPE_QM_Q_RXENET_LENGTH_MASK
383 * @brief QMgr Queue LENGTH field mask
385 #define IX_ETHNPE_QM_Q_RXENET_LENGTH_MASK 0x3fff
388 * @def IX_ETHNPE_QM_Q_FIELD_FLAG_R
390 * @brief QMgr Queue FLAG field right boundary
392 #define IX_ETHNPE_QM_Q_FIELD_FLAG_R 20
395 * @def IX_ETHNPE_QM_Q_FIELD_FLAG_MASK
397 * @brief QMgr Queue FLAG field mask
399 * Multicast bit : BIT(4)
400 * Broadcast bit : BIT(5)
401 * IP bit : BIT(6) (linux only)
405 #define IX_ETHNPE_QM_Q_FIELD_FLAG_MASK 0x30
407 #define IX_ETHNPE_QM_Q_FIELD_FLAG_MASK 0x70
412 * @def IX_ETHNPE_QM_Q_FIELD_NPEID_L
414 * @brief QMgr Queue NPE ID field left boundary
416 #define IX_ETHNPE_QM_Q_FIELD_NPEID_L 1
419 * @def IX_ETHNPE_QM_Q_FIELD_NPEID_R
421 * @brief QMgr Queue NPE ID field right boundary
423 #define IX_ETHNPE_QM_Q_FIELD_NPEID_R 0
426 * @def IX_ETHNPE_QM_Q_FIELD_PRIOR_L
428 * @brief QMgr Queue Priority field left boundary
430 #define IX_ETHNPE_QM_Q_FIELD_PRIOR_L 2
433 * @def IX_ETHNPE_QM_Q_FIELD_PRIOR_R
435 * @brief QMgr Queue Priority field right boundary
437 #define IX_ETHNPE_QM_Q_FIELD_PRIOR_R 0
440 * @def IX_ETHNPE_QM_Q_FIELD_ADDR_L
442 * @brief QMgr Queue Address field left boundary
444 #define IX_ETHNPE_QM_Q_FIELD_ADDR_L 31
447 * @def IX_ETHNPE_QM_Q_FIELD_ADDR_R
449 * @brief QMgr Queue Address field right boundary
451 #define IX_ETHNPE_QM_Q_FIELD_ADDR_R 5
453 /*--------------------------------------------------------------------------
454 * Queue Manager Queue entry bit field masks
455 *------------------------------------------------------------------------*/
458 * @def IX_ETHNPE_QM_Q_FREEENET_ADDR_MASK
460 * @brief Macro to mask the Address field of the FreeEnet Queue Manager Entry
462 #define IX_ETHNPE_QM_Q_FREEENET_ADDR_MASK \
463 MASK (IX_ETHNPE_QM_Q_FIELD_ADDR_L, \
464 IX_ETHNPE_QM_Q_FIELD_ADDR_R)
467 * @def IX_ETHNPE_QM_Q_RXENET_NPEID_MASK
469 * @brief Macro to mask the NPE ID field of the RxEnet Queue Manager Entry
471 #define IX_ETHNPE_QM_Q_RXENET_NPEID_MASK \
472 MASK (IX_ETHNPE_QM_Q_FIELD_NPEID_L, \
473 IX_ETHNPE_QM_Q_FIELD_NPEID_R)
476 * @def IX_ETHNPE_QM_Q_RXENET_ADDR_MASK
478 * @brief Macro to mask the Mbuf Address field of the RxEnet Queue Manager Entry
480 #define IX_ETHNPE_QM_Q_RXENET_ADDR_MASK \
481 MASK (IX_ETHNPE_QM_Q_FIELD_ADDR_L, \
482 IX_ETHNPE_QM_Q_FIELD_ADDR_R)
485 * @def IX_ETHNPE_QM_Q_TXENET_PRIOR_MASK
487 * @brief Macro to mask the Priority field of the TxEnet Queue Manager Entry
489 #define IX_ETHNPE_QM_Q_TXENET_PRIOR_MASK \
490 MASK (IX_ETHNPE_QM_Q_FIELD_PRIOR_L, \
491 IX_ETHNPE_QM_Q_FIELD_PRIOR_R)
494 * @def IX_ETHNPE_QM_Q_TXENET_ADDR_MASK
496 * @brief Macro to mask the Mbuf Address field of the TxEnet Queue Manager Entry
498 #define IX_ETHNPE_QM_Q_TXENET_ADDR_MASK \
499 MASK (IX_ETHNPE_QM_Q_FIELD_ADDR_L, \
500 IX_ETHNPE_QM_Q_FIELD_ADDR_R)
503 * @def IX_ETHNPE_QM_Q_TXENETDONE_NPEID_MASK
505 * @brief Macro to mask the NPE ID field of the TxEnetDone Queue Manager Entry
507 #define IX_ETHNPE_QM_Q_TXENETDONE_NPEID_MASK \
508 MASK (IX_ETHNPE_QM_Q_FIELD_NPEID_L, \
509 IX_ETHNPE_QM_Q_FIELD_NPEID_R)
512 * @def IX_ETHNPE_QM_Q_TXENETDONE_ADDR_MASK
514 * @brief Macro to mask the Mbuf Address field of the TxEnetDone Queue Manager
517 #define IX_ETHNPE_QM_Q_TXENETDONE_ADDR_MASK \
518 MASK (IX_ETHNPE_QM_Q_FIELD_ADDR_L, \
519 IX_ETHNPE_QM_Q_FIELD_ADDR_R)
521 /*--------------------------------------------------------------------------
522 * Queue Manager Queue entry bit field value extraction macros
523 *------------------------------------------------------------------------*/
526 * @def IX_ETHNPE_QM_Q_FREEENET_ADDR_VAL(x)
528 * @brief Extraction macro for Address field of FreeNet Queue Manager Entry
530 * Pointer to an mbuf buffer descriptor
532 #define IX_ETHNPE_QM_Q_FREEENET_ADDR_VAL(x) \
533 ((x) & IX_ETHNPE_QM_Q_FREEENET_ADDR_MASK)
536 * @def IX_ETHNPE_QM_Q_RXENET_NPEID_VAL(x)
538 * @brief Extraction macro for NPE ID field of RxEnet Queue Manager Entry
540 * Set to 0 for entries originating from the Eth0 NPE;
541 * Set to 1 for entries originating from the Eth1 NPE.
543 #define IX_ETHNPE_QM_Q_RXENET_NPEID_VAL(x) \
544 BITS (x, IX_ETHNPE_QM_Q_FIELD_NPEID_L, \
545 IX_ETHNPE_QM_Q_FIELD_NPEID_R)
548 * @def IX_ETHNPE_QM_Q_RXENET_PORTID_VAL(x)
550 * @brief Extraction macro for Port ID field of RxEnet Queue Manager Entry
552 * 0-5: Assignable (by the XScale client) to any of the physical ports.
554 * 7: Indication that the NPE did not find the associated frame's destination MAC address within
555 * its internal filtering database.
557 #define IX_ETHNPE_QM_Q_RXENET_PORTID_VAL(x) \
558 BITS (x, IX_ETHNPE_QM_Q_FIELD_PORTID_L, \
559 IX_ETHNPE_QM_Q_Field_PortID_R)
562 * @def IX_ETHNPE_QM_Q_RXENET_ADDR_VAL(x)
564 * @brief Extraction macro for Address field of RxEnet Queue Manager Entry
566 * Pointer to an mbuf buffer descriptor
568 #define IX_ETHNPE_QM_Q_RXENET_ADDR_VAL(x) \
569 ((x) & IX_ETHNPE_QM_Q_RXENET_ADDR_MASK)
572 * @def IX_ETHNPE_QM_Q_TXENET_PRIOR_VAL(x)
574 * @brief Extraction macro for Priority field of TxEnet Queue Manager Entry
576 * Priority of the packet (as described in IEEE 802.1D). This field is
577 * cleared upon return from the Ethernet NPE to the TxEnetDone queue.
579 #define IX_ETHNPE_QM_Q_TXENET_PRIOR_VAL(x) \
580 BITS (x, IX_ETHNPE_QM_Q_FIELD_PRIOR_L, \
581 IX_ETHNPE_QM_Q_FIELD_PRIOR_R)
584 * @def IX_ETHNPE_QM_Q_TXENET_ADDR_VAL(x)
586 * @brief Extraction macro for Address field of Queue Manager TxEnet Queue
589 * Pointer to an mbuf buffer descriptor
591 #define IX_ETHNPE_QM_Q_TXENET_ADDR_VAL(x) \
592 ((x) & IX_ETHNPE_QM_Q_TXENET_ADDR_MASK)
595 * @def IX_ETHNPE_QM_Q_TXENETDONE_NPEID_VAL(x)
597 * @brief Extraction macro for NPE ID field of TxEnetDone Queue Manager Entry
599 * Set to 0 for entries originating from the Eth0 NPE; set to 1 for en-tries
600 * originating from the Eth1 NPE.
602 #define IX_ETHNPE_QM_Q_TXENETDONE_NPEID_VAL(x) \
603 BITS (x, IX_ETHNPE_QM_Q_FIELD_NPEID_L, \
604 IX_ETHNPE_QM_Q_FIELD_NPEID_R)
607 * @def IX_ETHNPE_QM_Q_TXENETDONE_ADDR_VAL(x)
609 * @brief Extraction macro for Address field of TxEnetDone Queue Manager Entry
611 * Pointer to an mbuf buffer descriptor
613 #define IX_ETHNPE_QM_Q_TXENETDONE_ADDR_VAL(x) \
614 ((x) & IX_ETHNPE_QM_Q_TXENETDONE_ADDR_MASK)
617 /*--------------------------------------------------------------------------
619 *------------------------------------------------------------------------*/
622 * @def IX_ETHNPE_ACC_RXFREE_BUFFER_LENGTH_MIN
624 * @brief Macro to check the minimum length of a rx free buffer
626 #define IX_ETHNPE_ACC_RXFREE_BUFFER_LENGTH_MIN (64)
629 * @def IX_ETHNPE_ACC_RXFREE_BUFFER_LENGTH_MASK
631 * @brief Mask to apply to the mbuf length before submitting it to the NPE
632 * (the NPE handles only rx free mbufs which are multiple of 64)
634 * @sa IX_ETHNPE_ACC_RXFREE_BUFFER_LENGTH_MASK
636 #define IX_ETHNPE_ACC_RXFREE_BUFFER_LENGTH_MASK (~63)
639 * @def IX_ETHNPE_ACC_RXFREE_BUFFER_ROUND_UP(size)
641 * @brief Round up to get the size necessary to receive without chaining
642 * the frames which are (size) bytes (the NPE operates by multiple of 64)
643 * e.g. To receive 1514 bytes frames, the size of the buffers in replenish
644 * has to be at least (1514+63)&(~63) = 1536 bytes.
647 #define IX_ETHNPE_ACC_RXFREE_BUFFER_ROUND_UP(size) (((size) + 63) & ~63)
650 * @def IX_ETHNPE_ACC_RXFREE_BUFFER_ROUND_DOWN(size)
652 * @brief Round down to apply to the mbuf length before submitting
653 * it to the NPE. (the NPE operates by multiple of 64)
656 #define IX_ETHNPE_ACC_RXFREE_BUFFER_ROUND_DOWN(size) ((size) & ~63)
659 * @def IX_ETHNPE_ACC_FRAME_LENGTH_MAX
661 * @brief maximum mbuf length supported by the NPE
663 * @sa IX_ETHNPE_ACC_FRAME_LENGTH_MAX
665 #define IX_ETHNPE_ACC_FRAME_LENGTH_MAX (16320)
668 * @def IX_ETHNPE_ACC_FRAME_LENGTH_DEFAULT
670 * @brief default mbuf length supported by the NPE
672 * @sa IX_ETHNPE_ACC_FRAME_LENGTH_DEFAULT
674 #define IX_ETHNPE_ACC_FRAME_LENGTH_DEFAULT (1522)
677 * @def IX_ETHNPE_ACC_LENGTH_OFFSET
679 * @brief Offset of the cluster length field in the word shared with the NPEs
681 #define IX_ETHNPE_ACC_LENGTH_OFFSET 16
684 * @def IX_ETHNPE_ACC_PKTLENGTH_MASK
686 * @brief Mask of the cluster length field in the word shared with the NPEs
688 #define IX_ETHNPE_ACC_PKTLENGTH_MASK 0x3fff
695 #endif /* __doxygen_HIDE */