diff options
author | Andrew Tridgell <tridge@samba.org> | 2013-09-12 16:21:24 +1000 |
---|---|---|
committer | Lorenz Meier <lm@inf.ethz.ch> | 2013-09-12 09:25:08 +0200 |
commit | 7257642371f52a96c8d891795d090119437ea933 (patch) | |
tree | 21398dcd072381c4840df581e0fbca97a8927fd7 /src/modules/systemlib/perf_counter.h | |
parent | 0b7294a26ec33f707a9b5ddeee4269552b147e8b (diff) | |
download | px4-firmware-7257642371f52a96c8d891795d090119437ea933.tar.gz px4-firmware-7257642371f52a96c8d891795d090119437ea933.tar.bz2 px4-firmware-7257642371f52a96c8d891795d090119437ea933.zip |
perf: added perf_event_count() method
this allows drivers to get an event_count from a perf counter
Diffstat (limited to 'src/modules/systemlib/perf_counter.h')
-rw-r--r-- | src/modules/systemlib/perf_counter.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/modules/systemlib/perf_counter.h b/src/modules/systemlib/perf_counter.h index 4cd8b67a1..e1e3cbe95 100644 --- a/src/modules/systemlib/perf_counter.h +++ b/src/modules/systemlib/perf_counter.h @@ -135,6 +135,14 @@ __EXPORT extern void perf_print_all(void); */ __EXPORT extern void perf_reset_all(void); +/** + * Return current event_count + * + * @param handle The counter returned from perf_alloc. + * @return event_count + */ +__EXPORT extern uint64_t perf_event_count(perf_counter_t handle); + __END_DECLS #endif |