xref: /rk3399_rockchip-uboot/include/linux/netdevice.h (revision 326ea986ac150acdc7656d57fca647db80b50158)
1c85d70efSVitaly Kuzmichev /*
2c85d70efSVitaly Kuzmichev  * INET		An implementation of the TCP/IP protocol suite for the LINUX
3c85d70efSVitaly Kuzmichev  *		operating system.  INET is implemented using the  BSD Socket
4c85d70efSVitaly Kuzmichev  *		interface as the means of communication with the user level.
5c85d70efSVitaly Kuzmichev  *
6c85d70efSVitaly Kuzmichev  *		Definitions for the Interfaces handler.
7c85d70efSVitaly Kuzmichev  *
8c85d70efSVitaly Kuzmichev  * Version:	@(#)dev.h	1.0.10	08/12/93
9c85d70efSVitaly Kuzmichev  *
10c85d70efSVitaly Kuzmichev  * Authors:	Ross Biro
11c85d70efSVitaly Kuzmichev  *		Fred N. van Kempen, <waltje@uWalt.NL.Mugnet.ORG>
12c85d70efSVitaly Kuzmichev  *		Corey Minyard <wf-rch!minyard@relay.EU.net>
13c85d70efSVitaly Kuzmichev  *		Donald J. Becker, <becker@cesdis.gsfc.nasa.gov>
14c85d70efSVitaly Kuzmichev  *		Alan Cox, <Alan.Cox@linux.org>
15c85d70efSVitaly Kuzmichev  *		Bjorn Ekwall. <bj0rn@blox.se>
16c85d70efSVitaly Kuzmichev  *              Pekka Riikonen <priikone@poseidon.pspt.fi>
17c85d70efSVitaly Kuzmichev  *
18*1a459660SWolfgang Denk  * SPDX-License-Identifier:	GPL-2.0+
19c85d70efSVitaly Kuzmichev  *
20c85d70efSVitaly Kuzmichev  *		Moved to /usr/include/linux for NET3
21c85d70efSVitaly Kuzmichev  */
22c85d70efSVitaly Kuzmichev #ifndef _LINUX_NETDEVICE_H
23c85d70efSVitaly Kuzmichev #define _LINUX_NETDEVICE_H
24c85d70efSVitaly Kuzmichev 
25c85d70efSVitaly Kuzmichev /*
26c85d70efSVitaly Kuzmichev  *	Network device statistics. Akin to the 2.0 ether stats but
27c85d70efSVitaly Kuzmichev  *	with byte counters.
28c85d70efSVitaly Kuzmichev  */
29c85d70efSVitaly Kuzmichev 
30c85d70efSVitaly Kuzmichev struct net_device_stats {
31c85d70efSVitaly Kuzmichev 	unsigned long	rx_packets;		/* total packets received	*/
32c85d70efSVitaly Kuzmichev 	unsigned long	tx_packets;		/* total packets transmitted	*/
33c85d70efSVitaly Kuzmichev 	unsigned long	rx_bytes;		/* total bytes received		*/
34c85d70efSVitaly Kuzmichev 	unsigned long	tx_bytes;		/* total bytes transmitted	*/
35c85d70efSVitaly Kuzmichev 	unsigned long	rx_errors;		/* bad packets received		*/
36c85d70efSVitaly Kuzmichev 	unsigned long	tx_errors;		/* packet transmit problems	*/
37c85d70efSVitaly Kuzmichev 	unsigned long	rx_dropped;		/* no space in linux buffers	*/
38c85d70efSVitaly Kuzmichev 	unsigned long	tx_dropped;		/* no space available in linux	*/
39c85d70efSVitaly Kuzmichev 	unsigned long	multicast;		/* multicast packets received	*/
40c85d70efSVitaly Kuzmichev 	unsigned long	collisions;
41c85d70efSVitaly Kuzmichev 
42c85d70efSVitaly Kuzmichev 	/* detailed rx_errors: */
43c85d70efSVitaly Kuzmichev 	unsigned long	rx_length_errors;
44c85d70efSVitaly Kuzmichev 	unsigned long	rx_over_errors;		/* receiver ring buff overflow	*/
45c85d70efSVitaly Kuzmichev 	unsigned long	rx_crc_errors;		/* recved pkt with crc error	*/
46c85d70efSVitaly Kuzmichev 	unsigned long	rx_frame_errors;	/* recv'd frame alignment error	*/
47c85d70efSVitaly Kuzmichev 	unsigned long	rx_fifo_errors;		/* recv'r fifo overrun		*/
48c85d70efSVitaly Kuzmichev 	unsigned long	rx_missed_errors;	/* receiver missed packet	*/
49c85d70efSVitaly Kuzmichev 
50c85d70efSVitaly Kuzmichev 	/* detailed tx_errors */
51c85d70efSVitaly Kuzmichev 	unsigned long	tx_aborted_errors;
52c85d70efSVitaly Kuzmichev 	unsigned long	tx_carrier_errors;
53c85d70efSVitaly Kuzmichev 	unsigned long	tx_fifo_errors;
54c85d70efSVitaly Kuzmichev 	unsigned long	tx_heartbeat_errors;
55c85d70efSVitaly Kuzmichev 	unsigned long	tx_window_errors;
56c85d70efSVitaly Kuzmichev 
57c85d70efSVitaly Kuzmichev 	/* for cslip etc */
58c85d70efSVitaly Kuzmichev 	unsigned long	rx_compressed;
59c85d70efSVitaly Kuzmichev 	unsigned long	tx_compressed;
60c85d70efSVitaly Kuzmichev };
61c85d70efSVitaly Kuzmichev 
62c85d70efSVitaly Kuzmichev #endif	/* _LINUX_NETDEVICE_H */
63