summaryrefslogtreecommitdiffstats
path: root/src/vat/vat.h
diff options
context:
space:
mode:
authorDave Barach <dave@barachs.net>2017-01-20 19:50:09 -0500
committerDamjan Marion <dmarion.lists@gmail.com>2017-01-23 15:17:25 +0000
commitfe6bdfd84573cd8813a211f9094ee734f088ce16 (patch)
tree68c109d579ebbcb64c2a0e9af379aaf0522c0c0b /src/vat/vat.h
parent675a69cdf6eb1a8e60613bef4a918fe1b354c276 (diff)
binary-api debug CLI works with plugins
Change-Id: I81f33f5153d5afac94b66b5a8cb91da77463af79 Signed-off-by: Dave Barach <dave@barachs.net>
Diffstat (limited to 'src/vat/vat.h')
-rw-r--r--src/vat/vat.h33
1 files changed, 4 insertions, 29 deletions
diff --git a/src/vat/vat.h b/src/vat/vat.h
index 64be2f7f97f..3d7d96ae566 100644
--- a/src/vat/vat.h
+++ b/src/vat/vat.h
@@ -190,36 +190,11 @@ typedef struct
vlib_main_t *vlib_main;
} vat_main_t;
-vat_main_t vat_main;
-
-static inline f64
-vat_time_now (vat_main_t * vam)
-{
-#if VPP_API_TEST_BUILTIN
- return vlib_time_now (vam->vlib_main);
-#else
- return clib_time_now (&vam->clib_time);
-#endif
-}
-
-#if VPP_API_TEST_BUILTIN
-#define errmsg(fmt,args...) \
-do { \
- vat_main_t *__vam = &vat_main; \
- vlib_cli_output (__vam->vlib_main, fmt, ##args); \
- } while(0);
-#else
-#define errmsg(fmt,args...) \
-do { \
- vat_main_t *__vam = &vat_main; \
- if(__vam->ifp != stdin) \
- fformat(__vam->ofp,"%s(%d): \n", __vam->current_file, \
- __vam->input_line_number); \
- fformat(__vam->ofp, fmt "\n", ##args); \
- fflush(__vam->ofp); \
-} while(0);
-#endif
+extern vat_main_t vat_main;
+void vat_suspend (vlib_main_t * vm, f64 interval);
+f64 vat_time_now (vat_main_t * vam);
+void errmsg (char *fmt, ...);
void vat_api_hookup (vat_main_t * vam);
int api_sw_interface_dump (vat_main_t * vam);
void do_one_file (vat_main_t * vam);