Commit a6d1aa8d authored by Rohit Gupta's avatar Rohit Gupta
Browse files

Merge branch 'develop' into feature-34-test_framework

parents 8b849e5c 9eec54ae
...@@ -130,7 +130,7 @@ int emm_proc_status(unsigned int ueid, int emm_cause) ...@@ -130,7 +130,7 @@ int emm_proc_status(unsigned int ueid, int emm_cause)
emm_sap_t emm_sap; emm_sap_t emm_sap;
emm_security_context_t *sctx = NULL; emm_security_context_t *sctx = NULL;
struct emm_data_context_s *ctx = NULL; //struct emm_data_context_s *ctx = NULL;
LOG_TRACE(INFO,"EMM-PROC - EMM status procedure requested"); LOG_TRACE(INFO,"EMM-PROC - EMM status procedure requested");
......
...@@ -261,7 +261,7 @@ int lowerlayer_data_req(unsigned int ueid, const OctetString *data) ...@@ -261,7 +261,7 @@ int lowerlayer_data_req(unsigned int ueid, const OctetString *data)
int rc; int rc;
emm_sap_t emm_sap; emm_sap_t emm_sap;
emm_security_context_t *sctx = NULL; emm_security_context_t *sctx = NULL;
struct emm_data_context_s *ctx = NULL; //struct emm_data_context_s *ctx = NULL;
emm_sap.primitive = EMMAS_DATA_REQ; emm_sap.primitive = EMMAS_DATA_REQ;
emm_sap.u.emm_as.u.data.guti = _emm_data.guti; emm_sap.u.emm_as.u.data.guti = _emm_data.guti;
......
...@@ -215,7 +215,7 @@ emm_fsm_state_t _emm_fsm_status[EMM_FSM_NB_UE_MAX]; ...@@ -215,7 +215,7 @@ emm_fsm_state_t _emm_fsm_status[EMM_FSM_NB_UE_MAX];
***************************************************************************/ ***************************************************************************/
void emm_fsm_initialize(void) void emm_fsm_initialize(void)
{ {
int ueid; //int ueid;
LOG_FUNC_IN; LOG_FUNC_IN;
_emm_fsm_status[0] = EMM_NULL; _emm_fsm_status[0] = EMM_NULL;
......
...@@ -114,6 +114,9 @@ int emm_reg_send(const emm_reg_t *msg) ...@@ -114,6 +114,9 @@ int emm_reg_send(const emm_reg_t *msg)
emm_reg_primitive_t primitive = msg->primitive; emm_reg_primitive_t primitive = msg->primitive;
assert( (primitive > _EMMREG_START) && (primitive < _EMMREG_END)); assert( (primitive > _EMMREG_START) && (primitive < _EMMREG_END));
/* avoid gcc warnings */
(void)primitive;
/* Execute the EMM procedure */ /* Execute the EMM procedure */
rc = emm_fsm_process(msg); rc = emm_fsm_process(msg);
......
...@@ -114,7 +114,7 @@ int esm_ebr_context_create( ...@@ -114,7 +114,7 @@ int esm_ebr_context_create(
int bid = 0; int bid = 0;
esm_data_context_t *esm_ctx = NULL; esm_data_context_t *esm_ctx = NULL;
esm_pdn_t *pdn = NULL; esm_pdn_t *pdn = NULL;
unsigned int ueid = 0; //unsigned int ueid = 0;
LOG_FUNC_IN; LOG_FUNC_IN;
...@@ -212,7 +212,7 @@ int esm_ebr_context_create( ...@@ -212,7 +212,7 @@ int esm_ebr_context_create(
{ {
char *tmp = NULL; char *tmp = NULL;
char ipv4_addr[INET_ADDRSTRLEN]; char ipv4_addr[INET_ADDRSTRLEN];
char ipv6_addr[INET6_ADDRSTRLEN]; //char ipv6_addr[INET6_ADDRSTRLEN];
char *netmask = NULL; char *netmask = NULL;
char broadcast[INET_ADDRSTRLEN]; char broadcast[INET_ADDRSTRLEN];
struct in_addr in_addr; struct in_addr in_addr;
...@@ -221,7 +221,8 @@ int esm_ebr_context_create( ...@@ -221,7 +221,8 @@ int esm_ebr_context_create(
switch (pdn->type) { switch (pdn->type) {
case NET_PDN_TYPE_IPV4V6: case NET_PDN_TYPE_IPV4V6:
ipv6_addr[0] = pdn->ip_addr[4]; //ipv6_addr[0] = pdn->ip_addr[4];
/* TODO? */
// etc // etc
case NET_PDN_TYPE_IPV4: case NET_PDN_TYPE_IPV4:
...@@ -283,11 +284,12 @@ int esm_ebr_context_create( ...@@ -283,11 +284,12 @@ int esm_ebr_context_create(
res = sprintf(command_line, res = sprintf(command_line,
"ifconfig oip1 %s netmask %s broadcast %s up", "ifconfig oip1 %s netmask %s broadcast %s up",
ipv4_addr, netmask, broadcast); ipv4_addr, netmask, broadcast);
(void)res; /* avoid gcc warning "set but not used" */
// AssertFatal((res > 0) && (res < 128), // AssertFatal((res > 0) && (res < 128),
// "error in system command line"); // "error in system command line");
LOG_TRACE(INFO, "ESM-PROC - executing %s ", LOG_TRACE(INFO, "ESM-PROC - executing %s ",
command_line); command_line);
system(command_line); if (system(command_line)) ; /* TODO: what to do? */
break; break;
case NET_PDN_TYPE_IPV6: case NET_PDN_TYPE_IPV6:
...@@ -341,7 +343,7 @@ int esm_ebr_context_release( ...@@ -341,7 +343,7 @@ int esm_ebr_context_release(
esm_pdn_t *pdn = NULL; esm_pdn_t *pdn = NULL;
esm_data_context_t *esm_ctx; esm_data_context_t *esm_ctx;
unsigned int ueid = 0; //unsigned int ueid = 0;
LOG_FUNC_IN; LOG_FUNC_IN;
......
...@@ -4,7 +4,7 @@ ...@@ -4,7 +4,7 @@
asn_enc_rval_t OCTET_STRING_encode_aper(asn_TYPE_descriptor_t *td, asn_per_constraints_t *cts, void *sptr, asn_per_outp_t *po) { asn_enc_rval_t er = { 0, 0, 0 }; (void)td; (void)cts; (void)sptr; (void)po; return er; } asn_enc_rval_t OCTET_STRING_encode_aper(asn_TYPE_descriptor_t *td, asn_per_constraints_t *cts, void *sptr, asn_per_outp_t *po) { asn_enc_rval_t er = { 0, 0, 0 }; (void)td; (void)cts; (void)sptr; (void)po; return er; }
+asn_comp_rval_t * OCTET_STRING_compare(asn_TYPE_descriptor_t *td1, void *sptr1, asn_TYPE_descriptor_t *td2, void *sptr2) { (void)td1; (void)sptr1; (void)td2; (void)sptr2; return 0; } +asn_comp_rval_t * OCTET_STRING_compare(asn_TYPE_descriptor_t *td1, const void *sptr1, asn_TYPE_descriptor_t *td2, const void *sptr2) { (void)td1; (void)sptr1; (void)td2; (void)sptr2; return 0; }
+ +
size_t xer_whitespace_span(const void *chunk_buf, size_t chunk_size) { (void)chunk_buf; (void)chunk_size; return 0; } size_t xer_whitespace_span(const void *chunk_buf, size_t chunk_size) { (void)chunk_buf; (void)chunk_size; return 0; }
--- libasn1compiler/asn1c_C.c 2015-12-08 14:39:33.366543533 +0100 --- libasn1compiler/asn1c_C.c 2015-12-08 14:39:33.366543533 +0100
...@@ -51,9 +51,9 @@ ...@@ -51,9 +51,9 @@
+ if(HIDE_INNER_DEFS) OUT("_%d", expr->_type_unique_index); + if(HIDE_INNER_DEFS) OUT("_%d", expr->_type_unique_index);
+ OUT("_compare(asn_TYPE_descriptor_t *td1,\n"); + OUT("_compare(asn_TYPE_descriptor_t *td1,\n");
+ INDENTED( + INDENTED(
+ OUT("\tvoid *structure1,\n"); + OUT("\tconst void *structure1,\n");
+ OUT("\tasn_TYPE_descriptor_t *td2,\n"); + OUT("\tasn_TYPE_descriptor_t *td2,\n");
+ OUT("\tvoid *structure2) {\n"); + OUT("\tconst void *structure2) {\n");
+ OUT("asn_comp_rval_t * res = NULL;\n"); + OUT("asn_comp_rval_t * res = NULL;\n");
+ OUT("%s_%d_inherit_TYPE_descriptor(td1);\n", + OUT("%s_%d_inherit_TYPE_descriptor(td1);\n",
+ p, expr->_type_unique_index); + p, expr->_type_unique_index);
...@@ -142,8 +142,8 @@ ...@@ -142,8 +142,8 @@
+typedef struct asn_comp_rval_s { +typedef struct asn_comp_rval_s {
+ enum COMPARE_ERR_CODE_e err_code; + enum COMPARE_ERR_CODE_e err_code;
+ char *name; // e_S1ap_ProtocolIE_ID not available for all ASN1 use (RRC vs S1AP, X2AP) + char *name; // e_S1ap_ProtocolIE_ID not available for all ASN1 use (RRC vs S1AP, X2AP)
+ void *structure1; + const void *structure1;
+ void *structure2; + const void *structure2;
+ struct asn_comp_rval_s *next; + struct asn_comp_rval_s *next;
+} asn_comp_rval_t; +} asn_comp_rval_t;
+ +
...@@ -234,7 +234,7 @@ ...@@ -234,7 +234,7 @@
+ +
+asn_comp_rval_t * +asn_comp_rval_t *
+BOOLEAN_compare(asn_TYPE_descriptor_t *td1, +BOOLEAN_compare(asn_TYPE_descriptor_t *td1,
+ void *sptr1, asn_TYPE_descriptor_t *td2, void *sptr2) { + const void *sptr1, asn_TYPE_descriptor_t *td2, const void *sptr2) {
+ const BOOLEAN_t *st1 = (const BOOLEAN_t *)sptr1; + const BOOLEAN_t *st1 = (const BOOLEAN_t *)sptr1;
+ const BOOLEAN_t *st2 = (const BOOLEAN_t *)sptr2; + const BOOLEAN_t *st2 = (const BOOLEAN_t *)sptr2;
+ asn_comp_rval_t *res = NULL; + asn_comp_rval_t *res = NULL;
...@@ -279,9 +279,9 @@ ...@@ -279,9 +279,9 @@
+ +
+typedef asn_comp_rval_t * (type_compare_f)( +typedef asn_comp_rval_t * (type_compare_f)(
+ struct asn_TYPE_descriptor_s *type_descriptor1, + struct asn_TYPE_descriptor_s *type_descriptor1,
+ void *struct_ptr1, + const void *struct_ptr1,
+ struct asn_TYPE_descriptor_s *type_descriptor2, + struct asn_TYPE_descriptor_s *type_descriptor2,
+ void *struct_ptr2 + const void *struct_ptr2
+); +);
+ +
+ +
...@@ -299,7 +299,7 @@ ...@@ -299,7 +299,7 @@
} }
+ +
+asn_comp_rval_t * +asn_comp_rval_t *
+CHOICE_compare(asn_TYPE_descriptor_t *td1, void *sptr1, asn_TYPE_descriptor_t *td2, void *sptr2) +CHOICE_compare(asn_TYPE_descriptor_t *td1, const void *sptr1, asn_TYPE_descriptor_t *td2, const void *sptr2)
+{ +{
+ asn_CHOICE_specifics_t *specs1 = (asn_CHOICE_specifics_t *)td1->specifics; + asn_CHOICE_specifics_t *specs1 = (asn_CHOICE_specifics_t *)td1->specifics;
+ asn_CHOICE_specifics_t *specs2 = (asn_CHOICE_specifics_t *)td2->specifics; + asn_CHOICE_specifics_t *specs2 = (asn_CHOICE_specifics_t *)td2->specifics;
...@@ -392,14 +392,13 @@ ...@@ -392,14 +392,13 @@
} }
--- skeletons/constr_SEQUENCE.c 2015-12-08 14:39:33.346543533 +0100 --- skeletons/constr_SEQUENCE.c 2015-12-08 14:39:33.346543533 +0100
+++ skeletons/constr_SEQUENCE.c 2015-12-08 10:39:52.442558000 +0100 +++ skeletons/constr_SEQUENCE.c 2015-12-08 10:39:52.442558000 +0100
@@ -1761,3 +1761,66 @@ @@ -1761,3 +1761,65 @@
_ASN_ENCODED_OK(er); _ASN_ENCODED_OK(er);
} }
+ +
+asn_comp_rval_t * SEQUENCE_compare(asn_TYPE_descriptor_t *td1, void *sptr1, asn_TYPE_descriptor_t *td2, void *sptr2) { +asn_comp_rval_t * SEQUENCE_compare(asn_TYPE_descriptor_t *td1, const void *sptr1, asn_TYPE_descriptor_t *td2, const void *sptr2) {
+ int edx; + int edx;
+ int ret;
+ asn_comp_rval_t *res = NULL; + asn_comp_rval_t *res = NULL;
+ asn_comp_rval_t *res2 = NULL; + asn_comp_rval_t *res2 = NULL;
+ +
...@@ -498,7 +497,7 @@ ...@@ -498,7 +497,7 @@
} }
+ +
+asn_comp_rval_t * +asn_comp_rval_t *
+SET_compare(asn_TYPE_descriptor_t *td1, void *sptr1, asn_TYPE_descriptor_t *td2, void *sptr2) +SET_compare(asn_TYPE_descriptor_t *td1, const void *sptr1, asn_TYPE_descriptor_t *td2, const void *sptr2)
+{ +{
+ int edx; + int edx;
+ asn_comp_rval_t *res = NULL; + asn_comp_rval_t *res = NULL;
...@@ -563,19 +562,18 @@ ...@@ -563,19 +562,18 @@
* Some handy helpers. * * Some handy helpers. *
--- skeletons/constr_SET_OF.c 2015-12-08 14:39:33.338543533 +0100 --- skeletons/constr_SET_OF.c 2015-12-08 14:39:33.338543533 +0100
+++ skeletons/constr_SET_OF.c 2015-12-08 10:45:54.466557000 +0100 +++ skeletons/constr_SET_OF.c 2015-12-08 10:45:54.466557000 +0100
@@ -1039,3 +1039,55 @@ @@ -1039,3 +1039,54 @@
rv.consumed = 0; rv.consumed = 0;
return rv; return rv;
} }
+ +
+asn_comp_rval_t * +asn_comp_rval_t *
+SET_OF_compare(asn_TYPE_descriptor_t *td1, void *sptr1, asn_TYPE_descriptor_t *td2, void *sptr2) +SET_OF_compare(asn_TYPE_descriptor_t *td1, const void *sptr1, asn_TYPE_descriptor_t *td2, const void *sptr2)
+{ +{
+ asn_TYPE_member_t *elm1 = td1->elements; + asn_TYPE_member_t *elm1 = td1->elements;
+ asn_TYPE_member_t *elm2 = td2->elements; + asn_TYPE_member_t *elm2 = td2->elements;
+ const asn_anonymous_set_ *list1 = _A_CSET_FROM_VOID(sptr1); + const asn_anonymous_set_ *list1 = _A_CSET_FROM_VOID(sptr1);
+ const asn_anonymous_set_ *list2 = _A_CSET_FROM_VOID(sptr2); + const asn_anonymous_set_ *list2 = _A_CSET_FROM_VOID(sptr2);
+ int ret;
+ int i; + int i;
+ asn_comp_rval_t *res = NULL; + asn_comp_rval_t *res = NULL;
+ asn_comp_rval_t *res2 = NULL; + asn_comp_rval_t *res2 = NULL;
...@@ -667,10 +665,10 @@ ...@@ -667,10 +665,10 @@
} }
+ +
+asn_comp_rval_t * +asn_comp_rval_t *
+ENUMERATED_compare(asn_TYPE_descriptor_t *td1, void *sptr1, +ENUMERATED_compare(asn_TYPE_descriptor_t *td1, const void *sptr1,
+ asn_TYPE_descriptor_t *td2, void *sptr2) { + asn_TYPE_descriptor_t *td2, const void *sptr2) {
+ ENUMERATED_t *st1 = (ENUMERATED_t *)sptr1; + const ENUMERATED_t *st1 = (const ENUMERATED_t *)sptr1;
+ ENUMERATED_t *st2 = (ENUMERATED_t *)sptr2; + const ENUMERATED_t *st2 = (const ENUMERATED_t *)sptr2;
+ asn_comp_rval_t *res = NULL; + asn_comp_rval_t *res = NULL;
+ +
+ COMPARE_CHECK_ARGS(td1, td2, sptr1, sptr2, res) + COMPARE_CHECK_ARGS(td1, td2, sptr1, sptr2, res)
...@@ -774,10 +772,10 @@ ...@@ -774,10 +772,10 @@
+asn_comp_rval_t * +asn_comp_rval_t *
+INTEGER_compare(asn_TYPE_descriptor_t *td1, void *sptr1, +INTEGER_compare(asn_TYPE_descriptor_t *td1, const void *sptr1,
+ asn_TYPE_descriptor_t *td2, void *sptr2) { + asn_TYPE_descriptor_t *td2, const void *sptr2) {
+ INTEGER_t *st1 = (INTEGER_t *)sptr1; + const INTEGER_t *st1 = (const INTEGER_t *)sptr1;
+ INTEGER_t *st2 = (INTEGER_t *)sptr2; + const INTEGER_t *st2 = (const INTEGER_t *)sptr2;
+ asn_comp_rval_t *res = NULL; + asn_comp_rval_t *res = NULL;
+ +
+ COMPARE_CHECK_ARGS(td1, td2, sptr1, sptr2, res) + COMPARE_CHECK_ARGS(td1, td2, sptr1, sptr2, res)
...@@ -857,8 +855,8 @@ ...@@ -857,8 +855,8 @@
} }
+ +
+asn_comp_rval_t * +asn_comp_rval_t *
+NativeEnumerated_compare(asn_TYPE_descriptor_t *td1, void *sptr1, +NativeEnumerated_compare(asn_TYPE_descriptor_t *td1, const void *sptr1,
+ asn_TYPE_descriptor_t *td2, void *sptr2) { + asn_TYPE_descriptor_t *td2, const void *sptr2) {
+ const asn_INTEGER_enum_map_t *a = sptr1; + const asn_INTEGER_enum_map_t *a = sptr1;
+ const asn_INTEGER_enum_map_t *b = sptr2; + const asn_INTEGER_enum_map_t *b = sptr2;
+ asn_comp_rval_t *res = NULL; + asn_comp_rval_t *res = NULL;
...@@ -902,8 +900,8 @@ ...@@ -902,8 +900,8 @@
+ +
+asn_comp_rval_t * +asn_comp_rval_t *
+NativeInteger_compare(asn_TYPE_descriptor_t *td1, void *sptr1, +NativeInteger_compare(asn_TYPE_descriptor_t *td1, const void *sptr1,
+ asn_TYPE_descriptor_t *td2, void *sptr2) { + asn_TYPE_descriptor_t *td2, const void *sptr2) {
+ const long *native1 = (const long *)sptr1; + const long *native1 = (const long *)sptr1;
+ const long *native2 = (const long *)sptr2; + const long *native2 = (const long *)sptr2;
+ asn_comp_rval_t *res = NULL; + asn_comp_rval_t *res = NULL;
...@@ -945,10 +943,10 @@ ...@@ -945,10 +943,10 @@
} }
+asn_comp_rval_t * +asn_comp_rval_t *
+NativeReal_compare(asn_TYPE_descriptor_t *td1, void *sptr1, +NativeReal_compare(asn_TYPE_descriptor_t *td1, const void *sptr1,
+ asn_TYPE_descriptor_t *td2, void *sptr2) { + asn_TYPE_descriptor_t *td2, const void *sptr2) {
+ REAL_t *st1 = (REAL_t *)sptr1; + const REAL_t *st1 = (const REAL_t *)sptr1;
+ REAL_t *st2 = (REAL_t *)sptr2; + const REAL_t *st2 = (const REAL_t *)sptr2;
+ asn_comp_rval_t *res = NULL; + asn_comp_rval_t *res = NULL;
+ +
+ COMPARE_CHECK_ARGS(td1, td2, sptr1, sptr2, res) + COMPARE_CHECK_ARGS(td1, td2, sptr1, sptr2, res)
...@@ -999,8 +997,8 @@ ...@@ -999,8 +997,8 @@
} }
+ +
+asn_comp_rval_t * +asn_comp_rval_t *
+NULL_compare(asn_TYPE_descriptor_t *td1, void *sptr1, +NULL_compare(asn_TYPE_descriptor_t *td1, const void *sptr1,
+ asn_TYPE_descriptor_t *td2, void *sptr2) { + asn_TYPE_descriptor_t *td2, const void *sptr2) {
+ +
+ return NULL; + return NULL;
+} +}
...@@ -1068,9 +1066,9 @@ ...@@ -1068,9 +1066,9 @@
+asn_comp_rval_t * +asn_comp_rval_t *
+OCTET_STRING_compare(asn_TYPE_descriptor_t *td1, +OCTET_STRING_compare(asn_TYPE_descriptor_t *td1,
+ void *sptr1, asn_TYPE_descriptor_t *td2, void *sptr2) { + const void *sptr1, asn_TYPE_descriptor_t *td2, const void *sptr2) {
+ OCTET_STRING_t *st1 = (OCTET_STRING_t *)sptr1; + const OCTET_STRING_t *st1 = (const OCTET_STRING_t *)sptr1;
+ OCTET_STRING_t *st2 = (OCTET_STRING_t *)sptr2; + const OCTET_STRING_t *st2 = (const OCTET_STRING_t *)sptr2;
+ asn_comp_rval_t *res = NULL; + asn_comp_rval_t *res = NULL;
+ +
+ COMPARE_CHECK_ARGS(td1, td2, sptr1, sptr2, res) + COMPARE_CHECK_ARGS(td1, td2, sptr1, sptr2, res)
...@@ -1134,10 +1132,10 @@ ...@@ -1134,10 +1132,10 @@
+ +
+ +
+asn_comp_rval_t * +asn_comp_rval_t *
+REAL_compare(asn_TYPE_descriptor_t *td1, void *sptr1, +REAL_compare(asn_TYPE_descriptor_t *td1, const void *sptr1,
+ asn_TYPE_descriptor_t *td2, void *sptr2) { + asn_TYPE_descriptor_t *td2, const void *sptr2) {
+ REAL_t *st1 = (REAL_t *)sptr1; + const REAL_t *st1 = (const REAL_t *)sptr1;
+ REAL_t *st2 = (REAL_t *)sptr2; + const REAL_t *st2 = (const REAL_t *)sptr2;
+ asn_comp_rval_t *res = NULL; + asn_comp_rval_t *res = NULL;
+ +
+ COMPARE_CHECK_ARGS(td1, td2, sptr1, sptr2, res) + COMPARE_CHECK_ARGS(td1, td2, sptr1, sptr2, res)
......
...@@ -859,11 +859,12 @@ int s1ap_eNB_handle_ue_context_release_command(uint32_t assoc_id, ...@@ -859,11 +859,12 @@ int s1ap_eNB_handle_ue_context_release_command(uint32_t assoc_id,
break; break;
#warning "TODO mapping mme_ue_s1ap_id enb_ue_s1ap_id?" //#warning "TODO mapping mme_ue_s1ap_id enb_ue_s1ap_id?"
case S1ap_UE_S1AP_IDs_PR_mME_UE_S1AP_ID: case S1ap_UE_S1AP_IDs_PR_mME_UE_S1AP_ID:
mme_ue_s1ap_id = ueContextReleaseCommand_p->uE_S1AP_IDs.choice.mME_UE_S1AP_ID; mme_ue_s1ap_id = ueContextReleaseCommand_p->uE_S1AP_IDs.choice.mME_UE_S1AP_ID;
S1AP_ERROR("TO DO mapping mme_ue_s1ap_id enb_ue_s1ap_id"); S1AP_ERROR("TO DO mapping mme_ue_s1ap_id enb_ue_s1ap_id");
(void)mme_ue_s1ap_id; /* TODO: remove - it's to remove gcc warning about unused var */
case S1ap_UE_S1AP_IDs_PR_NOTHING: case S1ap_UE_S1AP_IDs_PR_NOTHING:
default: default:
......
...@@ -191,7 +191,7 @@ int s1ap_eNB_handle_nas_first_req( ...@@ -191,7 +191,7 @@ int s1ap_eNB_handle_nas_first_req(
* The cell identity is defined on 28 bits but as we use macro enb id, * The cell identity is defined on 28 bits but as we use macro enb id,
* we have to pad. * we have to pad.
*/ */
#warning "TODO get cell id from RRC" //#warning "TODO get cell id from RRC"
MACRO_ENB_ID_TO_CELL_IDENTITY(instance_p->eNB_id, MACRO_ENB_ID_TO_CELL_IDENTITY(instance_p->eNB_id,
0, // Cell ID 0, // Cell ID
&initial_ue_message_p->eutran_cgi.cell_ID); &initial_ue_message_p->eutran_cgi.cell_ID);
...@@ -400,7 +400,7 @@ int s1ap_eNB_nas_uplink(instance_t instance, s1ap_uplink_nas_t *s1ap_uplink_nas_ ...@@ -400,7 +400,7 @@ int s1ap_eNB_nas_uplink(instance_t instance, s1ap_uplink_nas_t *s1ap_uplink_nas_
s1ap_eNB_instance_p->mnc_digit_length, s1ap_eNB_instance_p->mnc_digit_length,
&uplink_NAS_transport_p->eutran_cgi.pLMNidentity); &uplink_NAS_transport_p->eutran_cgi.pLMNidentity);
#warning "TODO get cell id from RRC" //#warning "TODO get cell id from RRC"
MACRO_ENB_ID_TO_CELL_IDENTITY(s1ap_eNB_instance_p->eNB_id, MACRO_ENB_ID_TO_CELL_IDENTITY(s1ap_eNB_instance_p->eNB_id,
0, 0,
&uplink_NAS_transport_p->eutran_cgi.cell_ID); &uplink_NAS_transport_p->eutran_cgi.cell_ID);
......
...@@ -148,7 +148,7 @@ sctp_handle_new_association_req( ...@@ -148,7 +148,7 @@ sctp_handle_new_association_req(
DevAssert(sctp_new_association_req_p != NULL); DevAssert(sctp_new_association_req_p != NULL);
/* Create new socket with IPv6 affinity */ /* Create new socket with IPv6 affinity */
#warning "SCTP may Force IPv4 only, here" //#warning "SCTP may Force IPv4 only, here"
#ifdef NO_VIRTUAL_MACHINE #ifdef NO_VIRTUAL_MACHINE
// in init chunk appears a list of host addresses, IPv4 and IPv4 in an arbitrary (unsorted) order // in init chunk appears a list of host addresses, IPv4 and IPv4 in an arbitrary (unsorted) order
......
...@@ -49,7 +49,7 @@ int nas_stream_encrypt_eea1(nas_stream_cipher_t *stream_cipher, uint8_t *out) ...@@ -49,7 +49,7 @@ int nas_stream_encrypt_eea1(nas_stream_cipher_t *stream_cipher, uint8_t *out)
int n ; int n ;
int i = 0; int i = 0;
uint32_t zero_bit = 0; uint32_t zero_bit = 0;
uint32_t byte_length; //uint32_t byte_length;
uint32_t *KS; uint32_t *KS;
uint32_t K[4],IV[4]; uint32_t K[4],IV[4];
...@@ -60,7 +60,7 @@ int nas_stream_encrypt_eea1(nas_stream_cipher_t *stream_cipher, uint8_t *out) ...@@ -60,7 +60,7 @@ int nas_stream_encrypt_eea1(nas_stream_cipher_t *stream_cipher, uint8_t *out)
n = ( stream_cipher->blength + 31 ) / 32; n = ( stream_cipher->blength + 31 ) / 32;
zero_bit = stream_cipher->blength & 0x7; zero_bit = stream_cipher->blength & 0x7;
byte_length = stream_cipher->blength >> 3; //byte_length = stream_cipher->blength >> 3;
memset(&snow_3g_context, 0, sizeof(snow_3g_context)); memset(&snow_3g_context, 0, sizeof(snow_3g_context));
/*Initialisation*/ /*Initialisation*/
......
...@@ -112,6 +112,7 @@ int nas_stream_encrypt_eia2(nas_stream_cipher_t *stream_cipher, uint8_t out[4]) ...@@ -112,6 +112,7 @@ int nas_stream_encrypt_eia2(nas_stream_cipher_t *stream_cipher, uint8_t out[4])
cmac_ctx = CMAC_CTX_new(); cmac_ctx = CMAC_CTX_new();
ret = CMAC_Init(cmac_ctx, stream_cipher->key, stream_cipher->key_length, cipher, NULL); ret = CMAC_Init(cmac_ctx, stream_cipher->key, stream_cipher->key_length, cipher, NULL);
ret = CMAC_Update(cmac_ctx, m, m_length + 8); ret = CMAC_Update(cmac_ctx, m, m_length + 8);
(void)ret; /* avoid gcc warning "set but not used" */
CMAC_Final(cmac_ctx, data, &size); CMAC_Final(cmac_ctx, data, &size);
CMAC_CTX_free(cmac_ctx); CMAC_CTX_free(cmac_ctx);
......
...@@ -300,8 +300,8 @@ void *udp_eNB_task(void *args_p) ...@@ -300,8 +300,8 @@ void *udp_eNB_task(void *args_p)
int nb_events; int nb_events;
struct epoll_event *events; struct epoll_event *events;
MessageDef *received_message_p = NULL; MessageDef *received_message_p = NULL;
const char *msg_name = NULL; //const char *msg_name = NULL;
instance_t instance = 0; //instance_t instance = 0;
udp_enb_init(NULL); udp_enb_init(NULL);
itti_mark_task_ready(TASK_UDP); itti_mark_task_ready(TASK_UDP);
...@@ -316,8 +316,8 @@ void *udp_eNB_task(void *args_p) ...@@ -316,8 +316,8 @@ void *udp_eNB_task(void *args_p)
if (received_message_p != NULL) { if (received_message_p != NULL) {
msg_name = ITTI_MSG_NAME (received_message_p); //msg_name = ITTI_MSG_NAME (received_message_p);
instance = ITTI_MSG_INSTANCE (received_message_p); //instance = ITTI_MSG_INSTANCE (received_message_p);
switch (ITTI_MSG_ID(received_message_p)) { switch (ITTI_MSG_ID(received_message_p)) {
case UDP_INIT: { case UDP_INIT: {
......
...@@ -147,7 +147,8 @@ int openair0_device_load(openair0_device *device, openair0_config_t *openair0_cf ...@@ -147,7 +147,8 @@ int openair0_device_load(openair0_device *device, openair0_config_t *openair0_cf
int rc; int rc;
//ToDo: EXMIMO harmonization is not complete. That is the reason for this ifdef //ToDo: EXMIMO harmonization is not complete. That is the reason for this ifdef
#ifdef EXMIMO #ifdef EXMIMO
device_init(device, openair0_cfg); int device_init(openair0_device *device, openair0_config_t *openair0_cfg);
rc = device_init(device, openair0_cfg);
#else #else
rc=load_lib(device, openair0_cfg, NULL,BBU_LOCAL_RADIO_HEAD ); rc=load_lib(device, openair0_cfg, NULL,BBU_LOCAL_RADIO_HEAD );
if ( rc >= 0) { if ( rc >= 0) {
......
...@@ -190,15 +190,13 @@ static int __init openair_init_module( void ) ...@@ -190,15 +190,13 @@ static int __init openair_init_module( void )
mmio_length[card] = pci_resource_len (pdev[card], 0); mmio_length[card] = pci_resource_len (pdev[card], 0);
mmio_flags[card] = pci_resource_flags(pdev[card], 0); mmio_flags[card] = pci_resource_flags(pdev[card], 0);
if (check_mem_region(mmio_start[card],256) < 0) { if (request_mem_region(mmio_start[card],256,"openair_rf") == NULL) {
printk("[openair][INIT_MODULE][FATAL] : Cannot get memory region 0, aborting\n"); printk("[openair][INIT_MODULE][FATAL] : Cannot get memory region 0, aborting\n");
mmio_start[card] = 0; mmio_start[card] = 0;
openair_cleanup(); openair_cleanup();
return -EBUSY; return -EBUSY;
} else } else
printk("[openair][INIT_MODULE][INFO] : Reserving memory region 0 : mmio_start = 0x%x\n",(unsigned int)mmio_start[card]); printk("[openair][INIT_MODULE][INFO] : Reserved memory region 0 : mmio_start = 0x%x\n",(unsigned int)mmio_start[card]);
request_mem_region(mmio_start[card], 256, "openair_rf");
bar[card] = pci_iomap( pdev[card], 0, mmio_length[card] ); // get virtual kernel address for BAR0 bar[card] = pci_iomap( pdev[card], 0, mmio_length[card] ); // get virtual kernel address for BAR0
......
...@@ -30,8 +30,10 @@ ...@@ -30,8 +30,10 @@
#define TARGET_RX_POWER 50 // Target digital power for the AGC #define TARGET_RX_POWER 50 // Target digital power for the AGC
#define TARGET_RX_POWER_MAX 53 // Maximum digital power for AGC #define TARGET_RX_POWER_MAX 53 // Maximum digital power for AGC
#define TARGET_RX_POWER_MIN 48 // Minimum digital power for AGC