1 /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */
2 #ifndef _LINUX_IF_LINK_H
3 #define _LINUX_IF_LINK_H
5 #include <linux/types.h>
6 #include <linux/netlink.h>
8 /* This struct should be in sync with struct rtnl_link_stats64 */
9 struct rtnl_link_stats
{
10 __u32 rx_packets
; /* total packets received */
11 __u32 tx_packets
; /* total packets transmitted */
12 __u32 rx_bytes
; /* total bytes received */
13 __u32 tx_bytes
; /* total bytes transmitted */
14 __u32 rx_errors
; /* bad packets received */
15 __u32 tx_errors
; /* packet transmit problems */
16 __u32 rx_dropped
; /* no space in linux buffers */
17 __u32 tx_dropped
; /* no space available in linux */
18 __u32 multicast
; /* multicast packets received */
21 /* detailed rx_errors: */
22 __u32 rx_length_errors
;
23 __u32 rx_over_errors
; /* receiver ring buff overflow */
24 __u32 rx_crc_errors
; /* recved pkt with crc error */
25 __u32 rx_frame_errors
; /* recv'd frame alignment error */
26 __u32 rx_fifo_errors
; /* recv'r fifo overrun */
27 __u32 rx_missed_errors
; /* receiver missed packet */
29 /* detailed tx_errors */
30 __u32 tx_aborted_errors
;
31 __u32 tx_carrier_errors
;
33 __u32 tx_heartbeat_errors
;
34 __u32 tx_window_errors
;
40 __u32 rx_nohandler
; /* dropped, no handler found */
43 /* The main device statistics structure */
44 struct rtnl_link_stats64
{
45 __u64 rx_packets
; /* total packets received */
46 __u64 tx_packets
; /* total packets transmitted */
47 __u64 rx_bytes
; /* total bytes received */
48 __u64 tx_bytes
; /* total bytes transmitted */
49 __u64 rx_errors
; /* bad packets received */
50 __u64 tx_errors
; /* packet transmit problems */
51 __u64 rx_dropped
; /* no space in linux buffers */
52 __u64 tx_dropped
; /* no space available in linux */
53 __u64 multicast
; /* multicast packets received */
56 /* detailed rx_errors: */
57 __u64 rx_length_errors
;
58 __u64 rx_over_errors
; /* receiver ring buff overflow */
59 __u64 rx_crc_errors
; /* recved pkt with crc error */
60 __u64 rx_frame_errors
; /* recv'd frame alignment error */
61 __u64 rx_fifo_errors
; /* recv'r fifo overrun */
62 __u64 rx_missed_errors
; /* receiver missed packet */
64 /* detailed tx_errors */
65 __u64 tx_aborted_errors
;
66 __u64 tx_carrier_errors
;
68 __u64 tx_heartbeat_errors
;
69 __u64 tx_window_errors
;
75 __u64 rx_nohandler
; /* dropped, no handler found */
78 /* The struct should be in sync with struct ifmap */
79 struct rtnl_link_ifmap
{
90 * Contains nested attributes for address family specific attributes.
91 * Each address family may create a attribute with the address family
92 * number as type and create its own attribute structure in it.
97 * [IFLA_INET_CONF] = ...,
100 * [IFLA_INET6_FLAGS] = ...,
101 * [IFLA_INET6_CONF] = ...,
116 #define IFLA_COST IFLA_COST
118 #define IFLA_PRIORITY IFLA_PRIORITY
120 #define IFLA_MASTER IFLA_MASTER
121 IFLA_WIRELESS
, /* Wireless Extension event - see wireless.h */
122 #define IFLA_WIRELESS IFLA_WIRELESS
123 IFLA_PROTINFO
, /* Protocol specific information for a link */
124 #define IFLA_PROTINFO IFLA_PROTINFO
126 #define IFLA_TXQLEN IFLA_TXQLEN
128 #define IFLA_MAP IFLA_MAP
130 #define IFLA_WEIGHT IFLA_WEIGHT
134 #define IFLA_LINKINFO IFLA_LINKINFO
137 IFLA_NUM_VF
, /* Number of VFs if device is SR-IOV PF */
143 IFLA_GROUP
, /* Group the device belongs to */
145 IFLA_EXT_MASK
, /* Extended info mask, VFs, etc */
146 IFLA_PROMISCUITY
, /* Promiscuity count: > 0 means acts PROMISC */
147 #define IFLA_PROMISCUITY IFLA_PROMISCUITY
152 IFLA_CARRIER_CHANGES
,
164 IFLA_TARGET_NETNSID
= IFLA_IF_NETNSID
, /* new alias */
165 IFLA_CARRIER_UP_COUNT
,
166 IFLA_CARRIER_DOWN_COUNT
,
171 IFLA_ALT_IFNAME
, /* Alternative ifname */
177 #define IFLA_MAX (__IFLA_MAX - 1)
179 /* backwards compatibility for userspace */
180 #define IFLA_RTA(r) ((struct rtattr*)(((char*)(r)) + NLMSG_ALIGN(sizeof(struct ifinfomsg))))
181 #define IFLA_PAYLOAD(n) NLMSG_PAYLOAD(n,sizeof(struct ifinfomsg))
189 #define IFLA_INET_MAX (__IFLA_INET_MAX - 1)
196 IFF_LOOPBACK, IFF_BROADCAST and IFF_POINTOPOINT are
197 more not changeable by user. They describe link media
198 characteristics and set by device driver.
201 - Combination IFF_BROADCAST|IFF_POINTOPOINT is invalid
202 - If neither of these three flags are set;
203 the interface is NBMA.
205 - IFF_MULTICAST does not mean anything special:
206 multicasts can be used on all not-NBMA links.
207 IFF_MULTICAST means that this media uses special encapsulation
208 for multicast frames. Apparently, all IFF_POINTOPOINT and
209 IFF_BROADCAST devices are able to use multicasts too.
213 For usual devices it is equal ifi_index.
214 If it is a "virtual interface" (f.e. tunnel), ifi_link
215 can point to real physical interface (f.e. for bandwidth calculations),
216 or maybe 0, what means, that real media is unknown (usual
217 for IPIP tunnels, when route to endpoint is allowed to change)
220 /* Subtype attributes for IFLA_PROTINFO */
223 IFLA_INET6_FLAGS
, /* link flags */
224 IFLA_INET6_CONF
, /* sysctl parameters */
225 IFLA_INET6_STATS
, /* statistics */
226 IFLA_INET6_MCAST
, /* MC things. What of them? */
227 IFLA_INET6_CACHEINFO
, /* time values and max reasm size */
228 IFLA_INET6_ICMP6STATS
, /* statistics (icmpv6) */
229 IFLA_INET6_TOKEN
, /* device token */
230 IFLA_INET6_ADDR_GEN_MODE
, /* implicit address generator mode */
234 #define IFLA_INET6_MAX (__IFLA_INET6_MAX - 1)
236 enum in6_addr_gen_mode
{
237 IN6_ADDR_GEN_MODE_EUI64
,
238 IN6_ADDR_GEN_MODE_NONE
,
239 IN6_ADDR_GEN_MODE_STABLE_PRIVACY
,
240 IN6_ADDR_GEN_MODE_RANDOM
,
247 IFLA_BR_FORWARD_DELAY
,
253 IFLA_BR_VLAN_FILTERING
,
254 IFLA_BR_VLAN_PROTOCOL
,
255 IFLA_BR_GROUP_FWD_MASK
,
259 IFLA_BR_ROOT_PATH_COST
,
260 IFLA_BR_TOPOLOGY_CHANGE
,
261 IFLA_BR_TOPOLOGY_CHANGE_DETECTED
,
264 IFLA_BR_TOPOLOGY_CHANGE_TIMER
,
268 IFLA_BR_MCAST_ROUTER
,
269 IFLA_BR_MCAST_SNOOPING
,
270 IFLA_BR_MCAST_QUERY_USE_IFADDR
,
271 IFLA_BR_MCAST_QUERIER
,
272 IFLA_BR_MCAST_HASH_ELASTICITY
,
273 IFLA_BR_MCAST_HASH_MAX
,
274 IFLA_BR_MCAST_LAST_MEMBER_CNT
,
275 IFLA_BR_MCAST_STARTUP_QUERY_CNT
,
276 IFLA_BR_MCAST_LAST_MEMBER_INTVL
,
277 IFLA_BR_MCAST_MEMBERSHIP_INTVL
,
278 IFLA_BR_MCAST_QUERIER_INTVL
,
279 IFLA_BR_MCAST_QUERY_INTVL
,
280 IFLA_BR_MCAST_QUERY_RESPONSE_INTVL
,
281 IFLA_BR_MCAST_STARTUP_QUERY_INTVL
,
282 IFLA_BR_NF_CALL_IPTABLES
,
283 IFLA_BR_NF_CALL_IP6TABLES
,
284 IFLA_BR_NF_CALL_ARPTABLES
,
285 IFLA_BR_VLAN_DEFAULT_PVID
,
287 IFLA_BR_VLAN_STATS_ENABLED
,
288 IFLA_BR_MCAST_STATS_ENABLED
,
289 IFLA_BR_MCAST_IGMP_VERSION
,
290 IFLA_BR_MCAST_MLD_VERSION
,
291 IFLA_BR_VLAN_STATS_PER_PORT
,
292 IFLA_BR_MULTI_BOOLOPT
,
296 #define IFLA_BR_MAX (__IFLA_BR_MAX - 1)
298 struct ifla_bridge_id
{
300 __u8 addr
[6]; /* ETH_ALEN */
310 IFLA_BRPORT_STATE
, /* Spanning tree state */
311 IFLA_BRPORT_PRIORITY
, /* " priority */
312 IFLA_BRPORT_COST
, /* " cost */
313 IFLA_BRPORT_MODE
, /* mode (hairpin) */
314 IFLA_BRPORT_GUARD
, /* bpdu guard */
315 IFLA_BRPORT_PROTECT
, /* root port protection */
316 IFLA_BRPORT_FAST_LEAVE
, /* multicast fast leave */
317 IFLA_BRPORT_LEARNING
, /* mac learning */
318 IFLA_BRPORT_UNICAST_FLOOD
, /* flood unicast traffic */
319 IFLA_BRPORT_PROXYARP
, /* proxy ARP */
320 IFLA_BRPORT_LEARNING_SYNC
, /* mac learning sync from device */
321 IFLA_BRPORT_PROXYARP_WIFI
, /* proxy ARP for Wi-Fi */
322 IFLA_BRPORT_ROOT_ID
, /* designated root */
323 IFLA_BRPORT_BRIDGE_ID
, /* designated bridge */
324 IFLA_BRPORT_DESIGNATED_PORT
,
325 IFLA_BRPORT_DESIGNATED_COST
,
328 IFLA_BRPORT_TOPOLOGY_CHANGE_ACK
,
329 IFLA_BRPORT_CONFIG_PENDING
,
330 IFLA_BRPORT_MESSAGE_AGE_TIMER
,
331 IFLA_BRPORT_FORWARD_DELAY_TIMER
,
332 IFLA_BRPORT_HOLD_TIMER
,
334 IFLA_BRPORT_MULTICAST_ROUTER
,
336 IFLA_BRPORT_MCAST_FLOOD
,
337 IFLA_BRPORT_MCAST_TO_UCAST
,
338 IFLA_BRPORT_VLAN_TUNNEL
,
339 IFLA_BRPORT_BCAST_FLOOD
,
340 IFLA_BRPORT_GROUP_FWD_MASK
,
341 IFLA_BRPORT_NEIGH_SUPPRESS
,
342 IFLA_BRPORT_ISOLATED
,
343 IFLA_BRPORT_BACKUP_PORT
,
344 IFLA_BRPORT_MRP_RING_OPEN
,
347 #define IFLA_BRPORT_MAX (__IFLA_BRPORT_MAX - 1)
349 struct ifla_cacheinfo
{
351 __u32 tstamp
; /* ipv6InterfaceTable updated timestamp */
352 __u32 reachable_time
;
361 IFLA_INFO_SLAVE_KIND
,
362 IFLA_INFO_SLAVE_DATA
,
366 #define IFLA_INFO_MAX (__IFLA_INFO_MAX - 1)
374 IFLA_VLAN_EGRESS_QOS
,
375 IFLA_VLAN_INGRESS_QOS
,
380 #define IFLA_VLAN_MAX (__IFLA_VLAN_MAX - 1)
382 struct ifla_vlan_flags
{
388 IFLA_VLAN_QOS_UNSPEC
,
389 IFLA_VLAN_QOS_MAPPING
,
393 #define IFLA_VLAN_QOS_MAX (__IFLA_VLAN_QOS_MAX - 1)
395 struct ifla_vlan_qos_mapping
{
400 /* MACVLAN section */
405 IFLA_MACVLAN_MACADDR_MODE
,
406 IFLA_MACVLAN_MACADDR
,
407 IFLA_MACVLAN_MACADDR_DATA
,
408 IFLA_MACVLAN_MACADDR_COUNT
,
412 #define IFLA_MACVLAN_MAX (__IFLA_MACVLAN_MAX - 1)
415 MACVLAN_MODE_PRIVATE
= 1, /* don't talk to other macvlans */
416 MACVLAN_MODE_VEPA
= 2, /* talk to other ports through ext bridge */
417 MACVLAN_MODE_BRIDGE
= 4, /* talk to bridge ports directly */
418 MACVLAN_MODE_PASSTHRU
= 8,/* take over the underlying device */
419 MACVLAN_MODE_SOURCE
= 16,/* use source MAC address list to assign */
422 enum macvlan_macaddr_mode
{
425 MACVLAN_MACADDR_FLUSH
,
429 #define MACVLAN_FLAG_NOPROMISC 1
438 #define IFLA_VRF_MAX (__IFLA_VRF_MAX - 1)
441 IFLA_VRF_PORT_UNSPEC
,
446 #define IFLA_VRF_PORT_MAX (__IFLA_VRF_PORT_MAX - 1)
454 IFLA_MACSEC_CIPHER_SUITE
,
456 IFLA_MACSEC_ENCODING_SA
,
462 IFLA_MACSEC_REPLAY_PROTECT
,
463 IFLA_MACSEC_VALIDATION
,
469 #define IFLA_MACSEC_MAX (__IFLA_MACSEC_MAX - 1)
479 #define IFLA_XFRM_MAX (__IFLA_XFRM_MAX - 1)
481 enum macsec_validation_type
{
482 MACSEC_VALIDATE_DISABLED
= 0,
483 MACSEC_VALIDATE_CHECK
= 1,
484 MACSEC_VALIDATE_STRICT
= 2,
485 __MACSEC_VALIDATE_END
,
486 MACSEC_VALIDATE_MAX
= __MACSEC_VALIDATE_END
- 1,
489 enum macsec_offload
{
490 MACSEC_OFFLOAD_OFF
= 0,
491 MACSEC_OFFLOAD_PHY
= 1,
492 MACSEC_OFFLOAD_MAC
= 2,
493 __MACSEC_OFFLOAD_END
,
494 MACSEC_OFFLOAD_MAX
= __MACSEC_OFFLOAD_END
- 1,
505 #define IFLA_IPVLAN_MAX (__IFLA_IPVLAN_MAX - 1)
514 #define IPVLAN_F_PRIVATE 0x01
515 #define IPVLAN_F_VEPA 0x02
521 IFLA_VXLAN_GROUP
, /* group or remote address */
529 IFLA_VXLAN_PORT_RANGE
, /* source port */
534 IFLA_VXLAN_PORT
, /* destination port */
538 IFLA_VXLAN_UDP_ZERO_CSUM6_TX
,
539 IFLA_VXLAN_UDP_ZERO_CSUM6_RX
,
540 IFLA_VXLAN_REMCSUM_TX
,
541 IFLA_VXLAN_REMCSUM_RX
,
543 IFLA_VXLAN_REMCSUM_NOPARTIAL
,
544 IFLA_VXLAN_COLLECT_METADATA
,
547 IFLA_VXLAN_TTL_INHERIT
,
551 #define IFLA_VXLAN_MAX (__IFLA_VXLAN_MAX - 1)
553 struct ifla_vxlan_port_range
{
563 VXLAN_DF_MAX
= __VXLAN_DF_END
- 1,
573 IFLA_GENEVE_PORT
, /* destination port */
574 IFLA_GENEVE_COLLECT_METADATA
,
576 IFLA_GENEVE_UDP_CSUM
,
577 IFLA_GENEVE_UDP_ZERO_CSUM6_TX
,
578 IFLA_GENEVE_UDP_ZERO_CSUM6_RX
,
580 IFLA_GENEVE_TTL_INHERIT
,
584 #define IFLA_GENEVE_MAX (__IFLA_GENEVE_MAX - 1)
586 enum ifla_geneve_df
{
591 GENEVE_DF_MAX
= __GENEVE_DF_END
- 1,
594 /* Bareudp section */
598 IFLA_BAREUDP_ETHERTYPE
,
599 IFLA_BAREUDP_SRCPORT_MIN
,
600 IFLA_BAREUDP_MULTIPROTO_MODE
,
604 #define IFLA_BAREUDP_MAX (__IFLA_BAREUDP_MAX - 1)
612 #define IFLA_PPP_MAX (__IFLA_PPP_MAX - 1)
625 IFLA_GTP_PDP_HASHSIZE
,
629 #define IFLA_GTP_MAX (__IFLA_GTP_MAX - 1)
631 /* Bonding section */
636 IFLA_BOND_ACTIVE_SLAVE
,
640 IFLA_BOND_USE_CARRIER
,
641 IFLA_BOND_ARP_INTERVAL
,
642 IFLA_BOND_ARP_IP_TARGET
,
643 IFLA_BOND_ARP_VALIDATE
,
644 IFLA_BOND_ARP_ALL_TARGETS
,
646 IFLA_BOND_PRIMARY_RESELECT
,
647 IFLA_BOND_FAIL_OVER_MAC
,
648 IFLA_BOND_XMIT_HASH_POLICY
,
649 IFLA_BOND_RESEND_IGMP
,
650 IFLA_BOND_NUM_PEER_NOTIF
,
651 IFLA_BOND_ALL_SLAVES_ACTIVE
,
653 IFLA_BOND_LP_INTERVAL
,
654 IFLA_BOND_PACKETS_PER_SLAVE
,
655 IFLA_BOND_AD_LACP_RATE
,
658 IFLA_BOND_AD_ACTOR_SYS_PRIO
,
659 IFLA_BOND_AD_USER_PORT_KEY
,
660 IFLA_BOND_AD_ACTOR_SYSTEM
,
661 IFLA_BOND_TLB_DYNAMIC_LB
,
662 IFLA_BOND_PEER_NOTIF_DELAY
,
666 #define IFLA_BOND_MAX (__IFLA_BOND_MAX - 1)
669 IFLA_BOND_AD_INFO_UNSPEC
,
670 IFLA_BOND_AD_INFO_AGGREGATOR
,
671 IFLA_BOND_AD_INFO_NUM_PORTS
,
672 IFLA_BOND_AD_INFO_ACTOR_KEY
,
673 IFLA_BOND_AD_INFO_PARTNER_KEY
,
674 IFLA_BOND_AD_INFO_PARTNER_MAC
,
675 __IFLA_BOND_AD_INFO_MAX
,
678 #define IFLA_BOND_AD_INFO_MAX (__IFLA_BOND_AD_INFO_MAX - 1)
681 IFLA_BOND_SLAVE_UNSPEC
,
682 IFLA_BOND_SLAVE_STATE
,
683 IFLA_BOND_SLAVE_MII_STATUS
,
684 IFLA_BOND_SLAVE_LINK_FAILURE_COUNT
,
685 IFLA_BOND_SLAVE_PERM_HWADDR
,
686 IFLA_BOND_SLAVE_QUEUE_ID
,
687 IFLA_BOND_SLAVE_AD_AGGREGATOR_ID
,
688 IFLA_BOND_SLAVE_AD_ACTOR_OPER_PORT_STATE
,
689 IFLA_BOND_SLAVE_AD_PARTNER_OPER_PORT_STATE
,
690 __IFLA_BOND_SLAVE_MAX
,
693 #define IFLA_BOND_SLAVE_MAX (__IFLA_BOND_SLAVE_MAX - 1)
695 /* SR-IOV virtual function management section */
703 #define IFLA_VF_INFO_MAX (__IFLA_VF_INFO_MAX - 1)
707 IFLA_VF_MAC
, /* Hardware queue specific attributes */
708 IFLA_VF_VLAN
, /* VLAN ID and QoS */
709 IFLA_VF_TX_RATE
, /* Max TX Bandwidth Allocation */
710 IFLA_VF_SPOOFCHK
, /* Spoof Checking on/off switch */
711 IFLA_VF_LINK_STATE
, /* link state enable/disable/auto switch */
712 IFLA_VF_RATE
, /* Min and Max TX Bandwidth Allocation */
713 IFLA_VF_RSS_QUERY_EN
, /* RSS Redirection Table and Hash Key query
716 IFLA_VF_STATS
, /* network device statistics */
717 IFLA_VF_TRUST
, /* Trust VF */
718 IFLA_VF_IB_NODE_GUID
, /* VF Infiniband node GUID */
719 IFLA_VF_IB_PORT_GUID
, /* VF Infiniband port GUID */
720 IFLA_VF_VLAN_LIST
, /* nested list of vlans, option for QinQ */
721 IFLA_VF_BROADCAST
, /* VF broadcast */
725 #define IFLA_VF_MAX (__IFLA_VF_MAX - 1)
729 __u8 mac
[32]; /* MAX_ADDR_LEN */
732 struct ifla_vf_broadcast
{
736 struct ifla_vf_vlan
{
738 __u32 vlan
; /* 0 - 4095, 0 disables VLAN filter */
743 IFLA_VF_VLAN_INFO_UNSPEC
,
744 IFLA_VF_VLAN_INFO
, /* VLAN ID, QoS and VLAN protocol */
745 __IFLA_VF_VLAN_INFO_MAX
,
748 #define IFLA_VF_VLAN_INFO_MAX (__IFLA_VF_VLAN_INFO_MAX - 1)
749 #define MAX_VLAN_LIST_LEN 1
751 struct ifla_vf_vlan_info
{
753 __u32 vlan
; /* 0 - 4095, 0 disables VLAN filter */
755 __be16 vlan_proto
; /* VLAN protocol either 802.1Q or 802.1ad */
758 struct ifla_vf_tx_rate
{
760 __u32 rate
; /* Max TX bandwidth in Mbps, 0 disables throttling */
763 struct ifla_vf_rate
{
765 __u32 min_tx_rate
; /* Min Bandwidth in Mbps */
766 __u32 max_tx_rate
; /* Max Bandwidth in Mbps */
769 struct ifla_vf_spoofchk
{
774 struct ifla_vf_guid
{
780 IFLA_VF_LINK_STATE_AUTO
, /* link state of the uplink */
781 IFLA_VF_LINK_STATE_ENABLE
, /* link always up */
782 IFLA_VF_LINK_STATE_DISABLE
, /* link always down */
783 __IFLA_VF_LINK_STATE_MAX
,
786 struct ifla_vf_link_state
{
791 struct ifla_vf_rss_query_en
{
797 IFLA_VF_STATS_RX_PACKETS
,
798 IFLA_VF_STATS_TX_PACKETS
,
799 IFLA_VF_STATS_RX_BYTES
,
800 IFLA_VF_STATS_TX_BYTES
,
801 IFLA_VF_STATS_BROADCAST
,
802 IFLA_VF_STATS_MULTICAST
,
804 IFLA_VF_STATS_RX_DROPPED
,
805 IFLA_VF_STATS_TX_DROPPED
,
809 #define IFLA_VF_STATS_MAX (__IFLA_VF_STATS_MAX - 1)
811 struct ifla_vf_trust
{
816 /* VF ports management section
818 * Nested layout of set/get msg is:
833 IFLA_VF_PORT
, /* nest */
837 #define IFLA_VF_PORT_MAX (__IFLA_VF_PORT_MAX - 1)
841 IFLA_PORT_VF
, /* __u32 */
842 IFLA_PORT_PROFILE
, /* string */
843 IFLA_PORT_VSI_TYPE
, /* 802.1Qbg (pre-)standard VDP */
844 IFLA_PORT_INSTANCE_UUID
, /* binary UUID */
845 IFLA_PORT_HOST_UUID
, /* binary UUID */
846 IFLA_PORT_REQUEST
, /* __u8 */
847 IFLA_PORT_RESPONSE
, /* __u16, output only */
851 #define IFLA_PORT_MAX (__IFLA_PORT_MAX - 1)
853 #define PORT_PROFILE_MAX 40
854 #define PORT_UUID_MAX 16
855 #define PORT_SELF_VF -1
858 PORT_REQUEST_PREASSOCIATE
= 0,
859 PORT_REQUEST_PREASSOCIATE_RR
,
860 PORT_REQUEST_ASSOCIATE
,
861 PORT_REQUEST_DISASSOCIATE
,
865 PORT_VDP_RESPONSE_SUCCESS
= 0,
866 PORT_VDP_RESPONSE_INVALID_FORMAT
,
867 PORT_VDP_RESPONSE_INSUFFICIENT_RESOURCES
,
868 PORT_VDP_RESPONSE_UNUSED_VTID
,
869 PORT_VDP_RESPONSE_VTID_VIOLATION
,
870 PORT_VDP_RESPONSE_VTID_VERSION_VIOALTION
,
871 PORT_VDP_RESPONSE_OUT_OF_SYNC
,
872 /* 0x08-0xFF reserved for future VDP use */
873 PORT_PROFILE_RESPONSE_SUCCESS
= 0x100,
874 PORT_PROFILE_RESPONSE_INPROGRESS
,
875 PORT_PROFILE_RESPONSE_INVALID
,
876 PORT_PROFILE_RESPONSE_BADSTATE
,
877 PORT_PROFILE_RESPONSE_INSUFFICIENT_RESOURCES
,
878 PORT_PROFILE_RESPONSE_ERROR
,
881 struct ifla_port_vsi
{
884 __u8 vsi_type_version
;
900 IPOIB_MODE_DATAGRAM
= 0, /* using unreliable datagram QPs */
901 IPOIB_MODE_CONNECTED
= 1, /* using connected QPs */
904 #define IFLA_IPOIB_MAX (__IFLA_IPOIB_MAX - 1)
913 IFLA_HSR_MULTICAST_SPEC
, /* Last byte of supervision addr */
914 IFLA_HSR_SUPERVISION_ADDR
, /* Supervision frame multicast addr */
916 IFLA_HSR_VERSION
, /* HSR version */
920 #define IFLA_HSR_MAX (__IFLA_HSR_MAX - 1)
924 struct if_stats_msg
{
932 /* A stats attribute can be netdev specific or a global stat.
933 * For netdev stats, lets use the prefix IFLA_STATS_LINK_*
936 IFLA_STATS_UNSPEC
, /* also used as 64bit pad attribute */
938 IFLA_STATS_LINK_XSTATS
,
939 IFLA_STATS_LINK_XSTATS_SLAVE
,
940 IFLA_STATS_LINK_OFFLOAD_XSTATS
,
945 #define IFLA_STATS_MAX (__IFLA_STATS_MAX - 1)
947 #define IFLA_STATS_FILTER_BIT(ATTR) (1 << (ATTR - 1))
949 /* These are embedded into IFLA_STATS_LINK_XSTATS:
950 * [IFLA_STATS_LINK_XSTATS]
951 * -> [LINK_XSTATS_TYPE_xxx]
952 * -> [rtnl link type specific attributes]
955 LINK_XSTATS_TYPE_UNSPEC
,
956 LINK_XSTATS_TYPE_BRIDGE
,
957 LINK_XSTATS_TYPE_BOND
,
958 __LINK_XSTATS_TYPE_MAX
960 #define LINK_XSTATS_TYPE_MAX (__LINK_XSTATS_TYPE_MAX - 1)
962 /* These are stats embedded into IFLA_STATS_LINK_OFFLOAD_XSTATS */
964 IFLA_OFFLOAD_XSTATS_UNSPEC
,
965 IFLA_OFFLOAD_XSTATS_CPU_HIT
, /* struct rtnl_link_stats64 */
966 __IFLA_OFFLOAD_XSTATS_MAX
968 #define IFLA_OFFLOAD_XSTATS_MAX (__IFLA_OFFLOAD_XSTATS_MAX - 1)
972 #define XDP_FLAGS_UPDATE_IF_NOEXIST (1U << 0)
973 #define XDP_FLAGS_SKB_MODE (1U << 1)
974 #define XDP_FLAGS_DRV_MODE (1U << 2)
975 #define XDP_FLAGS_HW_MODE (1U << 3)
976 #define XDP_FLAGS_REPLACE (1U << 4)
977 #define XDP_FLAGS_MODES (XDP_FLAGS_SKB_MODE | \
978 XDP_FLAGS_DRV_MODE | \
980 #define XDP_FLAGS_MASK (XDP_FLAGS_UPDATE_IF_NOEXIST | \
981 XDP_FLAGS_MODES | XDP_FLAGS_REPLACE)
983 /* These are stored into IFLA_XDP_ATTACHED on dump. */
985 XDP_ATTACHED_NONE
= 0,
998 IFLA_XDP_DRV_PROG_ID
,
999 IFLA_XDP_SKB_PROG_ID
,
1000 IFLA_XDP_HW_PROG_ID
,
1001 IFLA_XDP_EXPECTED_FD
,
1005 #define IFLA_XDP_MAX (__IFLA_XDP_MAX - 1)
1009 IFLA_EVENT_REBOOT
, /* internal reset / reboot */
1010 IFLA_EVENT_FEATURES
, /* change in offload features */
1011 IFLA_EVENT_BONDING_FAILOVER
, /* change in active slave */
1012 IFLA_EVENT_NOTIFY_PEERS
, /* re-sent grat. arp/ndisc */
1013 IFLA_EVENT_IGMP_RESEND
, /* re-sent IGMP JOIN */
1014 IFLA_EVENT_BONDING_OPTIONS
, /* change in bonding options */
1027 IFLA_TUN_MULTI_QUEUE
,
1028 IFLA_TUN_NUM_QUEUES
,
1029 IFLA_TUN_NUM_DISABLED_QUEUES
,
1033 #define IFLA_TUN_MAX (__IFLA_TUN_MAX - 1)
1037 #define RMNET_FLAGS_INGRESS_DEAGGREGATION (1U << 0)
1038 #define RMNET_FLAGS_INGRESS_MAP_COMMANDS (1U << 1)
1039 #define RMNET_FLAGS_INGRESS_MAP_CKSUMV4 (1U << 2)
1040 #define RMNET_FLAGS_EGRESS_MAP_CKSUMV4 (1U << 3)
1049 #define IFLA_RMNET_MAX (__IFLA_RMNET_MAX - 1)
1051 struct ifla_rmnet_flags
{
1056 #endif /* _LINUX_IF_LINK_H */