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_LINUX_SEG6_H 8 #define _UAPI_LINUX_SEG6_H 9 #include <linux/types.h> 10 #include <linux/in6.h> 11 struct ipv6_sr_hdr { 12 __u8 nexthdr; 13 __u8 hdrlen; 14 __u8 type; 15 __u8 segments_left; 16 __u8 first_segment; 17 __u8 flags; 18 __u16 tag; 19 struct in6_addr segments[]; 20 }; 21 #define SR6_FLAG1_PROTECTED (1 << 6) 22 #define SR6_FLAG1_OAM (1 << 5) 23 #define SR6_FLAG1_ALERT (1 << 4) 24 #define SR6_FLAG1_HMAC (1 << 3) 25 #define SR6_TLV_INGRESS 1 26 #define SR6_TLV_EGRESS 2 27 #define SR6_TLV_OPAQUE 3 28 #define SR6_TLV_PADDING 4 29 #define SR6_TLV_HMAC 5 30 #define sr_has_hmac(srh) ((srh)->flags & SR6_FLAG1_HMAC) 31 struct sr6_tlv { 32 __u8 type; 33 __u8 len; 34 __u8 data[0]; 35 }; 36 #endif 37