1 /*
2  * This file is auto-generated. Modifications will be lost.
3  *
4  * See https://android.googlesource.com/platform/bionic/+/master/libc/kernel/
5  * for more information.
6  */
7 #ifndef _UAPI_MPLS_H
8 #define _UAPI_MPLS_H
9 #include <linux/types.h>
10 #include <asm/byteorder.h>
11 struct mpls_label {
12   __be32 entry;
13 };
14 #define MPLS_LS_LABEL_MASK 0xFFFFF000
15 #define MPLS_LS_LABEL_SHIFT 12
16 #define MPLS_LS_TC_MASK 0x00000E00
17 #define MPLS_LS_TC_SHIFT 9
18 #define MPLS_LS_S_MASK 0x00000100
19 #define MPLS_LS_S_SHIFT 8
20 #define MPLS_LS_TTL_MASK 0x000000FF
21 #define MPLS_LS_TTL_SHIFT 0
22 #define MPLS_LABEL_IPV4NULL 0
23 #define MPLS_LABEL_RTALERT 1
24 #define MPLS_LABEL_IPV6NULL 2
25 #define MPLS_LABEL_IMPLNULL 3
26 #define MPLS_LABEL_ENTROPY 7
27 #define MPLS_LABEL_GAL 13
28 #define MPLS_LABEL_OAMALERT 14
29 #define MPLS_LABEL_EXTENSION 15
30 #define MPLS_LABEL_FIRST_UNRESERVED 16
31 enum {
32   MPLS_STATS_UNSPEC,
33   MPLS_STATS_LINK,
34   __MPLS_STATS_MAX,
35 };
36 #define MPLS_STATS_MAX (__MPLS_STATS_MAX - 1)
37 struct mpls_link_stats {
38   __u64 rx_packets;
39   __u64 tx_packets;
40   __u64 rx_bytes;
41   __u64 tx_bytes;
42   __u64 rx_errors;
43   __u64 tx_errors;
44   __u64 rx_dropped;
45   __u64 tx_dropped;
46   __u64 rx_noroute;
47 };
48 #endif
49