1 /* SPDX-License-Identifier: GPL-2.0+ WITH Linux-syscall-note */
3 * IPv6 IOAM implementation
6 * Justin Iurman <justin.iurman@uliege.be>
9 #ifndef _UAPI_LINUX_IOAM6_H
10 #define _UAPI_LINUX_IOAM6_H
12 #include <asm/byteorder.h>
13 #include <linux/types.h>
15 #define IOAM6_U16_UNAVAILABLE U16_MAX
16 #define IOAM6_U32_UNAVAILABLE U32_MAX
17 #define IOAM6_U64_UNAVAILABLE U64_MAX
19 #define IOAM6_DEFAULT_ID (IOAM6_U32_UNAVAILABLE >> 8)
20 #define IOAM6_DEFAULT_ID_WIDE (IOAM6_U64_UNAVAILABLE >> 8)
21 #define IOAM6_DEFAULT_IF_ID IOAM6_U16_UNAVAILABLE
22 #define IOAM6_DEFAULT_IF_ID_WIDE IOAM6_U32_UNAVAILABLE
25 * IPv6 IOAM Option Header
30 __u8
:8; /* reserved */
31 #define IOAM6_TYPE_PREALLOC 0
33 } __attribute__((packed
));
38 struct ioam6_trace_hdr
{
41 #if defined(__LITTLE_ENDIAN_BITFIELD)
71 bit23
:1, /* reserved */
83 #elif defined(__BIG_ENDIAN_BITFIELD)
109 bit12
:1, /* unused */
110 bit13
:1, /* unused */
111 bit14
:1, /* unused */
112 bit15
:1, /* unused */
113 bit16
:1, /* unused */
114 bit17
:1, /* unused */
115 bit18
:1, /* unused */
116 bit19
:1, /* unused */
117 bit20
:1, /* unused */
118 bit21
:1, /* unused */
120 bit23
:1, /* reserved */
126 #error "Please fix <asm/byteorder.h>"
129 #define IOAM6_TRACE_DATA_SIZE_MAX 244
131 } __attribute__((packed
));
133 #endif /* _UAPI_LINUX_IOAM6_H */