aboutsummaryrefslogtreecommitdiffstats
path: root/openbsc/include/openbsc/gsm_data.h
diff options
context:
space:
mode:
authorHarald Welte <laforge@netfilter.org>2009-12-22 00:41:05 +0100
committerHarald Welte <laforge@netfilter.org>2009-12-22 00:41:05 +0100
commit24ff6ee0a343d46823771b9a86e867780eb2099b (patch)
tree2c8bd4dd014f9a851cbe1de9da39b4389ae6ccca /openbsc/include/openbsc/gsm_data.h
parenta992a36d5f9e7a2d1bb7948784c69ea2e342b7d3 (diff)
keep some internal statistics inside OpenBSC
the statistics will give us some idea about the network load and performance.
Diffstat (limited to 'openbsc/include/openbsc/gsm_data.h')
-rw-r--r--openbsc/include/openbsc/gsm_data.h45
1 files changed, 45 insertions, 0 deletions
diff --git a/openbsc/include/openbsc/gsm_data.h b/openbsc/include/openbsc/gsm_data.h
index 9d2549ca1..74e193832 100644
--- a/openbsc/include/openbsc/gsm_data.h
+++ b/openbsc/include/openbsc/gsm_data.h
@@ -457,6 +457,49 @@ struct gsm_bts {
struct llist_head trx_list;
};
+/* Some statistics of our network */
+struct gsmnet_stats {
+ struct {
+ unsigned long total;
+ unsigned long no_channel;
+ } chreq;
+ struct {
+ unsigned long attempted;
+ unsigned long no_channel; /* no channel available */
+ unsigned long timeout; /* T3103 timeout */
+ unsigned long completed; /* HO COMPL received */
+ unsigned long failed; /* HO FAIL received */
+ } handover;
+ struct {
+ unsigned long attach;
+ unsigned long normal;
+ unsigned long periodic;
+ unsigned long detach;
+ } loc_upd_type;
+ struct {
+ unsigned long reject;
+ unsigned long accept;
+ } loc_upd_resp;
+ struct {
+ unsigned long attempted;
+ unsigned long detached;
+ unsigned long completed;
+ unsigned long expired;
+ } paging;
+ struct {
+ unsigned long submitted; /* MO SMS submissions */
+ unsigned long no_receiver;
+ unsigned long delivered; /* MT SMS deliveries */
+ unsigned long rp_err_mem;
+ unsigned long rp_err_other;
+ } sms;
+ struct {
+ unsigned long dialled; /* total number of dialled calls */
+ unsigned long alerted; /* we alerted the other end */
+ unsigned long connected;/* how many calls were accepted */
+ } call;
+};
+
enum gsm_auth_policy {
GSM_AUTH_POLICY_CLOSED, /* only subscribers authorized in DB */
GSM_AUTH_POLICY_ACCEPT_ALL, /* accept everyone, even if not authorized in DB */
@@ -494,6 +537,8 @@ struct gsm_network {
unsigned int max_distance; /* TA values */
} handover;
+ struct gsmnet_stats stats;
+
/* layer 4 */
int (*mncc_recv) (struct gsm_network *net, int msg_type, void *arg);
struct llist_head upqueue;