[paging] Move the paging state into struct gsm_bts
There is a 1:1 relationship between gsm_bts and the paging
operation. Move the paging state into the gsm_bts which is
simplfying the code a lot. This was hinted by LaF0rge.
(I'm not happy with the names of the structs)
diff --git a/src/bsc_hack.c b/src/bsc_hack.c
index 6e54b93..cadf41c 100644
--- a/src/bsc_hack.c
+++ b/src/bsc_hack.c
@@ -672,7 +672,6 @@
static int bootstrap_network(void)
{
struct gsm_bts *bts;
- struct paging_bts *paging_bts;
/* initialize our data structures */
gsmnet = gsm_network_init(1, MCC, MNC);
@@ -694,8 +693,8 @@
patch_tables(bts);
- paging_bts = page_allocate(bts);
- paging_bts->channel_allocated = bsc_hack_channel_allocated;
+ page_init(bts);
+ bts->paging.channel_allocated = bsc_hack_channel_allocated;
telnet_init(gsmnet, 4242);
if (mi_setup(bts, 0, mi_cb) < 0)