* use 16bit for network and country code
* use aligned attribute for more data structures
* add command line arguments for operator/country code
diff --git a/src/bsc_hack.c b/src/bsc_hack.c
index 3076758..aab4d0f 100644
--- a/src/bsc_hack.c
+++ b/src/bsc_hack.c
@@ -587,20 +587,21 @@
(struct gsm48_system_information_type_4*)&si4;
struct gsm48_system_information_type_6 *type_6 =
(struct gsm48_system_information_type_6*)&si6;
+ struct gsm48_loc_area_id lai;
+
+ gsm0408_generate_lai(&lai, bts->network->country_code,
+ bts->network->network_code, bts->location_area_code);
/* assign the MCC and MNC */
- gsm0408_generate_lai(&type_3->lai, bts->network->country_code,
- bts->network->network_code, bts->location_area_code);
- gsm0408_generate_lai(&type_4->lai, bts->network->country_code,
- bts->network->network_code, bts->location_area_code);
- gsm0408_generate_lai(&type_6->lai, bts->network->country_code,
- bts->network->network_code, bts->location_area_code);
+ type_3->lai = lai;
+ type_4->lai = lai;
+ type_6->lai = lai;
}
static void bootstrap_rsl(struct gsm_bts *bts)
{
- fprintf(stdout, "bootstrapping RSL\n");
+ fprintf(stdout, "bootstrapping RSL MCC=%u MNC=%u\n", MCC, MNC);
patch_tables(bts);
set_system_infos(bts);
diff --git a/src/gsm_data.c b/src/gsm_data.c
index 61f8682..ed81954 100644
--- a/src/gsm_data.c
+++ b/src/gsm_data.c
@@ -24,8 +24,8 @@
#include <openbsc/gsm_data.h>
-struct gsm_network *gsm_network_init(unsigned int num_bts, u_int8_t country_code,
- u_int8_t network_code)
+struct gsm_network *gsm_network_init(unsigned int num_bts, u_int16_t country_code,
+ u_int16_t network_code)
{
int i;
struct gsm_network *net;