diff options
author | Pablo Neira Ayuso <pablo@gnumonks.org> | 2011-05-07 12:43:04 +0200 |
---|---|---|
committer | Pablo Neira Ayuso <pablo@gnumonks.org> | 2011-05-07 13:00:51 +0200 |
commit | 220abab3fa037e49188cc655084a26d3c3c44fd4 (patch) | |
tree | 11f4637df8e1873e307078e761b819905e0f68a5 /include/osmocom | |
parent | 9111d930a5586cb97ed4aca36234a638eb23bb55 (diff) |
statistics: use namespace prefix osmo_counter*
Summary of changes:
s/struct counter/struct osmo_counter/g
s/counter_inc/osmo_counter_inc/g
s/counter_get/osmo_counter_get/g
s/counter_reset/osmo_counter_reset/g
s/counter_alloc/osmo_counter_alloc/g
s/counter_free/osmo_counter_free/g
s/counters_for_each/osmo_counters_for_each/g
Diffstat (limited to 'include/osmocom')
-rw-r--r-- | include/osmocom/core/statistics.h | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/include/osmocom/core/statistics.h b/include/osmocom/core/statistics.h index 2c159657..18493277 100644 --- a/include/osmocom/core/statistics.h +++ b/include/osmocom/core/statistics.h @@ -1,33 +1,33 @@ #ifndef _STATISTICS_H #define _STATISTICS_H -struct counter { +struct osmo_counter { struct llist_head list; const char *name; const char *description; unsigned long value; }; -static inline void counter_inc(struct counter *ctr) +static inline void osmo_counter_inc(struct osmo_counter *ctr) { ctr->value++; } -static inline unsigned long counter_get(struct counter *ctr) +static inline unsigned long osmo_counter_get(struct osmo_counter *ctr) { return ctr->value; } -static inline void counter_reset(struct counter *ctr) +static inline void osmo_counter_reset(struct osmo_counter *ctr) { ctr->value = 0; } -struct counter *counter_alloc(const char *name); -void counter_free(struct counter *ctr); +struct osmo_counter *osmo_counter_alloc(const char *name); +void osmo_counter_free(struct osmo_counter *ctr); -int counters_for_each(int (*handle_counter)(struct counter *, void *), void *data); +int osmo_counters_for_each(int (*handle_counter)(struct osmo_counter *, void *), void *data); -struct counter *counter_get_by_name(const char *name); +struct osmo_counter *osmo_counter_get_by_name(const char *name); #endif /* _STATISTICS_H */ |