aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNeels Hofmeyr <nhofmeyr@sysmocom.de>2017-08-21 14:49:39 +0200
committerNeels Hofmeyr <nhofmeyr@sysmocom.de>2017-08-21 14:49:39 +0200
commit6270059e14b0d1dda05b48525a834bbef027da30 (patch)
tree8566cae236fe25b7a71224e89ebe83ca62897ce1
parent84b7e3723b8d7bf9bfd5db7ba5532c3d174c2c77 (diff)
Revert "factor out & introduce struct gsm_encr, in common_cs.h"
This reverts commit ac1f1436e9d380f632dd850fcd253d3480f0fc2d. common_cs.h added to gsm_data_shared.h was a mistake, i.e. I added the dependency by accident. Including common_cs.h in the debian installation may have seemed like the logical consequence but was not intended. AFAICT for osmo-msc, the need for struct gsm_encr is obsoleted by libvlr, gsm_encr will only be used in osmo-bsc and can just stay an inline struct. Related: OS#2272 Change-Id: I15d60441c6c6f053486c0482258a8759bdd92df1
-rw-r--r--openbsc/include/openbsc/common_cs.h8
-rw-r--r--openbsc/include/openbsc/gsm_data_shared.h9
2 files changed, 6 insertions, 11 deletions
diff --git a/openbsc/include/openbsc/common_cs.h b/openbsc/include/openbsc/common_cs.h
index 6dc956f80..4282064d0 100644
--- a/openbsc/include/openbsc/common_cs.h
+++ b/openbsc/include/openbsc/common_cs.h
@@ -9,14 +9,6 @@ typedef int (*mncc_recv_cb_t)(struct gsm_network *, struct msgb *);
struct vty;
-#define MAX_A5_KEY_LEN (128/8)
-
-struct gsm_encr {
- uint8_t alg_id;
- uint8_t key_len;
- uint8_t key[MAX_A5_KEY_LEN];
-};
-
struct gsm_network *gsm_network_init(void *ctx,
uint16_t country_code,
uint16_t network_code,
diff --git a/openbsc/include/openbsc/gsm_data_shared.h b/openbsc/include/openbsc/gsm_data_shared.h
index 369668df3..6b2269e1b 100644
--- a/openbsc/include/openbsc/gsm_data_shared.h
+++ b/openbsc/include/openbsc/gsm_data_shared.h
@@ -24,8 +24,6 @@
#include <osmocom/gsm/lapdm.h>
#endif
-#include <openbsc/common_cs.h>
-
/* 16 is the max. number of SI2quater messages according to 3GPP TS 44.018 Table 10.5.2.33b.1:
4-bit index is used (2#1111 = 10#15) */
#define SI2Q_MAX_NUM 16
@@ -131,6 +129,7 @@ struct om2k_mo {
struct osmo_fsm_inst *fsm;
};
+#define MAX_A5_KEY_LEN (128/8)
#define A38_XOR_MIN_KEY_LEN 12
#define A38_XOR_MAX_KEY_LEN 16
#define A38_COMP128_KEY_LEN 16
@@ -232,7 +231,11 @@ struct gsm_lchan {
uint8_t bs_power;
uint8_t ms_power;
/* Encryption information */
- struct gsm_encr encr;
+ struct {
+ uint8_t alg_id;
+ uint8_t key_len;
+ uint8_t key[MAX_A5_KEY_LEN];
+ } encr;
/* AMR bits */
uint8_t mr_ms_lv[7];