diff options
author | Harald Welte <laforge@gnumonks.org> | 2012-03-23 00:03:45 +0100 |
---|---|---|
committer | Harald Welte <laforge@gnumonks.org> | 2012-03-23 00:03:45 +0100 |
commit | 868b6d0c68f52385f7924e7d63eb1a5e92642f3a (patch) | |
tree | 81ea5fc541c1ede08a8f5297399decdd921bc9fd /firmware/include | |
parent | 4c0cf591b03148b9450d4009d2a3e908ec0c87a8 (diff) |
simtrace: introduce statisticsv0.5
the statistics count various events like overruns, parity errors,
missing rctx and can dump those stats via USB as well as on the serial
console.
Diffstat (limited to 'firmware/include')
-rw-r--r-- | firmware/include/simtrace_usb.h | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/firmware/include/simtrace_usb.h b/firmware/include/simtrace_usb.h index b8b62d3..08e4523 100644 --- a/firmware/include/simtrace_usb.h +++ b/firmware/include/simtrace_usb.h @@ -15,6 +15,7 @@ enum simtrace_usb_msgt { SIMTRACE_MSGT_NULL, SIMTRACE_MSGT_DATA, SIMTRACE_MSGT_RESET, /* reset was asserted, no more data */ + SIMTRACE_MSGT_STATS, /* statistics */ }; /* flags for MSGT_DATA */ @@ -22,4 +23,15 @@ enum simtrace_usb_msgt { #define SIMTRACE_FLAG_WTIME_EXP 0x04 /* work waiting time expired */ #define SIMTRACE_FLAG_PPS_FIDI 0x08 /* Fi/Di values in res[2] */ +struct simtrace_stats { + u_int32_t no_rctx; + u_int32_t rctx_sent; + u_int32_t rst; + u_int32_t pps; + u_int32_t bytes; + u_int32_t parity_err; + u_int32_t frame_err; + u_int32_t overrun; +} stats; + #endif /* SIMTRACE_USB_H */ |