diff options
author | Dave Barach <dave@barachs.net> | 2020-08-19 06:59:53 -0400 |
---|---|---|
committer | Dave Barach <dave@barachs.net> | 2020-08-19 07:04:36 -0400 |
commit | e09ae01f6777434f41ba8a5a564c8078565ecfea (patch) | |
tree | 5cdea178576d79d1a8803401fb1e42cf1270a6f4 /src/vppinfra/elog.h | |
parent | 5c1cba5401b499b80bd46e783b5a444f18991922 (diff) |
vppinfra: minor tweaks for cgo interoperation
'type' is a keyword in golang, so s/type/event_type/ in elog.h and
elsewhere.
Add vec_len_not_inline(...), elog_write_file_not_inline(...) and
elog_read_file_not_inline(...) since the inline forms aren't usable.
More such tweaks may follow.
Type: improvement
Signed-off-by: Dave Barach <dave@barachs.net>
Change-Id: I9a80a6afa635f5cdedee554ee9abe400fafc1cb6
Diffstat (limited to 'src/vppinfra/elog.h')
-rw-r--r-- | src/vppinfra/elog.h | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/src/vppinfra/elog.h b/src/vppinfra/elog.h index 9f957e336d0..ee63d5b491b 100644 --- a/src/vppinfra/elog.h +++ b/src/vppinfra/elog.h @@ -68,7 +68,7 @@ typedef struct }; /** Event type index. */ - u16 type; + u16 event_type; /** Track for this event. Tracks allow events to be sorted and displayed by track. Think of 2 dimensional display with time and @@ -324,7 +324,7 @@ elog_event_data_inline (elog_main_t * em, e = vec_elt_at_index (em->event_ring, ei); e->time_cycles = cpu_time; - e->type = type_index; + e->event_type = type_index; e->track = track_index; /* Return user data for caller to fill in. */ @@ -543,6 +543,9 @@ elog_write_file (elog_main_t * em, char *clib_file, int flush_ring) return error; } +clib_error_t *elog_write_file_not_inline (elog_main_t * em, char *clib_file, + int flush_ring); + always_inline clib_error_t * elog_read_file (elog_main_t * em, char *clib_file) { @@ -558,6 +561,8 @@ elog_read_file (elog_main_t * em, char *clib_file) return error; } +clib_error_t *elog_read_file_not_inline (elog_main_t * em, char *clib_file); + #endif /* CLIB_UNIX */ #endif /* included_clib_elog_h */ |