diff options
author | Harald Welte <laforge@netfilter.org> | 2009-12-22 13:09:29 +0100 |
---|---|---|
committer | Harald Welte <laforge@netfilter.org> | 2009-12-22 13:11:28 +0100 |
commit | b908cb7e0ed9e10ee7ced8083d4abdfb9ca2e61c (patch) | |
tree | 1797293a9ebf7dca69dc303abf4d003e59802d0b /openbsc/include/openbsc/chan_alloc.h | |
parent | c80210641a68a6ca07274f0319ba03d7521c2b3e (diff) |
Display current channel usage load in 'show bts' and 'show network'
This is just the load at one given instant. We definitely also want to see
some averages and record the measurements in a database later.
Diffstat (limited to 'openbsc/include/openbsc/chan_alloc.h')
-rw-r--r-- | openbsc/include/openbsc/chan_alloc.h | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/openbsc/include/openbsc/chan_alloc.h b/openbsc/include/openbsc/chan_alloc.h index 38855d1ee..fa8663056 100644 --- a/openbsc/include/openbsc/chan_alloc.h +++ b/openbsc/include/openbsc/chan_alloc.h @@ -49,4 +49,16 @@ void lchan_free(struct gsm_lchan *lchan); /* Consider releasing the channel */ int lchan_auto_release(struct gsm_lchan *lchan); +struct load_counter { + unsigned int total; + unsigned int used; +}; + +struct pchan_load { + struct load_counter pchan[GSM_PCHAN_UNKNOWN]; +}; + +void bts_chan_load(struct pchan_load *cl, const struct gsm_bts *bts); +void network_chan_load(struct pchan_load *pl, struct gsm_network *net); + #endif /* _CHAN_ALLOC_H */ |