1685343fcSTom GundersenWhat:		/sys/class/net/<iface>/name_assign_type
2685343fcSTom GundersenDate:		July 2014
3685343fcSTom GundersenKernelVersion:	3.17
4685343fcSTom GundersenContact:	netdev@vger.kernel.org
5685343fcSTom GundersenDescription:
6685343fcSTom Gundersen		Indicates the name assignment type. Possible values are:
7685343fcSTom Gundersen		1: enumerated by the kernel, possibly in an unpredictable way
8685343fcSTom Gundersen		2: predictably named by the kernel
9685343fcSTom Gundersen		3: named by userspace
10685343fcSTom Gundersen		4: renamed
11685343fcSTom Gundersen
1239f1a2f0SFlorian FainelliWhat:		/sys/class/net/<iface>/addr_assign_type
1339f1a2f0SFlorian FainelliDate:		July 2010
1439f1a2f0SFlorian FainelliKernelVersion:	3.2
1539f1a2f0SFlorian FainelliContact:	netdev@vger.kernel.org
1639f1a2f0SFlorian FainelliDescription:
1739f1a2f0SFlorian Fainelli		Indicates the address assignment type. Possible values are:
1839f1a2f0SFlorian Fainelli		0: permanent address
1939f1a2f0SFlorian Fainelli		1: randomly generated
2039f1a2f0SFlorian Fainelli		2: stolen from another device
2139f1a2f0SFlorian Fainelli		3: set using dev_set_mac_address
2239f1a2f0SFlorian Fainelli
2339f1a2f0SFlorian FainelliWhat:		/sys/class/net/<iface>/addr_len
2439f1a2f0SFlorian FainelliDate:		April 2005
2539f1a2f0SFlorian FainelliKernelVersion:	2.6.12
2639f1a2f0SFlorian FainelliContact:	netdev@vger.kernel.org
2739f1a2f0SFlorian FainelliDescription:
2839f1a2f0SFlorian Fainelli		Indicates the hardware address size in bytes.
2939f1a2f0SFlorian Fainelli		Values vary based on the lower-level protocol used by the
3039f1a2f0SFlorian Fainelli		interface (Ethernet, FDDI, ATM, IEEE 802.15.4...). See
3139f1a2f0SFlorian Fainelli		include/uapi/linux/if_*.h for actual values.
3239f1a2f0SFlorian Fainelli
3339f1a2f0SFlorian FainelliWhat:		/sys/class/net/<iface>/address
3439f1a2f0SFlorian FainelliDate:		April 2005
3539f1a2f0SFlorian FainelliKernelVersion:	2.6.12
3639f1a2f0SFlorian FainelliContact:	netdev@vger.kernel.org
3739f1a2f0SFlorian FainelliDescription:
3839f1a2f0SFlorian Fainelli		Hardware address currently assigned to this interface.
3939f1a2f0SFlorian Fainelli		Format is a string, e.g: 00:11:22:33:44:55 for an Ethernet MAC
4039f1a2f0SFlorian Fainelli		address.
4139f1a2f0SFlorian Fainelli
42784b58a3SBernhard ThalerWhat:		/sys/class/net/<bridge iface>/bridge/group_fwd_mask
43784b58a3SBernhard ThalerDate:		January 2012
44784b58a3SBernhard ThalerKernelVersion:	3.2
45784b58a3SBernhard ThalerContact:	netdev@vger.kernel.org
46784b58a3SBernhard ThalerDescription:
47784b58a3SBernhard Thaler		Bitmask to allow forwarding of link local frames with address
48784b58a3SBernhard Thaler		01-80-C2-00-00-0X on a bridge device. Only values that set bits
49784b58a3SBernhard Thaler		not matching BR_GROUPFWD_RESTRICTED in net/bridge/br_private.h
50784b58a3SBernhard Thaler		allowed.
51784b58a3SBernhard Thaler		Default value 0 does not forward any link local frames.
52784b58a3SBernhard Thaler
53784b58a3SBernhard Thaler		Restricted bits:
54784b58a3SBernhard Thaler		0: 01-80-C2-00-00-00 Bridge Group Address used for STP
55784b58a3SBernhard Thaler		1: 01-80-C2-00-00-01 (MAC Control) 802.3 used for MAC PAUSE
56784b58a3SBernhard Thaler		2: 01-80-C2-00-00-02 (Link Aggregation) 802.3ad
57784b58a3SBernhard Thaler
58784b58a3SBernhard Thaler		Any values not setting these bits can be used. Take special
59784b58a3SBernhard Thaler		care when forwarding control frames e.g. 802.1X-PAE or LLDP.
60784b58a3SBernhard Thaler
6139f1a2f0SFlorian FainelliWhat:		/sys/class/net/<iface>/broadcast
6239f1a2f0SFlorian FainelliDate:		April 2005
6339f1a2f0SFlorian FainelliKernelVersion:	2.6.12
6439f1a2f0SFlorian FainelliContact:	netdev@vger.kernel.org
6539f1a2f0SFlorian FainelliDescription:
6639f1a2f0SFlorian Fainelli		Hardware broadcast address for this interface. Format is a
6739f1a2f0SFlorian Fainelli		string, e.g: ff:ff:ff:ff:ff:ff for an Ethernet broadcast MAC
6839f1a2f0SFlorian Fainelli		address.
6939f1a2f0SFlorian Fainelli
7039f1a2f0SFlorian FainelliWhat:		/sys/class/net/<iface>/carrier
7139f1a2f0SFlorian FainelliDate:		April 2005
7239f1a2f0SFlorian FainelliKernelVersion:	2.6.12
7339f1a2f0SFlorian FainelliContact:	netdev@vger.kernel.org
7439f1a2f0SFlorian FainelliDescription:
7539f1a2f0SFlorian Fainelli		Indicates the current physical link state of the interface.
7639f1a2f0SFlorian Fainelli		Posssible values are:
7739f1a2f0SFlorian Fainelli		0: physical link is down
7839f1a2f0SFlorian Fainelli		1: physical link is up
7939f1a2f0SFlorian Fainelli
8039f1a2f0SFlorian Fainelli		Note: some special devices, e.g: bonding and team drivers will
8139f1a2f0SFlorian Fainelli		allow this attribute to be written to force a link state for
8239f1a2f0SFlorian Fainelli		operating correctly and designating another fallback interface.
8339f1a2f0SFlorian Fainelli
8439f1a2f0SFlorian FainelliWhat:		/sys/class/net/<iface>/dev_id
8539f1a2f0SFlorian FainelliDate:		April 2008
8639f1a2f0SFlorian FainelliKernelVersion:	2.6.26
8739f1a2f0SFlorian FainelliContact:	netdev@vger.kernel.org
8839f1a2f0SFlorian FainelliDescription:
8939f1a2f0SFlorian Fainelli		Indicates the device unique identifier. Format is an hexadecimal
9039f1a2f0SFlorian Fainelli		value. This is used to disambiguate interfaces which might be
9139f1a2f0SFlorian Fainelli		stacked (e.g: VLAN interfaces) but still have the same MAC
9239f1a2f0SFlorian Fainelli		address as their parent device.
9339f1a2f0SFlorian Fainelli
944c0b6534SArseny MaslennikovWhat:		/sys/class/net/<iface>/dev_port
954c0b6534SArseny MaslennikovDate:		February 2014
964c0b6534SArseny MaslennikovKernelVersion:	3.15
974c0b6534SArseny MaslennikovContact:	netdev@vger.kernel.org
984c0b6534SArseny MaslennikovDescription:
994c0b6534SArseny Maslennikov		Indicates the port number of this network device, formatted
1004c0b6534SArseny Maslennikov		as a decimal value. Some NICs have multiple independent ports
1014c0b6534SArseny Maslennikov		on the same PCI bus, device and function. This attribute allows
1024c0b6534SArseny Maslennikov		userspace to distinguish the respective interfaces.
1034c0b6534SArseny Maslennikov
1044c0b6534SArseny Maslennikov		Note: some device drivers started to use 'dev_id' for this
1054c0b6534SArseny Maslennikov		purpose since long before 3.15 and have not adopted the new
1064c0b6534SArseny Maslennikov		attribute ever since. To query the port number, some tools look
1074c0b6534SArseny Maslennikov		exclusively at 'dev_port', while others only consult 'dev_id'.
1084c0b6534SArseny Maslennikov		If a network device has multiple client adapter ports as
1094c0b6534SArseny Maslennikov		described in the previous paragraph and does not set this
1104c0b6534SArseny Maslennikov		attribute to its port number, it's a kernel bug.
1114c0b6534SArseny Maslennikov
11239f1a2f0SFlorian FainelliWhat:		/sys/class/net/<iface>/dormant
11339f1a2f0SFlorian FainelliDate:		March 2006
11439f1a2f0SFlorian FainelliKernelVersion:	2.6.17
11539f1a2f0SFlorian FainelliContact:	netdev@vger.kernel.org
11639f1a2f0SFlorian FainelliDescription:
11739f1a2f0SFlorian Fainelli		Indicates whether the interface is in dormant state. Possible
11839f1a2f0SFlorian Fainelli		values are:
11939f1a2f0SFlorian Fainelli		0: interface is not dormant
12039f1a2f0SFlorian Fainelli		1: interface is dormant
12139f1a2f0SFlorian Fainelli
12239f1a2f0SFlorian Fainelli		This attribute can be used by supplicant software to signal that
12339f1a2f0SFlorian Fainelli		the device is not usable unless some supplicant-based
12439f1a2f0SFlorian Fainelli		authentication is performed (e.g: 802.1x). 'link_mode' attribute
12539f1a2f0SFlorian Fainelli		will also reflect the dormant state.
12639f1a2f0SFlorian Fainelli
127*db30a577SAndrew LunnWhat:		/sys/class/net/<iface>/testing
128*db30a577SAndrew LunnDate:		April 2002
129*db30a577SAndrew LunnKernelVersion:	5.8
130*db30a577SAndrew LunnContact:	netdev@vger.kernel.org
131*db30a577SAndrew LunnDescription:
132*db30a577SAndrew Lunn		Indicates whether the interface is under test. Possible
133*db30a577SAndrew Lunn		values are:
134*db30a577SAndrew Lunn		0: interface is not being tested
135*db30a577SAndrew Lunn		1: interface is being tested
136*db30a577SAndrew Lunn
137*db30a577SAndrew Lunn		When an interface is under test, it cannot be expected
138*db30a577SAndrew Lunn		to pass packets as normal.
139*db30a577SAndrew Lunn
14039f1a2f0SFlorian FainelliWhat:		/sys/clas/net/<iface>/duplex
14139f1a2f0SFlorian FainelliDate:		October 2009
14239f1a2f0SFlorian FainelliKernelVersion:	2.6.33
14339f1a2f0SFlorian FainelliContact:	netdev@vger.kernel.org
14439f1a2f0SFlorian FainelliDescription:
14539f1a2f0SFlorian Fainelli		Indicates the interface latest or current duplex value. Possible
14639f1a2f0SFlorian Fainelli		values are:
14739f1a2f0SFlorian Fainelli		half: half duplex
14839f1a2f0SFlorian Fainelli		full: full duplex
14939f1a2f0SFlorian Fainelli
15039f1a2f0SFlorian Fainelli		Note: This attribute is only valid for interfaces that implement
1519b300495SMichal Kubecek		the ethtool get_link_ksettings method (mostly Ethernet).
15239f1a2f0SFlorian Fainelli
15339f1a2f0SFlorian FainelliWhat:		/sys/class/net/<iface>/flags
15439f1a2f0SFlorian FainelliDate:		April 2005
15539f1a2f0SFlorian FainelliKernelVersion:	2.6.12
15639f1a2f0SFlorian FainelliContact:	netdev@vger.kernel.org
15739f1a2f0SFlorian FainelliDescription:
15839f1a2f0SFlorian Fainelli		Indicates the interface flags as a bitmask in hexadecimal. See
15939f1a2f0SFlorian Fainelli		include/uapi/linux/if.h for a list of all possible values and
16039f1a2f0SFlorian Fainelli		the flags semantics.
16139f1a2f0SFlorian Fainelli
16239f1a2f0SFlorian FainelliWhat:		/sys/class/net/<iface>/ifalias
16339f1a2f0SFlorian FainelliDate:		September 2008
16439f1a2f0SFlorian FainelliKernelVersion:	2.6.28
16539f1a2f0SFlorian FainelliContact:	netdev@vger.kernel.org
16639f1a2f0SFlorian FainelliDescription:
16739f1a2f0SFlorian Fainelli		Indicates/stores an interface alias name as a string. This can
16839f1a2f0SFlorian Fainelli		be used for system management purposes.
16939f1a2f0SFlorian Fainelli
17039f1a2f0SFlorian FainelliWhat:		/sys/class/net/<iface>/ifindex
17139f1a2f0SFlorian FainelliDate:		April 2005
17239f1a2f0SFlorian FainelliKernelVersion:	2.6.12
17339f1a2f0SFlorian FainelliContact:	netdev@vger.kernel.org
17439f1a2f0SFlorian FainelliDescription:
17539f1a2f0SFlorian Fainelli		Indicates the system-wide interface unique index identifier as a
17639f1a2f0SFlorian Fainelli		decimal number. This attribute is used for mapping an interface
17739f1a2f0SFlorian Fainelli		identifier to an interface name. It is used throughout the
17839f1a2f0SFlorian Fainelli		networking stack for specifying the interface specific
17939f1a2f0SFlorian Fainelli		requests/events.
18039f1a2f0SFlorian Fainelli
18139f1a2f0SFlorian FainelliWhat:		/sys/class/net/<iface>/iflink
18239f1a2f0SFlorian FainelliDate:		April 2005
18339f1a2f0SFlorian FainelliKernelVersion:	2.6.12
18439f1a2f0SFlorian FainelliContact:	netdev@vger.kernel.org
18539f1a2f0SFlorian FainelliDescription:
18639f1a2f0SFlorian Fainelli		Indicates the system-wide interface unique index identifier a
18739f1a2f0SFlorian Fainelli		the interface is linked to. Format is decimal. This attribute is
18839f1a2f0SFlorian Fainelli		used to resolve interfaces chaining, linking and stacking.
18939f1a2f0SFlorian Fainelli		Physical interfaces have the same 'ifindex' and 'iflink' values.
19039f1a2f0SFlorian Fainelli
19139f1a2f0SFlorian FainelliWhat:		/sys/class/net/<iface>/link_mode
19239f1a2f0SFlorian FainelliDate:		March 2006
19339f1a2f0SFlorian FainelliKernelVersion:	2.6.17
19439f1a2f0SFlorian FainelliContact:	netdev@vger.kernel.org
19539f1a2f0SFlorian FainelliDescription:
19639f1a2f0SFlorian Fainelli		Indicates the interface link mode, as a decimal number. This
19739f1a2f0SFlorian Fainelli		attribute should be used in conjunction with 'dormant' attribute
19839f1a2f0SFlorian Fainelli		to determine the interface usability. Possible values:
19939f1a2f0SFlorian Fainelli		0: default link mode
20039f1a2f0SFlorian Fainelli		1: dormant link mode
20139f1a2f0SFlorian Fainelli
20239f1a2f0SFlorian FainelliWhat:		/sys/class/net/<iface>/mtu
20339f1a2f0SFlorian FainelliDate:		April 2005
20439f1a2f0SFlorian FainelliKernelVersion:	2.6.12
20539f1a2f0SFlorian FainelliContact:	netdev@vger.kernel.org
20639f1a2f0SFlorian FainelliDescription:
20739f1a2f0SFlorian Fainelli		Indicates the interface currently configured MTU value, in
20839f1a2f0SFlorian Fainelli		bytes, and in decimal format. Specific values depends on the
20939f1a2f0SFlorian Fainelli		lower-level interface protocol used. Ethernet devices will show
21039f1a2f0SFlorian Fainelli		a 'mtu' attribute value of 1500 unless changed.
21139f1a2f0SFlorian Fainelli
2121578ea3aSJunien FridrickWhat:		/sys/class/net/<iface>/netdev_group
21339f1a2f0SFlorian FainelliDate:		January 2011
21439f1a2f0SFlorian FainelliKernelVersion:	2.6.39
21539f1a2f0SFlorian FainelliContact:	netdev@vger.kernel.org
21639f1a2f0SFlorian FainelliDescription:
21739f1a2f0SFlorian Fainelli		Indicates the interface network device group, as a decimal
21839f1a2f0SFlorian Fainelli		integer. Default value is 0 which corresponds to the initial
21939f1a2f0SFlorian Fainelli		network devices group. The group can be changed to affect
22039f1a2f0SFlorian Fainelli		routing decisions (see: net/ipv4/fib_rules and
22139f1a2f0SFlorian Fainelli		net/ipv6/fib6_rules.c).
22239f1a2f0SFlorian Fainelli
22339f1a2f0SFlorian FainelliWhat:		/sys/class/net/<iface>/operstate
22439f1a2f0SFlorian FainelliDate:		March 2006
22539f1a2f0SFlorian FainelliKernelVersion:	2.6.17
22639f1a2f0SFlorian FainelliContact:	netdev@vger.kernel.org
22739f1a2f0SFlorian FainelliDescription:
22839f1a2f0SFlorian Fainelli		Indicates the interface RFC2863 operational state as a string.
22939f1a2f0SFlorian Fainelli		Possible values are:
23039f1a2f0SFlorian Fainelli		"unknown", "notpresent", "down", "lowerlayerdown", "testing",
23139f1a2f0SFlorian Fainelli		"dormant", "up".
23239f1a2f0SFlorian Fainelli
23379499bcaSFlorian FainelliWhat:		/sys/class/net/<iface>/phys_port_id
23479499bcaSFlorian FainelliDate:		July 2013
23579499bcaSFlorian FainelliKernelVersion:	3.12
23679499bcaSFlorian FainelliContact:	netdev@vger.kernel.org
23779499bcaSFlorian FainelliDescription:
23879499bcaSFlorian Fainelli		Indicates the interface unique physical port identifier within
23979499bcaSFlorian Fainelli		the NIC, as a string.
24079499bcaSFlorian Fainelli
241db24a904SDavid AhernWhat:		/sys/class/net/<iface>/phys_port_name
242db24a904SDavid AhernDate:		March 2015
243db24a904SDavid AhernKernelVersion:	4.0
244db24a904SDavid AhernContact:	netdev@vger.kernel.org
245db24a904SDavid AhernDescription:
246db24a904SDavid Ahern		Indicates the interface physical port name within the NIC,
247db24a904SDavid Ahern		as a string.
248db24a904SDavid Ahern
24939f1a2f0SFlorian FainelliWhat:		/sys/class/net/<iface>/speed
25039f1a2f0SFlorian FainelliDate:		October 2009
25139f1a2f0SFlorian FainelliKernelVersion:	2.6.33
25239f1a2f0SFlorian FainelliContact:	netdev@vger.kernel.org
25339f1a2f0SFlorian FainelliDescription:
25439f1a2f0SFlorian Fainelli		Indicates the interface latest or current speed value. Value is
25539f1a2f0SFlorian Fainelli		an integer representing the link speed in Mbits/sec.
25639f1a2f0SFlorian Fainelli
25739f1a2f0SFlorian Fainelli		Note: this attribute is only valid for interfaces that implement
2589b300495SMichal Kubecek		the ethtool get_link_ksettings method (mostly Ethernet).
25939f1a2f0SFlorian Fainelli
26039f1a2f0SFlorian FainelliWhat:		/sys/class/net/<iface>/tx_queue_len
26139f1a2f0SFlorian FainelliDate:		April 2005
26239f1a2f0SFlorian FainelliKernelVersion:	2.6.12
26339f1a2f0SFlorian FainelliContact:	netdev@vger.kernel.org
26439f1a2f0SFlorian FainelliDescription:
26539f1a2f0SFlorian Fainelli		Indicates the interface transmit queue len in number of packets,
26639f1a2f0SFlorian Fainelli		as an integer value. Value depend on the type of interface,
26739f1a2f0SFlorian Fainelli		Ethernet network adapters have a default value of 1000 unless
26839f1a2f0SFlorian Fainelli		configured otherwise
26939f1a2f0SFlorian Fainelli
27039f1a2f0SFlorian FainelliWhat:		/sys/class/net/<iface>/type
27139f1a2f0SFlorian FainelliDate:		April 2005
27239f1a2f0SFlorian FainelliKernelVersion:	2.6.12
27339f1a2f0SFlorian FainelliContact:	netdev@vger.kernel.org
27439f1a2f0SFlorian FainelliDescription:
27539f1a2f0SFlorian Fainelli		Indicates the interface protocol type as a decimal value. See
27639f1a2f0SFlorian Fainelli		include/uapi/linux/if_arp.h for all possible values.
277aecbe01eSJiri Pirko
278aecbe01eSJiri PirkoWhat:		/sys/class/net/<iface>/phys_switch_id
279aecbe01eSJiri PirkoDate:		November 2014
280aecbe01eSJiri PirkoKernelVersion:	3.19
281aecbe01eSJiri PirkoContact:	netdev@vger.kernel.org
282aecbe01eSJiri PirkoDescription:
283aecbe01eSJiri Pirko		Indicates the unique physical switch identifier of a switch this
284aecbe01eSJiri Pirko		port belongs to, as a string.
2858f602198SFlorian Fainelli
2868f602198SFlorian FainelliWhat:		/sys/class/net/<iface>/phydev
2878f602198SFlorian FainelliDate:		May 2017
2888f602198SFlorian FainelliKernelVersion:	4.13
2898f602198SFlorian FainelliContact:	netdev@vger.kernel.org
2908f602198SFlorian FainelliDescription:
2918f602198SFlorian Fainelli		Symbolic link to the PHY device this network device is attached
2928f602198SFlorian Fainelli		to.
293b2d3bcfaSDavid Decotigny
294b2d3bcfaSDavid DecotignyWhat:		/sys/class/net/<iface>/carrier_changes
295b2d3bcfaSDavid DecotignyDate:		Mar 2014
296b2d3bcfaSDavid DecotignyKernelVersion:	3.15
297b2d3bcfaSDavid DecotignyContact:	netdev@vger.kernel.org
298b2d3bcfaSDavid DecotignyDescription:
299b2d3bcfaSDavid Decotigny		32-bit unsigned integer counting the number of times the link has
300b2d3bcfaSDavid Decotigny		seen a change from UP to DOWN and vice versa
301b2d3bcfaSDavid Decotigny
302b2d3bcfaSDavid DecotignyWhat:		/sys/class/net/<iface>/carrier_up_count
303b2d3bcfaSDavid DecotignyDate:		Jan 2018
304b2d3bcfaSDavid DecotignyKernelVersion:	4.16
305b2d3bcfaSDavid DecotignyContact:	netdev@vger.kernel.org
306b2d3bcfaSDavid DecotignyDescription:
307b2d3bcfaSDavid Decotigny		32-bit unsigned integer counting the number of times the link has
308b2d3bcfaSDavid Decotigny		been up
309b2d3bcfaSDavid Decotigny
310b2d3bcfaSDavid DecotignyWhat:		/sys/class/net/<iface>/carrier_down_count
311b2d3bcfaSDavid DecotignyDate:		Jan 2018
312b2d3bcfaSDavid DecotignyKernelVersion:	4.16
313b2d3bcfaSDavid DecotignyContact:	netdev@vger.kernel.org
314b2d3bcfaSDavid DecotignyDescription:
315b2d3bcfaSDavid Decotigny		32-bit unsigned integer counting the number of times the link has
316b2d3bcfaSDavid Decotigny		been down
317