FD.io VPP  v18.04-17-g3a0d853
Vector Packet Processing
trace_util.h File Reference
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  trace_profile_
 Usage: More...
 
struct  trace_main_t
 
struct  ioam_trace_if_ts_app_t
 
struct  ioam_trace_if_t
 
struct  ioam_trace_ts_t
 
struct  ioam_trace_app_t
 
struct  ioam_trace_ts_app_t
 

Macros

#define debug_ioam   debug_ioam_fn
 
#define BIT_TTL_NODEID   (1<<0)
 
#define BIT_ING_INTERFACE   (1<<1)
 
#define BIT_EGR_INTERFACE   (1<<2)
 
#define BIT_TIMESTAMP   (1<<3)
 
#define BIT_APPDATA   (1<<4)
 
#define BIT_LOOPBACK   (1<<5)
 
#define BIT_LOOPBACK_REPLY   (1<<6)
 
#define TRACE_TYPE_MASK   0x7F /* Mask of all above bits */
 
#define TRACE_TYPE_IF_TS_APP_LOOP   0x3F
 
#define TRACE_TYPE_IF_TS_APP   0x1f
 
#define TRACE_TYPE_IF   0x03
 
#define TRACE_TYPE_TS   0x09
 
#define TRACE_TYPE_APP   0x11
 
#define TRACE_TYPE_TS_APP   0x19
 
#define TSP_SECONDS   0
 
#define TSP_MILLISECONDS   1
 
#define TSP_MICROSECONDS   2
 
#define TSP_NANOSECONDS   3
 

Typedefs

typedef struct trace_profile_ trace_profile
 Usage: More...
 

Functions

int trace_util_init (void)
 
int trace_profile_create (trace_profile *profile, u8 trace_type, u8 num_elts, u32 trace_tsp, u32 node_id, u32 app_data)
 
void clear_trace_profiles (void)
 
typedef CLIB_PACKED (struct{u8 ioam_trace_type;u8 data_list_elts_left;u32 elts[0];}) ioam_trace_hdr_t
 
static u8 fetch_trace_data_size (u16 trace_type)
 
static void ioam_trace_set_bit (ioam_trace_hdr_t *trace_hdr, u8 trace_bit)
 
static void ioam_trace_reset_bit (ioam_trace_hdr_t *trace_hdr, u8 trace_bit)
 
int ioam_trace_get_sizeof_handler (u32 *result)
 
int ip6_trace_profile_setup (void)
 
int ip6_trace_profile_cleanup (void)
 

Macro Definition Documentation

#define BIT_APPDATA   (1<<4)

Definition at line 93 of file trace_util.h.

#define BIT_EGR_INTERFACE   (1<<2)

Definition at line 91 of file trace_util.h.

#define BIT_ING_INTERFACE   (1<<1)

Definition at line 90 of file trace_util.h.

#define BIT_LOOPBACK   (1<<5)

Definition at line 94 of file trace_util.h.

#define BIT_LOOPBACK_REPLY   (1<<6)

Definition at line 95 of file trace_util.h.

#define BIT_TIMESTAMP   (1<<3)

Definition at line 92 of file trace_util.h.

#define BIT_TTL_NODEID   (1<<0)

Definition at line 89 of file trace_util.h.

#define debug_ioam   debug_ioam_fn

Definition at line 21 of file trace_util.h.

#define TRACE_TYPE_APP   0x11

Definition at line 179 of file trace_util.h.

#define TRACE_TYPE_IF   0x03

Definition at line 138 of file trace_util.h.

#define TRACE_TYPE_IF_TS_APP   0x1f

Definition at line 116 of file trace_util.h.

#define TRACE_TYPE_IF_TS_APP_LOOP   0x3F

Definition at line 98 of file trace_util.h.

#define TRACE_TYPE_MASK   0x7F /* Mask of all above bits */

Definition at line 96 of file trace_util.h.

#define TRACE_TYPE_TS   0x09

Definition at line 158 of file trace_util.h.

#define TRACE_TYPE_TS_APP   0x19

Definition at line 200 of file trace_util.h.

#define TSP_MICROSECONDS   2

Definition at line 245 of file trace_util.h.

#define TSP_MILLISECONDS   1

Definition at line 244 of file trace_util.h.

#define TSP_NANOSECONDS   3

Definition at line 246 of file trace_util.h.

#define TSP_SECONDS   0

Definition at line 243 of file trace_util.h.

Typedef Documentation

typedef struct trace_profile_ trace_profile

Usage:

On any node that participates in iOAM Trace.

Step 1: Initialize this library by calling trace_init() Step 2: Setup a trace profile that contains all the parameters needed to compute cumulative: Call these functions: trace_profile_find trace_profile_create Step 2a: On initial node enable the profile to be used: trace_profile_set_active / trace_profile_get_active will return the profile Step 4: TBD trace_validate

Function Documentation

void clear_trace_profiles ( void  )

Definition at line 96 of file trace_util.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

typedef CLIB_PACKED ( struct{u8 ioam_trace_type;u8 data_list_elts_left;u32 elts[0];}  )
static u8 fetch_trace_data_size ( u16  trace_type)
inlinestatic

Definition at line 209 of file trace_util.h.

+ Here is the caller graph for this function:

int ioam_trace_get_sizeof_handler ( u32 result)

+ Here is the caller graph for this function:

static void ioam_trace_reset_bit ( ioam_trace_hdr_t *  trace_hdr,
u8  trace_bit 
)
inlinestatic

Definition at line 234 of file trace_util.h.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

static void ioam_trace_set_bit ( ioam_trace_hdr_t *  trace_hdr,
u8  trace_bit 
)
inlinestatic

Definition at line 228 of file trace_util.h.

+ Here is the caller graph for this function:

int ip6_trace_profile_cleanup ( void  )

Definition at line 456 of file ip6_ioam_trace.c.

+ Here is the caller graph for this function:

int ip6_trace_profile_setup ( void  )

Definition at line 468 of file ip6_ioam_trace.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

int trace_profile_create ( trace_profile profile,
u8  trace_type,
u8  num_elts,
u32  trace_tsp,
u32  node_id,
u32  app_data 
)

Definition at line 57 of file trace_util.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

int trace_util_init ( void  )

Definition at line 47 of file trace_util.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function: