Lines Matching +full:spi +full:- +full:crc

7  * Copyright (c) 2003-2008 Cavium Networks
14 * AS-IS and WITHOUT ANY WARRANTY; without even the implied warranty
21 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
36 #include <asm/octeon/cvmx-wqe.h>
37 #include <asm/octeon/cvmx-fpa.h>
38 #include <asm/octeon/cvmx-pip-defs.h>
103 /* RGM+SPI 1 = partially received packet (buffering/bandwidth
106 /* RGM+SPI 2 = receive packet too large and truncated */
113 /* RGM+SPI 4 = max frame error (pkt len > max frame len) */
116 * RGM 5 = nibble error (data not byte multiple - 100M and 10M
127 /* RGM+SPI 8 = min frame error (pkt len < min frame len) */
138 /* SPI 11 = DIP4 error */
141 * RGM 12 = packet was not large enough to pass the skipper -
146 * RGM 13 = studder error (data not repeated - 100M and 10M
150 /* RGM+SPI 16 = FCS error */
153 * RGM+SPI+PCI 17 = packet was not large enough to pass the
154 * skipper - no inspection could occur.
158 * RGM+SPI+PCI 18 = malformed l2 (packet not long enough to
208 /* Number of 65-127B packets */
210 /* Number of 128-255B packets */
212 /* Number of 256-511B packets */
214 /* Number of 512-1023B packets */
216 /* Number of 1024-1518B packets */
218 /* Number of 1519-max packets */
234 * including CRC
249 * Documented as R - Set if the Packet is RAWFULL. If
282 /* CSR typedefs have been moved to cvmx-csr-*.h */
310 * @watcher: Watcher number to configure (0 - 3).
334 * VLAN priority (0-7)
349 * @diffserv: Diffserv field value (0-63)
406 status->dropped_octets = stat0.s.drp_octs; in cvmx_pip_get_port_status()
407 status->dropped_packets = stat0.s.drp_pkts; in cvmx_pip_get_port_status()
408 status->octets = stat1.s.octs; in cvmx_pip_get_port_status()
409 status->pci_raw_packets = stat2.s.raw; in cvmx_pip_get_port_status()
410 status->packets = stat2.s.pkts; in cvmx_pip_get_port_status()
411 status->multicast_packets = stat3.s.mcst; in cvmx_pip_get_port_status()
412 status->broadcast_packets = stat3.s.bcst; in cvmx_pip_get_port_status()
413 status->len_64_packets = stat4.s.h64; in cvmx_pip_get_port_status()
414 status->len_65_127_packets = stat4.s.h65to127; in cvmx_pip_get_port_status()
415 status->len_128_255_packets = stat5.s.h128to255; in cvmx_pip_get_port_status()
416 status->len_256_511_packets = stat5.s.h256to511; in cvmx_pip_get_port_status()
417 status->len_512_1023_packets = stat6.s.h512to1023; in cvmx_pip_get_port_status()
418 status->len_1024_1518_packets = stat6.s.h1024to1518; in cvmx_pip_get_port_status()
419 status->len_1519_max_packets = stat7.s.h1519; in cvmx_pip_get_port_status()
420 status->fcs_align_err_packets = stat7.s.fcs; in cvmx_pip_get_port_status()
421 status->runt_packets = stat8.s.undersz; in cvmx_pip_get_port_status()
422 status->runt_crc_packets = stat8.s.frag; in cvmx_pip_get_port_status()
423 status->oversize_packets = stat9.s.oversz; in cvmx_pip_get_port_status()
424 status->oversize_crc_packets = stat9.s.jabber; in cvmx_pip_get_port_status()
425 status->inb_packets = pip_stat_inb_pktsx.s.pkts; in cvmx_pip_get_port_status()
426 status->inb_octets = pip_stat_inb_octsx.s.octs; in cvmx_pip_get_port_status()
427 status->inb_errors = pip_stat_inb_errsx.s.errs; in cvmx_pip_get_port_status()
431 * Kludge to fix Octeon Pass 1 errata - Drop counts in cvmx_pip_get_port_status()
434 if (status->inb_packets > status->packets) in cvmx_pip_get_port_status()
435 status->dropped_packets = in cvmx_pip_get_port_status()
436 status->inb_packets - status->packets; in cvmx_pip_get_port_status()
438 status->dropped_packets = 0; in cvmx_pip_get_port_status()
439 if (status->inb_octets - status->inb_packets * 4 > in cvmx_pip_get_port_status()
440 status->octets) in cvmx_pip_get_port_status()
441 status->dropped_octets = in cvmx_pip_get_port_status()
442 status->inb_octets - status->inb_packets * 4 - in cvmx_pip_get_port_status()
443 status->octets; in cvmx_pip_get_port_status()
445 status->dropped_octets = 0; in cvmx_pip_get_port_status()
450 * Configure the hardware CRC engine
454 * Invert the result of the CRC
457 * CRC initialization vector
514 while (len--) { in cvmx_pip_tag_mask_set()