Commit da744511 authored by Lionel Gauthier's avatar Lionel Gauthier

eNB and MBMS flags are now boolean

git-svn-id: http://svn.eurecom.fr/openair4G/trunk@5097 818b1a75-f10b-46b9-bf7c-635c3b92a50f
parent c60dc45b
...@@ -41,22 +41,20 @@ typedef int8_t smodule_id_t; ...@@ -41,22 +41,20 @@ typedef int8_t smodule_id_t;
typedef uint16_t rb_id_t; typedef uint16_t rb_id_t;
typedef uint16_t srb_id_t; typedef uint16_t srb_id_t;
typedef boolean_t MBMS_flag_t;
#define MBMS_FLAG_NO FALSE
#define MBMS_FLAG_YES TRUE
typedef boolean_t eNB_flag_t;
#define ENB_FLAG_NO FALSE
#define ENB_FLAG_YES TRUE
typedef enum link_direction_e { typedef enum link_direction_e {
UNKNOWN_DIR = 0, UNKNOWN_DIR = 0,
DIR_UPLINK = 1, DIR_UPLINK = 1,
DIR_DOWNLINK = 2 DIR_DOWNLINK = 2
} link_direction_t; } link_direction_t;
typedef enum MBMS_flag_e {
MBMS_FLAG_NO = 0,
MBMS_FLAG_YES = 1,
} MBMS_flag_t;
typedef enum eNB_flag_e {
ENB_FLAG_NO = 0,
ENB_FLAG_YES = 1,
} eNB_flag_t;
typedef enum rb_type_e { typedef enum rb_type_e {
UNKNOWN_RADIO_BEARER = 0, UNKNOWN_RADIO_BEARER = 0,
SIGNALLING_RADIO_BEARER = 1, SIGNALLING_RADIO_BEARER = 1,
...@@ -122,6 +120,13 @@ typedef enum ip_traffic_type_e { ...@@ -122,6 +120,13 @@ typedef enum ip_traffic_type_e {
typedef uint32_t mbms_session_id_t; typedef uint32_t mbms_session_id_t;
typedef uint16_t mbms_service_id_t; typedef uint16_t mbms_service_id_t;
typedef uint16_t rnti_t; typedef uint16_t rnti_t;
typedef unsigned int config_action_t; typedef enum config_action_e {
CONFIG_ACTION_NULL = 0,
CONFIG_ACTION_ADD = 1,
CONFIG_ACTION_REMOVE = 2,
CONFIG_ACTION_MODIFY = 3,
CONFIG_ACTION_SET_SECURITY_MODE = 4,
CONFIG_ACTION_MBMS_ADD = 10,
CONFIG_ACTION_MBMS_MODIFY = 11
} config_action_t;
#endif #endif
...@@ -21,6 +21,7 @@ ...@@ -21,6 +21,7 @@
# define TRANSACTION_NULL 0 # define TRANSACTION_NULL 0
// RRM action // RRM action
/*
# define ACTION_NULL 0 # define ACTION_NULL 0
# define ACTION_ADD 1 # define ACTION_ADD 1
# define ACTION_REMOVE 2 # define ACTION_REMOVE 2
...@@ -28,6 +29,7 @@ ...@@ -28,6 +29,7 @@
# define ACTION_SET_SECURITY_MODE 4 # define ACTION_SET_SECURITY_MODE 4
# define ACTION_MBMS_ADD 10 # define ACTION_MBMS_ADD 10
# define ACTION_MBMS_MODIFY 11 # define ACTION_MBMS_MODIFY 11
*/
# define MOBILE 7 # define MOBILE 7
......
...@@ -94,14 +94,14 @@ boolean_t pdcp_data_req(module_id_t enb_mod_idP, module_id_t ue_mod_idP, frame_t ...@@ -94,14 +94,14 @@ boolean_t pdcp_data_req(module_id_t enb_mod_idP, module_id_t ue_mod_idP, frame_t
AssertError (ue_mod_idP < NUMBER_OF_UE_MAX, return FALSE, "UE id is too high (%u/%d) %u %u!\n", ue_mod_idP, NUMBER_OF_UE_MAX, enb_mod_idP, rb_idP); AssertError (ue_mod_idP < NUMBER_OF_UE_MAX, return FALSE, "UE id is too high (%u/%d) %u %u!\n", ue_mod_idP, NUMBER_OF_UE_MAX, enb_mod_idP, rb_idP);
AssertError (rb_idP < NB_RB_MAX, return FALSE, "RB id is too high (%u/%d) %u %u!\n", rb_idP, NB_RB_MAX, ue_mod_idP, enb_mod_idP); AssertError (rb_idP < NB_RB_MAX, return FALSE, "RB id is too high (%u/%d) %u %u!\n", rb_idP, NB_RB_MAX, ue_mod_idP, enb_mod_idP);
if (enb_flagP == 0) { if (enb_flagP == ENB_FLAG_NO) {
pdcp_p = &pdcp_array_ue[ue_mod_idP][rb_idP]; pdcp_p = &pdcp_array_ue[ue_mod_idP][rb_idP];
} else { } else {
pdcp_p = &pdcp_array_eNB[enb_mod_idP][ue_mod_idP][rb_idP]; pdcp_p = &pdcp_array_eNB[enb_mod_idP][ue_mod_idP][rb_idP];
} }
if ((pdcp_p->instanciated_instance == 0) && (modeP != PDCP_TRANSMISSION_MODE_TRANSPARENT)) { if ((pdcp_p->instanciated_instance == FALSE) && (modeP != PDCP_TRANSMISSION_MODE_TRANSPARENT)) {
if (enb_flagP == 0) { if (enb_flagP == ENB_FLAG_NO) {
LOG_W(PDCP, "[UE %d] Instance is not configured for eNB %d, rb_id %d Ignoring SDU...\n", LOG_W(PDCP, "[UE %d] Instance is not configured for eNB %d, rb_id %d Ignoring SDU...\n",
ue_mod_idP, enb_mod_idP, rb_idP); ue_mod_idP, enb_mod_idP, rb_idP);
} else { } else {
...@@ -125,7 +125,7 @@ boolean_t pdcp_data_req(module_id_t enb_mod_idP, module_id_t ue_mod_idP, frame_t ...@@ -125,7 +125,7 @@ boolean_t pdcp_data_req(module_id_t enb_mod_idP, module_id_t ue_mod_idP, frame_t
mac_xface->macphy_exit("PDCP sdu buffer size > MAX_IP_PACKET_SIZE"); mac_xface->macphy_exit("PDCP sdu buffer size > MAX_IP_PACKET_SIZE");
} }
if (enb_flagP == 0) if (enb_flagP == ENB_FLAG_NO)
start_meas(&eNB_pdcp_stats[enb_mod_idP].data_req); start_meas(&eNB_pdcp_stats[enb_mod_idP].data_req);
else else
start_meas(&UE_pdcp_stats[ue_mod_idP].data_req); start_meas(&UE_pdcp_stats[ue_mod_idP].data_req);
...@@ -189,7 +189,7 @@ boolean_t pdcp_data_req(module_id_t enb_mod_idP, module_id_t ue_mod_idP, frame_t ...@@ -189,7 +189,7 @@ boolean_t pdcp_data_req(module_id_t enb_mod_idP, module_id_t ue_mod_idP, frame_t
memset(&pdu_header.mac_i[0],0,PDCP_CONTROL_PLANE_DATA_PDU_MAC_I_SIZE); memset(&pdu_header.mac_i[0],0,PDCP_CONTROL_PLANE_DATA_PDU_MAC_I_SIZE);
if (pdcp_serialize_control_plane_data_pdu_with_SRB_sn_buffer((unsigned char*)pdcp_pdu_p->data, &pdu_header) == FALSE) { if (pdcp_serialize_control_plane_data_pdu_with_SRB_sn_buffer((unsigned char*)pdcp_pdu_p->data, &pdu_header) == FALSE) {
LOG_E(PDCP, "Cannot fill PDU buffer with relevant header fields!\n"); LOG_E(PDCP, "Cannot fill PDU buffer with relevant header fields!\n");
if (enb_flagP == 0) if (enb_flagP == ENB_FLAG_NO)
stop_meas(&eNB_pdcp_stats[enb_mod_idP].data_req); stop_meas(&eNB_pdcp_stats[enb_mod_idP].data_req);
else else
stop_meas(&UE_pdcp_stats[ue_mod_idP].data_req); stop_meas(&UE_pdcp_stats[ue_mod_idP].data_req);
...@@ -202,7 +202,7 @@ boolean_t pdcp_data_req(module_id_t enb_mod_idP, module_id_t ue_mod_idP, frame_t ...@@ -202,7 +202,7 @@ boolean_t pdcp_data_req(module_id_t enb_mod_idP, module_id_t ue_mod_idP, frame_t
current_sn = pdu_header.sn ; current_sn = pdu_header.sn ;
if (pdcp_serialize_user_plane_data_pdu_with_long_sn_buffer((unsigned char*)pdcp_pdu_p->data, &pdu_header) == FALSE) { if (pdcp_serialize_user_plane_data_pdu_with_long_sn_buffer((unsigned char*)pdcp_pdu_p->data, &pdu_header) == FALSE) {
LOG_E(PDCP, "Cannot fill PDU buffer with relevant header fields!\n"); LOG_E(PDCP, "Cannot fill PDU buffer with relevant header fields!\n");
if (enb_flagP == 0) if (enb_flagP == ENB_FLAG_NO)
stop_meas(&eNB_pdcp_stats[enb_mod_idP].data_req); stop_meas(&eNB_pdcp_stats[enb_mod_idP].data_req);
else else
stop_meas(&UE_pdcp_stats[ue_mod_idP].data_req); stop_meas(&UE_pdcp_stats[ue_mod_idP].data_req);
...@@ -217,7 +217,7 @@ boolean_t pdcp_data_req(module_id_t enb_mod_idP, module_id_t ue_mod_idP, frame_t ...@@ -217,7 +217,7 @@ boolean_t pdcp_data_req(module_id_t enb_mod_idP, module_id_t ue_mod_idP, frame_t
LOG_E(PDCP, "There must be a problem with PDCP initialization, ignoring this PDU...\n"); LOG_E(PDCP, "There must be a problem with PDCP initialization, ignoring this PDU...\n");
free_mem_block(pdcp_pdu_p); free_mem_block(pdcp_pdu_p);
if (enb_flagP == 0) if (enb_flagP == ENB_FLAG_NO)
stop_meas(&eNB_pdcp_stats[enb_mod_idP].data_req); stop_meas(&eNB_pdcp_stats[enb_mod_idP].data_req);
else else
stop_meas(&UE_pdcp_stats[ue_mod_idP].data_req); stop_meas(&UE_pdcp_stats[ue_mod_idP].data_req);
...@@ -252,7 +252,7 @@ boolean_t pdcp_data_req(module_id_t enb_mod_idP, module_id_t ue_mod_idP, frame_t ...@@ -252,7 +252,7 @@ boolean_t pdcp_data_req(module_id_t enb_mod_idP, module_id_t ue_mod_idP, frame_t
//util_flush_hex_octets(PDCP, (unsigned char*)pdcp_pdu->data, pdcp_pdu_size); //util_flush_hex_octets(PDCP, (unsigned char*)pdcp_pdu->data, pdcp_pdu_size);
} else { } else {
LOG_E(PDCP, "Cannot create a mem_block for a PDU!\n"); LOG_E(PDCP, "Cannot create a mem_block for a PDU!\n");
if (enb_flagP == 0) if (enb_flagP == ENB_FLAG_NO)
stop_meas(&eNB_pdcp_stats[enb_mod_idP].data_req); stop_meas(&eNB_pdcp_stats[enb_mod_idP].data_req);
else else
stop_meas(&UE_pdcp_stats[ue_mod_idP].data_req); stop_meas(&UE_pdcp_stats[ue_mod_idP].data_req);
...@@ -297,7 +297,7 @@ boolean_t pdcp_data_req(module_id_t enb_mod_idP, module_id_t ue_mod_idP, frame_t ...@@ -297,7 +297,7 @@ boolean_t pdcp_data_req(module_id_t enb_mod_idP, module_id_t ue_mod_idP, frame_t
ret= FALSE; ret= FALSE;
break; break;
} }
if (enb_flagP == 0) if (enb_flagP == ENB_FLAG_NO)
stop_meas(&eNB_pdcp_stats[enb_mod_idP].data_req); stop_meas(&eNB_pdcp_stats[enb_mod_idP].data_req);
else else
stop_meas(&UE_pdcp_stats[ue_mod_idP].data_req); stop_meas(&UE_pdcp_stats[ue_mod_idP].data_req);
...@@ -364,7 +364,7 @@ boolean_t pdcp_data_ind(module_id_t enb_mod_idP, module_id_t ue_mod_idP, frame_t ...@@ -364,7 +364,7 @@ boolean_t pdcp_data_ind(module_id_t enb_mod_idP, module_id_t ue_mod_idP, frame_t
#endif #endif
DevCheck4(rb_idP < NB_RB_MAX, rb_idP, NB_RB_MAX, enb_mod_idP, ue_mod_idP); DevCheck4(rb_idP < NB_RB_MAX, rb_idP, NB_RB_MAX, enb_mod_idP, ue_mod_idP);
if (enb_flagP == 0) { if (enb_flagP == ENB_FLAG_NO) {
pdcp_p = &pdcp_array_ue[ue_mod_idP][rb_idP]; pdcp_p = &pdcp_array_ue[ue_mod_idP][rb_idP];
LOG_I(PDCP, "Data indication notification for PDCP entity from eNB %u to UE %u " LOG_I(PDCP, "Data indication notification for PDCP entity from eNB %u to UE %u "
...@@ -484,7 +484,7 @@ boolean_t pdcp_data_ind(module_id_t enb_mod_idP, module_id_t ue_mod_idP, frame_t ...@@ -484,7 +484,7 @@ boolean_t pdcp_data_ind(module_id_t enb_mod_idP, module_id_t ue_mod_idP, frame_t
int ctime; int ctime;
src_id = (enb_flagP != 0) ? ue_mod_idP : enb_mod_idP; src_id = (enb_flagP != 0) ? ue_mod_idP : enb_mod_idP;
dst_id = (enb_flagP == 0) ? ue_mod_idP : enb_mod_idP; dst_id = (enb_flagP == ENB_FLAG_NO) ? ue_mod_idP : enb_mod_idP;
ctime = oai_emulation.info.time_ms; // avg current simulation time in ms : we may get the exact time through OCG? ctime = oai_emulation.info.time_ms; // avg current simulation time in ms : we may get the exact time through OCG?
LOG_D(PDCP, "Check received buffer : enb_flag %d rab id %d (src %d, dst %d)\n", LOG_D(PDCP, "Check received buffer : enb_flag %d rab id %d (src %d, dst %d)\n",
enb_flagP, rb_idP, src_id, dst_id); enb_flagP, rb_idP, src_id, dst_id);
...@@ -521,7 +521,7 @@ boolean_t pdcp_data_ind(module_id_t enb_mod_idP, module_id_t ue_mod_idP, frame_t ...@@ -521,7 +521,7 @@ boolean_t pdcp_data_ind(module_id_t enb_mod_idP, module_id_t ue_mod_idP, frame_t
// Here there is no virtualization possible // Here there is no virtualization possible
// set ((pdcp_data_ind_header_t *) new_sdu_p->data)->inst for IP layer here // set ((pdcp_data_ind_header_t *) new_sdu_p->data)->inst for IP layer here
if (enb_flagP == 0) { if (enb_flagP == ENB_FLAG_NO) {
((pdcp_data_ind_header_t *) new_sdu_p->data)->rb_id = rb_idP; ((pdcp_data_ind_header_t *) new_sdu_p->data)->rb_id = rb_idP;
#if defined(OAI_EMU) #if defined(OAI_EMU)
((pdcp_data_ind_header_t *) new_sdu_p->data)->inst = ue_mod_idP + oai_emulation.info.nb_enb_local - oai_emulation.info.first_ue_local; ((pdcp_data_ind_header_t *) new_sdu_p->data)->inst = ue_mod_idP + oai_emulation.info.nb_enb_local - oai_emulation.info.first_ue_local;
...@@ -703,12 +703,12 @@ boolean_t rrc_pdcp_config_asn1_req (module_id_t enb_mod_idP, ...@@ -703,12 +703,12 @@ boolean_t rrc_pdcp_config_asn1_req (module_id_t enb_mod_idP,
rlc_mode_t rlc_type = RLC_MODE_NONE; rlc_mode_t rlc_type = RLC_MODE_NONE;
DRB_Identity_t drb_id = 0; DRB_Identity_t drb_id = 0;
DRB_Identity_t *pdrb_id_p = NULL; DRB_Identity_t *pdrb_id_p = NULL;
uint8_t drb_sn = 0; uint8_t drb_sn = 0;
uint8_t srb_sn = 5; // fixed sn for SRBs uint8_t srb_sn = 5; // fixed sn for SRBs
uint8_t drb_report = 0; uint8_t drb_report = 0;
long int cnt = 0; long int cnt = 0;
uint16_t header_compression_profile = 0; uint16_t header_compression_profile = 0;
uint32_t action = ACTION_ADD; config_action_t action = CONFIG_ACTION_ADD;
SRB_ToAddMod_t *srb_toaddmod_p = NULL; SRB_ToAddMod_t *srb_toaddmod_p = NULL;
DRB_ToAddMod_t *drb_toaddmod_p = NULL; DRB_ToAddMod_t *drb_toaddmod_p = NULL;
pdcp_t *pdcp_p = NULL; pdcp_t *pdcp_p = NULL;
...@@ -719,7 +719,7 @@ boolean_t rrc_pdcp_config_asn1_req (module_id_t enb_mod_idP, ...@@ -719,7 +719,7 @@ boolean_t rrc_pdcp_config_asn1_req (module_id_t enb_mod_idP,
MBMS_SessionInfo_r9_t *MBMS_SessionInfo_p = NULL; MBMS_SessionInfo_r9_t *MBMS_SessionInfo_p = NULL;
#endif #endif
if (enb_flagP == 0) { if (enb_flagP == ENB_FLAG_NO) {
LOG_D(PDCP, "[UE %u] CONFIG REQ ASN1 for eNB %u\n", ue_mod_idP, enb_mod_idP); LOG_D(PDCP, "[UE %u] CONFIG REQ ASN1 for eNB %u\n", ue_mod_idP, enb_mod_idP);
} else { } else {
LOG_D(PDCP, "[eNB %u] CONFIG REQ ASN1 for UE %u\n", enb_mod_idP, ue_mod_idP); LOG_D(PDCP, "[eNB %u] CONFIG REQ ASN1 for UE %u\n", enb_mod_idP, ue_mod_idP);
...@@ -734,16 +734,16 @@ boolean_t rrc_pdcp_config_asn1_req (module_id_t enb_mod_idP, ...@@ -734,16 +734,16 @@ boolean_t rrc_pdcp_config_asn1_req (module_id_t enb_mod_idP,
rb_id = srb_id; rb_id = srb_id;
lc_id = srb_id; lc_id = srb_id;
if (enb_flagP == 0) { if (enb_flagP == ENB_FLAG_NO) {
pdcp_p = &pdcp_array_ue[ue_mod_idP][srb_id]; pdcp_p = &pdcp_array_ue[ue_mod_idP][srb_id];
} else { } else {
pdcp_p = &pdcp_array_eNB[enb_mod_idP][ue_mod_idP][srb_id]; pdcp_p = &pdcp_array_eNB[enb_mod_idP][ue_mod_idP][srb_id];
} }
if (pdcp_p->instanciated_instance == 1) { if (pdcp_p->instanciated_instance == TRUE) {
action = ACTION_MODIFY; action = CONFIG_ACTION_MODIFY;
} else { } else {
action = ACTION_ADD; action = CONFIG_ACTION_ADD;
} }
if (srb_toaddmod_p->rlc_Config) { if (srb_toaddmod_p->rlc_Config) {
...@@ -803,16 +803,16 @@ boolean_t rrc_pdcp_config_asn1_req (module_id_t enb_mod_idP, ...@@ -803,16 +803,16 @@ boolean_t rrc_pdcp_config_asn1_req (module_id_t enb_mod_idP,
DevCheck4(rb_id < NB_RB_MAX, rb_id, NB_RB_MAX, ue_mod_idP, enb_mod_idP); DevCheck4(rb_id < NB_RB_MAX, rb_id, NB_RB_MAX, ue_mod_idP, enb_mod_idP);
if (enb_flagP == 0) { if (enb_flagP == ENB_FLAG_NO) {
pdcp_p = &pdcp_array_ue[ue_mod_idP][rb_id]; pdcp_p = &pdcp_array_ue[ue_mod_idP][rb_id];
} else { } else {
pdcp_p = &pdcp_array_eNB[enb_mod_idP][ue_mod_idP][rb_id]; pdcp_p = &pdcp_array_eNB[enb_mod_idP][ue_mod_idP][rb_id];
} }
if (pdcp_p->instanciated_instance == 1) if (pdcp_p->instanciated_instance == TRUE)
action = ACTION_MODIFY; action = CONFIG_ACTION_MODIFY;
else else
action = ACTION_ADD; action = CONFIG_ACTION_ADD;
if (drb_toaddmod_p->pdcp_Config){ if (drb_toaddmod_p->pdcp_Config){
if (drb_toaddmod_p->pdcp_Config->discardTimer) { if (drb_toaddmod_p->pdcp_Config->discardTimer) {
...@@ -887,12 +887,12 @@ boolean_t rrc_pdcp_config_asn1_req (module_id_t enb_mod_idP, ...@@ -887,12 +887,12 @@ boolean_t rrc_pdcp_config_asn1_req (module_id_t enb_mod_idP,
for (cnt=0;cnt<drb2release_list_pP->list.count;cnt++) { for (cnt=0;cnt<drb2release_list_pP->list.count;cnt++) {
pdrb_id_p = drb2release_list_pP->list.array[cnt]; pdrb_id_p = drb2release_list_pP->list.array[cnt];
rb_id = *pdrb_id_p; rb_id = *pdrb_id_p;
if (enb_flagP == 0) { if (enb_flagP == ENB_FLAG_NO) {
pdcp_p = &pdcp_array_ue[ue_mod_idP][rb_id]; pdcp_p = &pdcp_array_ue[ue_mod_idP][rb_id];
} else { } else {
pdcp_p = &pdcp_array_eNB[enb_mod_idP][ue_mod_idP][rb_id]; pdcp_p = &pdcp_array_eNB[enb_mod_idP][ue_mod_idP][rb_id];
} }
action = ACTION_REMOVE; action = CONFIG_ACTION_REMOVE;
pdcp_config_req_asn1 (pdcp_p, pdcp_config_req_asn1 (pdcp_p,
enb_mod_idP, enb_mod_idP,
ue_mod_idP, ue_mod_idP,
...@@ -925,16 +925,16 @@ boolean_t rrc_pdcp_config_asn1_req (module_id_t enb_mod_idP, ...@@ -925,16 +925,16 @@ boolean_t rrc_pdcp_config_asn1_req (module_id_t enb_mod_idP,
// can set the mch_id = i // can set the mch_id = i
if (enb_flagP) { if (enb_flagP) {
rb_id = (mch_id * maxSessionPerPMCH ) + lc_id; // 1 rb_id = (mch_id * maxSessionPerPMCH ) + lc_id; // 1
if (pdcp_mbms_array_eNB[enb_mod_idP][mch_id][lc_id].instanciated_instance == enb_mod_idP + 1) if (pdcp_mbms_array_eNB[enb_mod_idP][mch_id][lc_id].instanciated_instance == TRUE)
action = ACTION_MBMS_MODIFY; action = CONFIG_ACTION_MBMS_MODIFY;
else else
action = ACTION_MBMS_ADD; action = CONFIG_ACTION_MBMS_ADD;
} else { } else {
rb_id = (mch_id * maxSessionPerPMCH ) + lc_id + (maxDRB + 3); // 15 rb_id = (mch_id * maxSessionPerPMCH ) + lc_id + (maxDRB + 3); // 15
if (pdcp_mbms_array_ue[ue_mod_idP][mch_id][lc_id].instanciated_instance == ue_mod_idP + 1) if (pdcp_mbms_array_ue[ue_mod_idP][mch_id][lc_id].instanciated_instance == TRUE)
action = ACTION_MBMS_MODIFY; action = CONFIG_ACTION_MBMS_MODIFY;
else else
action = ACTION_MBMS_ADD; action = CONFIG_ACTION_MBMS_ADD;
} }
...@@ -971,24 +971,24 @@ boolean_t pdcp_config_req_asn1 (pdcp_t *pdcp_pP, ...@@ -971,24 +971,24 @@ boolean_t pdcp_config_req_asn1 (pdcp_t *pdcp_pP,
frame_t frameP, frame_t frameP,
eNB_flag_t enb_flagP, eNB_flag_t enb_flagP,
rlc_mode_t rlc_modeP, rlc_mode_t rlc_modeP,
uint32_t actionP, config_action_t actionP,
uint16_t lc_idP, uint16_t lc_idP,
uint16_t mch_idP, uint16_t mch_idP,
rb_id_t rb_idP, rb_id_t rb_idP,
uint8_t rb_snP, uint8_t rb_snP,
uint8_t rb_reportP, uint8_t rb_reportP,
uint16_t header_compression_profileP, uint16_t header_compression_profileP,
uint8_t security_modeP, uint8_t security_modeP,
uint8_t *kRRCenc_pP, uint8_t *kRRCenc_pP,
uint8_t *kRRCint_pP, uint8_t *kRRCint_pP,
uint8_t *kUPenc_pP) uint8_t *kUPenc_pP)
{ {
switch (actionP) { switch (actionP) {
case ACTION_ADD: case CONFIG_ACTION_ADD:
DevAssert(pdcp_pP != NULL); DevAssert(pdcp_pP != NULL);
pdcp_pP->instanciated_instance = 1; pdcp_pP->instanciated_instance = TRUE;
pdcp_pP->is_ue = (enb_flagP == 0) ? 1 : 0; pdcp_pP->is_ue = (enb_flagP == ENB_FLAG_NO) ? TRUE : FALSE;
pdcp_pP->lcid = lc_idP; pdcp_pP->lcid = lc_idP;
pdcp_pP->header_compression_profile = header_compression_profileP; pdcp_pP->header_compression_profile = header_compression_profileP;
pdcp_pP->status_report = rb_reportP; pdcp_pP->status_report = rb_reportP;
...@@ -1009,7 +1009,7 @@ boolean_t pdcp_config_req_asn1 (pdcp_t *pdcp_pP, ...@@ -1009,7 +1009,7 @@ boolean_t pdcp_config_req_asn1 (pdcp_t *pdcp_pP,
pdcp_pP->last_submitted_pdcp_rx_sn = 4095; pdcp_pP->last_submitted_pdcp_rx_sn = 4095;
pdcp_pP->first_missing_pdu = -1; pdcp_pP->first_missing_pdu = -1;
if (enb_flagP == 0) { if (enb_flagP == ENB_FLAG_NO) {
LOG_I(PDCP, "[UE %d] Config request : Action ADD for eNB %d: Frame %d LCID %d (rb id %d) " LOG_I(PDCP, "[UE %d] Config request : Action ADD for eNB %d: Frame %d LCID %d (rb id %d) "
"configured with SN size %d bits and RLC %s\n", "configured with SN size %d bits and RLC %s\n",
ue_mod_idP, enb_mod_idP, frameP, lc_idP, rb_idP, pdcp_pP->seq_num_size, ue_mod_idP, enb_mod_idP, frameP, lc_idP, rb_idP, pdcp_pP->seq_num_size,
...@@ -1026,10 +1026,10 @@ boolean_t pdcp_config_req_asn1 (pdcp_t *pdcp_pP, ...@@ -1026,10 +1026,10 @@ boolean_t pdcp_config_req_asn1 (pdcp_t *pdcp_pP,
pdcp_config_set_security(pdcp_pP, enb_mod_idP, ue_mod_idP, frameP, enb_flagP, rb_idP, lc_idP, security_modeP, kRRCenc_pP, kRRCint_pP, kUPenc_pP); pdcp_config_set_security(pdcp_pP, enb_mod_idP, ue_mod_idP, frameP, enb_flagP, rb_idP, lc_idP, security_modeP, kRRCenc_pP, kRRCint_pP, kUPenc_pP);
} }
LOG_D(PDCP, "[FRAME %5u][%s][PDCP][MOD %u/%u][RB %u]\n", frameP, (enb_flagP == 0) ? "UE" : "eNB", enb_mod_idP, ue_mod_idP, rb_idP); LOG_D(PDCP, "[FRAME %5u][%s][PDCP][MOD %u/%u][RB %u]\n", frameP, (enb_flagP == ENB_FLAG_NO) ? "UE" : "eNB", enb_mod_idP, ue_mod_idP, rb_idP);
break; break;
case ACTION_MODIFY: case CONFIG_ACTION_MODIFY:
DevAssert(pdcp_pP != NULL); DevAssert(pdcp_pP != NULL);
pdcp_pP->header_compression_profile=header_compression_profileP; pdcp_pP->header_compression_profile=header_compression_profileP;
pdcp_pP->status_report = rb_reportP; pdcp_pP->status_report = rb_reportP;
...@@ -1048,7 +1048,7 @@ boolean_t pdcp_config_req_asn1 (pdcp_t *pdcp_pP, ...@@ -1048,7 +1048,7 @@ boolean_t pdcp_config_req_asn1 (pdcp_t *pdcp_pP,
pdcp_pP->seq_num_size=5; pdcp_pP->seq_num_size=5;
} }
if (enb_flagP == 0) { if (enb_flagP == ENB_FLAG_NO) {
LOG_I(PDCP,"[UE %d] Config request : Action MODIFY for eNB %d: Frame %d LCID %d " LOG_I(PDCP,"[UE %d] Config request : Action MODIFY for eNB %d: Frame %d LCID %d "
"RB id %d configured with SN size %d and RLC %s \n", "RB id %d configured with SN size %d and RLC %s \n",
ue_mod_idP, enb_mod_idP, frameP, lc_idP, rb_idP, rb_snP, ue_mod_idP, enb_mod_idP, frameP, lc_idP, rb_idP, rb_snP,
...@@ -1060,9 +1060,9 @@ boolean_t pdcp_config_req_asn1 (pdcp_t *pdcp_pP, ...@@ -1060,9 +1060,9 @@ boolean_t pdcp_config_req_asn1 (pdcp_t *pdcp_pP,
(rlc_modeP == 1) ? "AM" : (rlc_modeP == 2) ? "TM" : "UM"); (rlc_modeP == 1) ? "AM" : (rlc_modeP == 2) ? "TM" : "UM");
} }
break; break;
case ACTION_REMOVE: case CONFIG_ACTION_REMOVE:
DevAssert(pdcp_pP != NULL); DevAssert(pdcp_pP != NULL);
pdcp_pP->instanciated_instance = 0; pdcp_pP->instanciated_instance = FALSE;
pdcp_pP->lcid = 0; pdcp_pP->lcid = 0;
pdcp_pP->header_compression_profile = 0x0; pdcp_pP->header_compression_profile = 0x0;
pdcp_pP->cipheringAlgorithm = 0xff; pdcp_pP->cipheringAlgorithm = 0xff;
...@@ -1078,11 +1078,11 @@ boolean_t pdcp_config_req_asn1 (pdcp_t *pdcp_pP, ...@@ -1078,11 +1078,11 @@ boolean_t pdcp_config_req_asn1 (pdcp_t *pdcp_pP,
pdcp_pP->first_missing_pdu = -1; pdcp_pP->first_missing_pdu = -1;
pdcp_pP->security_activated = 0; pdcp_pP->security_activated = 0;
if (enb_flagP == 0) { if (enb_flagP == ENB_FLAG_NO) {
LOG_I(PDCP, "[UE %d] Config request : ACTION_REMOVE for eNB %d: Frame %d LCID %d RBID %d configured\n", LOG_I(PDCP, "[UE %d] Config request : CONFIG_ACTION_REMOVE for eNB %d: Frame %d LCID %d RBID %d configured\n",
ue_mod_idP, enb_mod_idP, frameP, lc_idP, rb_idP); ue_mod_idP, enb_mod_idP, frameP, lc_idP, rb_idP);
} else { } else {
LOG_I(PDCP, "[eNB %d] Config request : ACTION_REMOVE for UE %d: Frame %d LCID %d RBID %d configured\n", LOG_I(PDCP, "[eNB %d] Config request : CONFIG_ACTION_REMOVE for UE %d: Frame %d LCID %d RBID %d configured\n",
enb_mod_idP, ue_mod_idP, frameP, lc_idP, rb_idP); enb_mod_idP, ue_mod_idP, frameP, lc_idP, rb_idP);
} }
/* Security keys */ /* Security keys */
...@@ -1097,25 +1097,25 @@ boolean_t pdcp_config_req_asn1 (pdcp_t *pdcp_pP, ...@@ -1097,25 +1097,25 @@ boolean_t pdcp_config_req_asn1 (pdcp_t *pdcp_pP,
} }
break; break;
#if defined(Rel10) #if defined(Rel10)
case ACTION_MBMS_ADD: case CONFIG_ACTION_MBMS_ADD:
case ACTION_MBMS_MODIFY: case CONFIG_ACTION_MBMS_MODIFY:
if (enb_flagP == 0) { if (enb_flagP == ENB_FLAG_NO) {
LOG_I(PDCP,"[UE %d] Config request for eNB %d: %s: Frame %d service_id/mch index %d, session_id/lcid %d, rbid %d configured\n", LOG_I(PDCP,"[UE %d] Config request for eNB %d: %s: Frame %d service_id/mch index %d, session_id/lcid %d, rbid %d configured\n",
ue_mod_idP, enb_mod_idP, actionP == ACTION_MBMS_ADD ? "ACTION_MBMS_ADD" : "ACTION_MBMS_MODIFY", frameP, mch_idP, lc_idP, rb_idP); ue_mod_idP, enb_mod_idP, actionP == CONFIG_ACTION_MBMS_ADD ? "CONFIG_ACTION_MBMS_ADD" : "CONFIG_ACTION_MBMS_MODIFY", frameP, mch_idP, lc_idP, rb_idP);
} else { } else {
LOG_I(PDCP,"[eNB %d] Config request for UE %d: %s: Frame %d service_id/mch index %d, session_id/lcid %d, rbid %d configured\n", LOG_I(PDCP,"[eNB %d] Config request for UE %d: %s: Frame %d service_id/mch index %d, session_id/lcid %d, rbid %d configured\n",
enb_mod_idP, ue_mod_idP, actionP == ACTION_MBMS_ADD ? "ACTION_MBMS_ADD" : "ACTION_MBMS_MODIFY", frameP, mch_idP, lc_idP, rb_idP); enb_mod_idP, ue_mod_idP, actionP == CONFIG_ACTION_MBMS_ADD ? "CONFIG_ACTION_MBMS_ADD" : "CONFIG_ACTION_MBMS_MODIFY", frameP, mch_idP, lc_idP, rb_idP);
} }
if (enb_flagP == 1) { if (enb_flagP == 1) {
pdcp_mbms_array_eNB[enb_mod_idP][mch_idP][lc_idP].instanciated_instance = 1 ; pdcp_mbms_array_eNB[enb_mod_idP][mch_idP][lc_idP].instanciated_instance = TRUE ;
pdcp_mbms_array_eNB[enb_mod_idP][mch_idP][lc_idP].rb_id = rb_idP; pdcp_mbms_array_eNB[enb_mod_idP][mch_idP][lc_idP].rb_id = rb_idP;
} else { } else {
pdcp_mbms_array_eNB[ue_mod_idP][mch_idP][lc_idP].instanciated_instance = 1 ; pdcp_mbms_array_eNB[ue_mod_idP][mch_idP][lc_idP].instanciated_instance = TRUE ;
pdcp_mbms_array_eNB[ue_mod_idP][mch_idP][lc_idP].rb_id = rb_idP; pdcp_mbms_array_eNB[ue_mod_idP][mch_idP][lc_idP].rb_id = rb_idP;
} }
break; break;
#endif #endif
case ACTION_SET_SECURITY_MODE: case CONFIG_ACTION_SET_SECURITY_MODE:
pdcp_config_set_security(pdcp_pP, enb_mod_idP, ue_mod_idP, frameP, enb_flagP, rb_idP, lc_idP, security_modeP, kRRCenc_pP, kRRCint_pP, kUPenc_pP); pdcp_config_set_security(pdcp_pP, enb_mod_idP, ue_mod_idP, frameP, enb_flagP, rb_idP, lc_idP, security_modeP, kRRCenc_pP, kRRCint_pP, kUPenc_pP);
break; break;
default: default:
...@@ -1143,12 +1143,12 @@ void pdcp_config_set_security(pdcp_t *pdcp_pP, ...@@ -1143,12 +1143,12 @@ void pdcp_config_set_security(pdcp_t *pdcp_pP,
pdcp_pP->cipheringAlgorithm = security_modeP & 0x0f; pdcp_pP->cipheringAlgorithm = security_modeP & 0x0f;
pdcp_pP->integrityProtAlgorithm = (security_modeP>>4) & 0xf; pdcp_pP->integrityProtAlgorithm = (security_modeP>>4) & 0xf;
if (enb_flagP == 0) { if (enb_flagP == ENB_FLAG_NO) {
LOG_D(PDCP,"[UE %d][RB %02d] Set security mode : ACTION_SET_SECURITY_MODE: " LOG_D(PDCP,"[UE %d][RB %02d] Set security mode : CONFIG_ACTION_SET_SECURITY_MODE: "
"Frame %d cipheringAlgorithm %d integrityProtAlgorithm %d\n", "Frame %d cipheringAlgorithm %d integrityProtAlgorithm %d\n",
ue_mod_idP, rb_idP, frameP, pdcp_pP->cipheringAlgorithm, pdcp_pP->integrityProtAlgorithm); ue_mod_idP, rb_idP, frameP, pdcp_pP->cipheringAlgorithm, pdcp_pP->integrityProtAlgorithm);
} else { } else {
LOG_D(PDCP,"[eNB %d][UE %d][RB %02d] Set security mode : ACTION_SET_SECURITY_MODE: " LOG_D(PDCP,"[eNB %d][UE %d][RB %02d] Set security mode : CONFIG_ACTION_SET_SECURITY_MODE: "
"Frame %d cipheringAlgorithm %d integrityProtAlgorithm %d\n", "Frame %d cipheringAlgorithm %d integrityProtAlgorithm %d\n",
enb_mod_idP, ue_mod_idP, rb_idP, frameP, pdcp_pP->cipheringAlgorithm, pdcp_pP->integrityProtAlgorithm); enb_mod_idP, ue_mod_idP, rb_idP, frameP, pdcp_pP->cipheringAlgorithm, pdcp_pP->integrityProtAlgorithm);
} }
...@@ -1177,8 +1177,8 @@ void rrc_pdcp_config_req (module_id_t enb_mod_idP, module_id_t ue_mod_idP, frame ...@@ -1177,8 +1177,8 @@ void rrc_pdcp_config_req (module_id_t enb_mod_idP, module_id_t ue_mod_idP, frame
* Initialize sequence number state variables of relevant PDCP entity * Initialize sequence number state variables of relevant PDCP entity
*/ */
switch (actionP) { switch (actionP) {
case ACTION_ADD: case CONFIG_ACTION_ADD:
pdcp_p->instanciated_instance = 1; pdcp_p->instanciated_instance = TRUE;
pdcp_p->next_pdcp_tx_sn = 0; pdcp_p->next_pdcp_tx_sn = 0;
pdcp_p->next_pdcp_rx_sn = 0; pdcp_p->next_pdcp_rx_sn = 0;
...@@ -1196,10 +1196,10 @@ void rrc_pdcp_config_req (module_id_t enb_mod_idP, module_id_t ue_mod_idP, frame ...@@ -1196,10 +1196,10 @@ void rrc_pdcp_config_req (module_id_t enb_mod_idP, module_id_t ue_mod_idP, frame
LOG_D(PDCP,"[%s %d] Config request : Action ADD: Frame %d radio bearer id %d configured\n", LOG_D(PDCP,"[%s %d] Config request : Action ADD: Frame %d radio bearer id %d configured\n",
(enb_flagP) ? "eNB" : "UE", (enb_flagP) ? enb_mod_idP : ue_mod_idP, frameP, rb_idP); (enb_flagP) ? "eNB" : "UE", (enb_flagP) ? enb_mod_idP : ue_mod_idP, frameP, rb_idP);
break; break;
case ACTION_MODIFY: case CONFIG_ACTION_MODIFY:
break; break;
case ACTION_REMOVE: case CONFIG_ACTION_REMOVE:
pdcp_p->instanciated_instance = 0; pdcp_p->instanciated_instance = FALSE;
pdcp_p->next_pdcp_tx_sn = 0; pdcp_p->next_pdcp_tx_sn = 0;
pdcp_p->next_pdcp_rx_sn = 0; pdcp_p->next_pdcp_rx_sn = 0;
pdcp_p->tx_hfn = 0; pdcp_p->tx_hfn = 0;
...@@ -1208,15 +1208,15 @@ void rrc_pdcp_config_req (module_id_t enb_mod_idP, module_id_t ue_mod_idP, frame ...@@ -1208,15 +1208,15 @@ void rrc_pdcp_config_req (module_id_t enb_mod_idP, module_id_t ue_mod_idP, frame
pdcp_p->seq_num_size = 0; pdcp_p->seq_num_size = 0;
pdcp_p->first_missing_pdu = -1; pdcp_p->first_missing_pdu = -1;
pdcp_p->security_activated = 0; pdcp_p->security_activated = 0;
LOG_D(PDCP,"[%s %d] Config request : ACTION_REMOVE: Frame %d radio bearer id %d configured\n", LOG_D(PDCP,"[%s %d] Config request : CONFIG_ACTION_REMOVE: Frame %d radio bearer id %d configured\n",
(enb_flagP) ? "eNB" : "UE", (enb_flagP) ? enb_mod_idP : ue_mod_idP, frameP, rb_idP); (enb_flagP) ? "eNB" : "UE", (enb_flagP) ? enb_mod_idP : ue_mod_idP, frameP, rb_idP);
break; break;
case ACTION_SET_SECURITY_MODE: case CONFIG_ACTION_SET_SECURITY_MODE:
if ((security_modeP >= 0) && (security_modeP <= 0x77)) { if ((security_modeP >= 0) && (security_modeP <= 0x77)) {
pdcp_p->cipheringAlgorithm= security_modeP & 0x0f; pdcp_p->cipheringAlgorithm= security_modeP & 0x0f;
pdcp_p->integrityProtAlgorithm = (security_modeP>>4) & 0xf; pdcp_p->integrityProtAlgorithm = (security_modeP>>4) & 0xf;
LOG_D(PDCP,"[%s %d]Set security mode : ACTION_SET_SECURITY_MODE: Frame %d cipheringAlgorithm %d integrityProtAlgorithm %d\n", LOG_D(PDCP,"[%s %d]Set security mode : CONFIG_ACTION_SET_SECURITY_MODE: Frame %d cipheringAlgorithm %d integrityProtAlgorithm %d\n",
(enb_flagP) ? "eNB" : "UE", (enb_flagP) ? enb_mod_idP : ue_mod_idP, frameP, (enb_flagP) ? "eNB" : "UE", (enb_flagP) ? enb_mod_idP : ue_mod_idP, frameP,
pdcp_p->cipheringAlgorithm, pdcp_p->cipheringAlgorithm,
pdcp_p->integrityProtAlgorithm ); pdcp_p->integrityProtAlgorithm );
......
...@@ -693,7 +693,7 @@ int pdcp_fifo_read_input_sdus (frame_t frameP, eNB_flag_t enb_flagP, module_id_t ...@@ -693,7 +693,7 @@ int pdcp_fifo_read_input_sdus (frame_t frameP, eNB_flag_t enb_flagP, module_id_t
// is a broadcast packet, we have to send this packet on all default RABS of all connected UEs // is a broadcast packet, we have to send this packet on all default RABS of all connected UEs
#warning CODE TO BE REVIEWED, ONLY WORK FOR SIMPLE TOPOLOGY CASES #warning CODE TO BE REVIEWED, ONLY WORK FOR SIMPLE TOPOLOGY CASES
for (ue_mod_idP = 0; ue_mod_idP < NB_UE_INST; ue_mod_idP++) { for (ue_mod_idP = 0; ue_mod_idP < NB_UE_INST; ue_mod_idP++) {
if (pdcp_array_eNB[enb_mod_idP][ue_mod_idP][rab_id].instanciated_instance > 0) { if (pdcp_array_eNB[enb_mod_idP][ue_mod_idP][rab_id].instanciated_instance == TRUE) {
LOG_D(PDCP, "[FRAME %5u][eNB][IP][INSTANCE %u][RB %u][--- PDCP_DATA_REQ / %d Bytes --->][PDCP][MOD %u/%u][RB DEFAULT_RAB_ID %u]\n", LOG_D(PDCP, "[FRAME %5u][eNB][IP][INSTANCE %u][RB %u][--- PDCP_DATA_REQ / %d Bytes --->][PDCP][MOD %u/%u][RB DEFAULT_RAB_ID %u]\n",
frameP, frameP,
pdcp_read_header_g.inst, pdcp_read_header_g.inst,
......
...@@ -149,8 +149,8 @@ rlc_info_t Rlc_info_am_config1; ...@@ -149,8 +149,8 @@ rlc_info_t Rlc_info_am_config1;
Rlc_info_am_config1.rlc.rlc_am_info.last_transmission_pdu_poll_trigger = 1;//boolean Rlc_info_am_config1.rlc.rlc_am_info.last_transmission_pdu_poll_trigger = 1;//boolean
Rlc_info_am_config1.rlc.rlc_am_info.last_retransmission_pdu_poll_trigger = 1;//boolean Rlc_info_am_config1.rlc.rlc_am_info.last_retransmission_pdu_poll_trigger = 1;//boolean
Rlc_info_am_config1.rlc.rlc_am_info.send_mrw = 1;//boolean* Rlc_info_am_config1.rlc.rlc_am_info.send_mrw = 1;//boolean*
Mac_rlc_xface->rrc_rlc_config_req(0,ACTION_REMOVE,rlcP->rb_id,RADIO_ACCESS_BEARER,Rlc_info_am_config1); Mac_rlc_xface->rrc_rlc_config_req(0,CONFIG_ACTION_REMOVE,rlcP->rb_id,RADIO_ACCESS_BEARER,Rlc_info_am_config1);
Mac_rlc_xface->rrc_rlc_config_req(0,ACTION_ADD,rlcP->rb_id,RADIO_ACCESS_BEARER,Rlc_info_am_config1); Mac_rlc_xface->rrc_rlc_config_req(0,CONFIG_ACTION_ADD,rlcP->rb_id,RADIO_ACCESS_BEARER,Rlc_info_am_config1);
#endif #endif
} }
......
...@@ -314,7 +314,7 @@ rlc_um_rx (void *argP, frame_t frameP, eNB_flag_t eNB_flagP, struct mac_data_ind ...@@ -314,7 +314,7 @@ rlc_um_rx (void *argP, frame_t frameP, eNB_flag_t eNB_flagP, struct mac_data_ind
message_string_size += sprintf(&message_string[message_string_size], " |\n"); message_string_size += sprintf(&message_string[message_string_size], " |\n");
# if defined(ENABLE_ITTI) # if defined(ENABLE_ITTI)
msg_p = itti_alloc_new_message_sized (l_rlc_p->is_enb > 0 ? TASK_RLC_ENB:TASK_RLC_UE , RLC_UM_DATA_PDU_IND, message_string_size + sizeof (IttiMsgText)); msg_p = itti_alloc_new_message_sized (l_rlc_p->is_enb ? TASK_RLC_ENB:TASK_RLC_UE , RLC_UM_DATA_PDU_IND, message_string_size + sizeof (IttiMsgText));
msg_p->ittiMsg.rlc_um_data_pdu_ind.size = message_string_size; msg_p->ittiMsg.rlc_um_data_pdu_ind.size = message_string_size;
memcpy(&msg_p->ittiMsg.rlc_um_data_pdu_ind.text, message_string, message_string_size); memcpy(&msg_p->ittiMsg.rlc_um_data_pdu_ind.text, message_string, message_string_size);
......
...@@ -416,15 +416,15 @@ rlc_op_status_t rrc_rlc_config_asn1_req (module_id_t enb_mod_idP, ...@@ -416,15 +416,15 @@ rlc_op_status_t rrc_rlc_config_asn1_req (module_id_t enb_mod_idP,
rb_id = (mbms_service_id * maxSessionPerPMCH ) + mbms_session_id; // 1 rb_id = (mbms_service_id * maxSessionPerPMCH ) + mbms_session_id; // 1
// NO CHECK // NO CHECK
/*if (rlc_mbms_array_eNB[enb_mod_idP][mbms_service_id][mbms_session_id].instanciated_instance == enb_mod_idP + 1) /*if (rlc_mbms_array_eNB[enb_mod_idP][mbms_service_id][mbms_session_id].instanciated_instance == enb_mod_idP + 1)
action = ACTION_MBMS_MODIFY; action = CONFIG_ACTION_MBMS_MODIFY;
else else
action = ACTION_MBMS_ADD;*/ action = CONFIG_ACTION_MBMS_ADD;*/
} else { } else {
rb_id = (mbms_service_id * maxSessionPerPMCH ) + mbms_session_id + (maxDRB + 3); // 15 rb_id = (mbms_service_id * maxSessionPerPMCH ) + mbms_session_id + (maxDRB + 3); // 15
/*if (rlc_mbms_array_ue[ue_mod_idP][mbms_service_id][mbms_session_id].instanciated_instance == ue_mod_idP + 1) /*if (rlc_mbms_array_ue[ue_mod_idP][mbms_service_id][mbms_session_id].instanciated_instance == ue_mod_idP + 1)
action = ACTION_MBMS_MODIFY; action = CONFIG_ACTION_MBMS_MODIFY;
else else
action = ACTION_MBMS_ADD;*/ action = CONFIG_ACTION_MBMS_ADD;*/
} }
dl_um_rlc.sn_FieldLength = SN_FieldLength_size5; dl_um_rlc.sn_FieldLength = SN_FieldLength_size5;
dl_um_rlc.t_Reordering = T_Reordering_ms0; dl_um_rlc.t_Reordering = T_Reordering_ms0;
...@@ -873,11 +873,11 @@ rlc_op_status_t rrc_rlc_config_req (module_id_t enb_mod_idP, module_id_t ue_mo ...@@ -873,11 +873,11 @@ rlc_op_status_t rrc_rlc_config_req (module_id_t enb_mod_idP, module_id_t ue_mo
switch (actionP) { switch (actionP) {
case ACTION_ADD: case CONFIG_ACTION_ADD:
if ((status = rrc_rlc_add_rlc(enb_mod_idP, ue_mod_idP, frameP, enb_flagP, rb_idP, rb_idP, rlc_infoP.rlc_mode)) != RLC_OP_STATUS_OK) { if ((status = rrc_rlc_add_rlc(enb_mod_idP, ue_mod_idP, frameP, enb_flagP, rb_idP, rb_idP, rlc_infoP.rlc_mode)) != RLC_OP_STATUS_OK) {
return status; return status;
} }
case ACTION_MODIFY: case CONFIG_ACTION_MODIFY:
switch (rlc_infoP.rlc_mode) { switch (rlc_infoP.rlc_mode) {
case RLC_MODE_AM: case RLC_MODE_AM:
LOG_I(RLC, "[Frame %05u][UE][RLC_RRC][INST %u/%u][RB %u] MODIFY RB AM\n", LOG_I(RLC, "[Frame %05u][UE][RLC_RRC][INST %u/%u][RB %u] MODIFY RB AM\n",
...@@ -930,7 +930,7 @@ rlc_op_status_t rrc_rlc_config_req (module_id_t enb_mod_idP, module_id_t ue_mo ...@@ -930,7 +930,7 @@ rlc_op_status_t rrc_rlc_config_req (module_id_t enb_mod_idP, module_id_t ue_mo
} }
break; break;
case ACTION_REMOVE: case CONFIG_ACTION_REMOVE:
return rrc_rlc_remove_rlc(enb_mod_idP, ue_mod_idP, rb_idP, frameP, enb_flagP); return rrc_rlc_remove_rlc(enb_mod_idP, ue_mod_idP, rb_idP, frameP, enb_flagP);
break; break;
default: default:
......
...@@ -538,8 +538,8 @@ int32_t rrc_ue_establish_srb1(module_id_t Mod_id, frame_t frameP,uint8_t eNB_ind ...@@ -538,8 +538,8 @@ int32_t rrc_ue_establish_srb1(module_id_t Mod_id, frame_t frameP,uint8_t eNB_ind
LOG_I(RRC,"[UE %d], CONFIG_SRB1 %d corresponding to eNB_index %d\n", Mod_id,lchan_id,eNB_index); LOG_I(RRC,"[UE %d], CONFIG_SRB1 %d corresponding to eNB_index %d\n", Mod_id,lchan_id,eNB_index);
//rrc_pdcp_config_req (Mod_id+NB_eNB_INST, frameP, 0, ACTION_ADD, lchan_id,UNDEF_SECURITY_MODE); //rrc_pdcp_config_req (Mod_id+NB_eNB_INST, frameP, 0, CONFIG_ACTION_ADD, lchan_id,UNDEF_SECURITY_MODE);
// rrc_rlc_config_req(Mod_id+NB_eNB_INST,frameP,0,ACTION_ADD,lchan_id,SIGNALLING_RADIO_BEARER,Rlc_info_am_config); // rrc_rlc_config_req(Mod_id+NB_eNB_INST,frameP,0,CONFIG_ACTION_ADD,lchan_id,SIGNALLING_RADIO_BEARER,Rlc_info_am_config);
// UE_rrc_inst[Mod_id].Srb1[eNB_index].Srb_info.Tx_buffer.payload_size=DEFAULT_MEAS_IND_SIZE+1; // UE_rrc_inst[Mod_id].Srb1[eNB_index].Srb_info.Tx_buffer.payload_size=DEFAULT_MEAS_IND_SIZE+1;
...@@ -563,8 +563,8 @@ int32_t rrc_ue_establish_srb2(module_id_t Mod_id, frame_t frameP,uint8_t eNB_ind ...@@ -563,8 +563,8 @@ int32_t rrc_ue_establish_srb2(module_id_t Mod_id, frame_t frameP,uint8_t eNB_ind
LOG_I(RRC,"[UE %d], CONFIG_SRB2 %d corresponding to eNB_index %d\n",Mod_id,lchan_id,eNB_index); LOG_I(RRC,"[UE %d], CONFIG_SRB2 %d corresponding to eNB_index %d\n",Mod_id,lchan_id,eNB_index);
//rrc_pdcp_config_req (Mod_id+NB_eNB_INST, frameP, 0, ACTION_ADD, lchan_id, UNDEF_SECURITY_MODE); //rrc_pdcp_config_req (Mod_id+NB_eNB_INST, frameP, 0, CONFIG_ACTION_ADD, lchan_id, UNDEF_SECURITY_MODE);
// rrc_rlc_config_req(Mod_id+NB_eNB_INST,frameP,0,ACTION_ADD,lchan_id,SIGNALLING_RADIO_BEARER,Rlc_info_am_config); // rrc_rlc_config_req(Mod_id+NB_eNB_INST,frameP,0,CONFIG_ACTION_ADD,lchan_id,SIGNALLING_RADIO_BEARER,Rlc_info_am_config);
// UE_rrc_inst[Mod_id].Srb1[eNB_index].Srb_info.Tx_buffer.payload_size=DEFAULT_MEAS_IND_SIZE+1; // UE_rrc_inst[Mod_id].Srb1[eNB_index].Srb_info.Tx_buffer.payload_size=DEFAULT_MEAS_IND_SIZE+1;
...@@ -581,10 +581,10 @@ int32_t rrc_ue_establish_drb(module_id_t Mod_id, frame_t frameP,uint8_t eNB_inde ...@@ -581,10 +581,10 @@ int32_t rrc_ue_establish_drb(module_id_t Mod_id, frame_t frameP,uint8_t eNB_inde
LOG_I(RRC,"[UE %d] Frame %d: processing RRCConnectionReconfiguration: reconfiguring DRB %ld/LCID %d\n", LOG_I(RRC,"[UE %d] Frame %d: processing RRCConnectionReconfiguration: reconfiguring DRB %ld/LCID %d\n",
Mod_id, frameP, DRB_config->drb_Identity, (int)*DRB_config->logicalChannelIdentity); Mod_id, frameP, DRB_config->drb_Identity, (int)*DRB_config->logicalChannelIdentity);
/* /*
rrc_pdcp_config_req (Mod_id+NB_eNB_INST, frameP, 0, ACTION_ADD, rrc_pdcp_config_req (Mod_id+NB_eNB_INST, frameP, 0, CONFIG_ACTION_ADD,
(eNB_index * NB_RB_MAX) + *DRB_config->logicalChannelIdentity, UNDEF_SECURITY_MODE); (eNB_index * NB_RB_MAX) + *DRB_config->logicalChannelIdentity, UNDEF_SECURITY_MODE);
rrc_rlc_config_req(Mod_id+NB_eNB_INST,frameP,0,ACTION_ADD, rrc_rlc_config_req(Mod_id+NB_eNB_INST,frameP,0,CONFIG_ACTION_ADD,
(eNB_index * NB_RB_MAX) + *DRB_config->logicalChannelIdentity, (eNB_index * NB_RB_MAX) + *DRB_config->logicalChannelIdentity,
RADIO_ACCESS_BEARER,Rlc_info_um); RADIO_ACCESS_BEARER,Rlc_info_um);
*/ */
...@@ -1413,14 +1413,14 @@ void rrc_ue_process_mobilityControlInfo(uint8_t eNB_index, uint8_t UE_id, frame_ ...@@ -1413,14 +1413,14 @@ void rrc_ue_process_mobilityControlInfo(uint8_t eNB_index, uint8_t UE_id, frame_
//Removing SRB1 and SRB2 and DRB0 //Removing SRB1 and SRB2 and DRB0
LOG_N(RRC,"[UE %d] : Update needed for rrc_pdcp_config_req (deprecated) and rrc_rlc_config_req commands(deprecated)\n", UE_id); LOG_N(RRC,"[UE %d] : Update needed for rrc_pdcp_config_req (deprecated) and rrc_rlc_config_req commands(deprecated)\n", UE_id);
rrc_pdcp_config_req (eNB_index, UE_id, frameP, 0, ACTION_REMOVE, DCCH,UNDEF_SECURITY_MODE); rrc_pdcp_config_req (eNB_index, UE_id, frameP, 0, CONFIG_ACTION_REMOVE, DCCH,UNDEF_SECURITY_MODE);
rrc_rlc_config_req(eNB_index, Mod_id,frameP,0,ACTION_REMOVE,Mod_id+DCCH,SIGNALLING_RADIO_BEARER,Rlc_info_am_config); rrc_rlc_config_req(eNB_index, Mod_id,frameP,0,CONFIG_ACTION_REMOVE,Mod_id+DCCH,SIGNALLING_RADIO_BEARER,Rlc_info_am_config);
rrc_pdcp_config_req (eNB_index, UE_id, frameP, 0, ACTION_REMOVE, DCCH1,UNDEF_SECURITY_MODE); rrc_pdcp_config_req (eNB_index, UE_id, frameP, 0, CONFIG_ACTION_REMOVE, DCCH1,UNDEF_SECURITY_MODE);
rrc_rlc_config_req(eNB_index, Mod_id,frameP,0,ACTION_REMOVE,Mod_id+DCCH1,SIGNALLING_RADIO_BEARER,Rlc_info_am_config); rrc_rlc_config_req(eNB_index, Mod_id,frameP,0,CONFIG_ACTION_REMOVE,Mod_id+DCCH1,SIGNALLING_RADIO_BEARER,Rlc_info_am_config);
rrc_pdcp_config_req (eNB_index, UE_id, frameP, 0, ACTION_REMOVE, DTCH,UNDEF_SECURITY_MODE); rrc_pdcp_config_req (eNB_index, UE_id, frameP, 0, CONFIG_ACTION_REMOVE, DTCH,UNDEF_SECURITY_MODE);
rrc_rlc_config_req(eNB_index, Mod_id,frameP,0,ACTION_REMOVE,Mod_id+DTCH,RADIO_ACCESS_BEARER,Rlc_info_um); rrc_rlc_config_req(eNB_index, Mod_id,frameP,0,CONFIG_ACTION_REMOVE,Mod_id+DTCH,RADIO_ACCESS_BEARER,Rlc_info_um);
/* /*
rrc_pdcp_config_asn1_req(NB_eNB_INST+Mod_id,frameP, 0,eNB_index, rrc_pdcp_config_asn1_req(NB_eNB_INST+Mod_id,frameP, 0,eNB_index,
NULL, // SRB_ToAddModList NULL, // SRB_ToAddModList
...@@ -1496,15 +1496,15 @@ void rrc_ue_process_mobilityControlInfo(uint8_t eNB_index, uint8_t UE_id, frame_ ...@@ -1496,15 +1496,15 @@ void rrc_ue_process_mobilityControlInfo(uint8_t eNB_index, uint8_t UE_id, frame_
); );
// Re-establish PDCP for all RBs that are established // Re-establish PDCP for all RBs that are established
// rrc_pdcp_config_req (Mod_id+NB_eNB_INST, frameP, 0, ACTION_ADD, Mod_id+DCCH); // rrc_pdcp_config_req (Mod_id+NB_eNB_INST, frameP, 0, CONFIG_ACTION_ADD, Mod_id+DCCH);
// rrc_pdcp_config_req (Mod_id+NB_eNB_INST, frameP, 0, ACTION_ADD, Mod_id+DCCH1); // rrc_pdcp_config_req (Mod_id+NB_eNB_INST, frameP, 0, CONFIG_ACTION_ADD, Mod_id+DCCH1);
// rrc_pdcp_config_req (Mod_id+NB_eNB_INST, frameP, 0, ACTION_ADD, Mod_id+DTCH); // rrc_pdcp_config_req (Mod_id+NB_eNB_INST, frameP, 0, CONFIG_ACTION_ADD, Mod_id+DTCH);
// Re-establish RLC for all RBs that are established // Re-establish RLC for all RBs that are established
// rrc_rlc_config_req(Mod_id+NB_eNB_INST,frameP,0,ACTION_ADD,Mod_id+DCCH,SIGNALLING_RADIO_BEARER,Rlc_info_am_config); // rrc_rlc_config_req(Mod_id+NB_eNB_INST,frameP,0,CONFIG_ACTION_ADD,Mod_id+DCCH,SIGNALLING_RADIO_BEARER,Rlc_info_am_config);
// rrc_rlc_config_req(Mod_id+NB_eNB_INST,frameP,0,ACTION_ADD,Mod_id+DCCH1,SIGNALLING_RADIO_BEARER,Rlc_info_am_config); // rrc_rlc_config_req(Mod_id+NB_eNB_INST,frameP,0,CONFIG_ACTION_ADD,Mod_id+DCCH1,SIGNALLING_RADIO_BEARER,Rlc_info_am_config);
// rrc_rlc_config_req(Mod_id+NB_eNB_INST,frameP,0,ACTION_ADD,Mod_id+DTCH,RADIO_ACCESS_BEARER,Rlc_info_um); // rrc_rlc_config_req(Mod_id+NB_eNB_INST,frameP,0,CONFIG_ACTION_ADD,Mod_id+DTCH,RADIO_ACCESS_BEARER,Rlc_info_um);
UE_rrc_inst[Mod_id].Info[eNB_index].State = RRC_SI_RECEIVED; UE_rrc_inst[Mod_id].Info[eNB_index].State = RRC_SI_RECEIVED;
......
...@@ -304,9 +304,9 @@ void rrc_t310_expiration(frame_t frameP, uint8_t Mod_id, uint8_t eNB_index) { ...@@ -304,9 +304,9 @@ void rrc_t310_expiration(frame_t frameP, uint8_t Mod_id, uint8_t eNB_index) {
if (UE_rrc_inst[Mod_id].Srb2[eNB_index].Active == 1) { if (UE_rrc_inst[Mod_id].Srb2[eNB_index].Active == 1) {
msg ("[RRC Inst %d] eNB_index %d, Remove RB %d\n ", Mod_id, eNB_index, msg ("[RRC Inst %d] eNB_index %d, Remove RB %d\n ", Mod_id, eNB_index,
UE_rrc_inst[Mod_id].Srb2[eNB_index].Srb_info.Srb_id); UE_rrc_inst[Mod_id].Srb2[eNB_index].Srb_info.Srb_id);
rrc_pdcp_config_req (eNB_index, Mod_id, frameP, 0, ACTION_REMOVE, rrc_pdcp_config_req (eNB_index, Mod_id, frameP, 0, CONFIG_ACTION_REMOVE,
UE_rrc_inst[Mod_id].Srb2[eNB_index].Srb_info.Srb_id, 0); UE_rrc_inst[Mod_id].Srb2[eNB_index].Srb_info.Srb_id, 0);
rrc_rlc_config_req (eNB_index, Mod_id, frameP, 0, ACTION_REMOVE, rrc_rlc_config_req (eNB_index, Mod_id, frameP, 0, CONFIG_ACTION_REMOVE,
UE_rrc_inst[Mod_id].Srb2[eNB_index].Srb_info.Srb_id, SIGNALLING_RADIO_BEARER, Rlc_info_um); UE_rrc_inst[Mod_id].Srb2[eNB_index].Srb_info.Srb_id, SIGNALLING_RADIO_BEARER, Rlc_info_um);
UE_rrc_inst[Mod_id].Srb2[eNB_index].Active = 0; UE_rrc_inst[Mod_id].Srb2[eNB_index].Active = 0;
UE_rrc_inst[Mod_id].Srb2[eNB_index].Status = IDLE; UE_rrc_inst[Mod_id].Srb2[eNB_index].Status = IDLE;
......
...@@ -223,7 +223,7 @@ void rrc_config_req(Instance_t Mod_id, void *smsg, unsigned char Action,Transact ...@@ -223,7 +223,7 @@ void rrc_config_req(Instance_t Mod_id, void *smsg, unsigned char Action,Transact
// msg("[RRC]Inst %d: Programing RADIO CONFIG of DCCH LCHAN %d\n",Mod_id,Idx); // msg("[RRC]Inst %d: Programing RADIO CONFIG of DCCH LCHAN %d\n",Mod_id,Idx);
//CH_rrc_inst[Mod_id].Nb_rb[UE_index]++; //CH_rrc_inst[Mod_id].Nb_rb[UE_index]++;
//msg("[OPENAIR][RRC] CALLING RLC CONFIG RADIO BEARER %d\n",Idx); //msg("[OPENAIR][RRC] CALLING RLC CONFIG RADIO BEARER %d\n",Idx);
Mac_rlc_xface->rrc_rlc_config_req(Mod_id,ACTION_ADD,Idx,SIGNALLING_RADIO_BEARER,Rlc_info_um); Mac_rlc_xface->rrc_rlc_config_req(Mod_id,CONFIG_ACTION_ADD,Idx,SIGNALLING_RADIO_BEARER,Rlc_info_um);
/* /*
CH_rrc_inst[Mod_id].Srb2[UE_index].Srb_info.CH_ip_addr_type=p->L3_info_t; CH_rrc_inst[Mod_id].Srb2[UE_index].Srb_info.CH_ip_addr_type=p->L3_info_t;
if(p->L3_info_t == IPv4_ADDR){ if(p->L3_info_t == IPv4_ADDR){
...@@ -287,7 +287,7 @@ void rrc_config_req(Instance_t Mod_id, void *smsg, unsigned char Action,Transact ...@@ -287,7 +287,7 @@ void rrc_config_req(Instance_t Mod_id, void *smsg, unsigned char Action,Transact
if(p->Lchan_desc.Lchan_t==DTCH){ if(p->Lchan_desc.Lchan_t==DTCH){
CH_rrc_inst[Mod_id].Rab[In_idx][UE_index].Status = RADIO_CONFIG_OK;//RADIO CFG CH_rrc_inst[Mod_id].Rab[In_idx][UE_index].Status = RADIO_CONFIG_OK;//RADIO CFG
Mac_rlc_xface->rrc_rlc_config_req(Mod_id,ACTION_ADD,Idx,RADIO_ACCESS_BEARER,Rlc_info_um); Mac_rlc_xface->rrc_rlc_config_req(Mod_id,CONFIG_ACTION_ADD,Idx,RADIO_ACCESS_BEARER,Rlc_info_um);
CH_rrc_inst[Mod_id].IP_addr_type = p->L3_info_t; CH_rrc_inst[Mod_id].IP_addr_type = p->L3_info_t;
if(CH_rrc_inst[Mod_id].IP_addr_type == IPv4_ADDR) if(CH_rrc_inst[Mod_id].IP_addr_type == IPv4_ADDR)
memcpy(CH_rrc_inst[Mod_id].IP_addr,p->L3_info,4); memcpy(CH_rrc_inst[Mod_id].IP_addr,p->L3_info,4);
...@@ -295,7 +295,7 @@ void rrc_config_req(Instance_t Mod_id, void *smsg, unsigned char Action,Transact ...@@ -295,7 +295,7 @@ void rrc_config_req(Instance_t Mod_id, void *smsg, unsigned char Action,Transact
memcpy(CH_rrc_inst[Mod_id].IP_addr,p->L3_info,16); memcpy(CH_rrc_inst[Mod_id].IP_addr,p->L3_info,16);
} }
else else
Mac_rlc_xface->rrc_rlc_config_req(Mod_id,ACTION_ADD,Idx,RADIO_ACCESS_BEARER,Rlc_info_am_config); Mac_rlc_xface->rrc_rlc_config_req(Mod_id,CONFIG_ACTION_ADD,Idx,RADIO_ACCESS_BEARER,Rlc_info_am_config);
} }
if(p->Lchan_desc.Lchan_t==DTCH) if(p->Lchan_desc.Lchan_t==DTCH)
send_msg(&S_rrc,msg_rrc_rb_establish_cfm(Mod_id,Idx,0,Trans_id)); send_msg(&S_rrc,msg_rrc_rb_establish_cfm(Mod_id,Idx,0,Trans_id));
......
...@@ -2019,8 +2019,8 @@ void rrc_eNB_generate_RRCConnectionReconfiguration_handover (module_id_t Mod_id, ...@@ -2019,8 +2019,8 @@ void rrc_eNB_generate_RRCConnectionReconfiguration_handover (module_id_t Mod_id,
LOG_I (RRC,"[eNB %d] CALLING RLC CONFIG SRB1 (rbid %d) for UE %d\n",Mod_id, Idx, UE_index); LOG_I (RRC,"[eNB %d] CALLING RLC CONFIG SRB1 (rbid %d) for UE %d\n",Mod_id, Idx, UE_index);
// rrc_pdcp_config_req (Mod_id, frameP, 1, ACTION_ADD, idx, UNDEF_SECURITY_MODE); // rrc_pdcp_config_req (Mod_id, frameP, 1, CONFIG_ACTION_ADD, idx, UNDEF_SECURITY_MODE);
// rrc_rlc_config_req(Mod_id,frameP,1,ACTION_ADD,Idx,SIGNALLING_RADIO_BEARER,Rlc_info_am_config); // rrc_rlc_config_req(Mod_id,frameP,1,CONFIG_ACTION_ADD,Idx,SIGNALLING_RADIO_BEARER,Rlc_info_am_config);
rrc_pdcp_config_asn1_req (Mod_id, UE_index, frameP, 1, rrc_pdcp_config_asn1_req (Mod_id, UE_index, frameP, 1,
eNB_rrc_inst[Mod_id].SRB_configList[UE_index], eNB_rrc_inst[Mod_id].SRB_configList[UE_index],
...@@ -2253,9 +2253,9 @@ void rrc_eNB_process_RRCConnectionReconfigurationComplete (module_id_t Mod_id, f ...@@ -2253,9 +2253,9 @@ void rrc_eNB_process_RRCConnectionReconfigurationComplete (module_id_t Mod_id, f
if (eNB_rrc_inst[Mod_id].DRB_active[UE_index][i] == 0) if (eNB_rrc_inst[Mod_id].DRB_active[UE_index][i] == 0)
{ {
/* /*
rrc_pdcp_config_req (Mod_id, frameP, 1, ACTION_ADD, rrc_pdcp_config_req (Mod_id, frameP, 1, CONFIG_ACTION_ADD,
(UE_index * NB_RB_MAX) + *DRB_configList->list.array[i]->logicalChannelIdentity,UNDEF_SECURITY_MODE); (UE_index * NB_RB_MAX) + *DRB_configList->list.array[i]->logicalChannelIdentity,UNDEF_SECURITY_MODE);
rrc_rlc_config_req(Mod_id,frameP,1,ACTION_ADD, rrc_rlc_config_req(Mod_id,frameP,1,CONFIG_ACTION_ADD,
(UE_index * NB_RB_MAX) + (int)*eNB_rrc_inst[Mod_id].DRB_config[UE_index][i]->logicalChannelIdentity, (UE_index * NB_RB_MAX) + (int)*eNB_rrc_inst[Mod_id].DRB_config[UE_index][i]->logicalChannelIdentity,
RADIO_ACCESS_BEARER,Rlc_info_um); RADIO_ACCESS_BEARER,Rlc_info_um);
*/ */
...@@ -2348,10 +2348,10 @@ void rrc_eNB_process_RRCConnectionReconfigurationComplete (module_id_t Mod_id, f ...@@ -2348,10 +2348,10 @@ void rrc_eNB_process_RRCConnectionReconfigurationComplete (module_id_t Mod_id, f
if (eNB_rrc_inst[Mod_id].DRB_active[UE_index][i] == 1) if (eNB_rrc_inst[Mod_id].DRB_active[UE_index][i] == 1)
{ {
// DRB has just been removed so remove RLC + PDCP for DRB // DRB has just been removed so remove RLC + PDCP for DRB
/* rrc_pdcp_config_req (Mod_id, frameP, 1, ACTION_REMOVE, /* rrc_pdcp_config_req (Mod_id, frameP, 1, CONFIG_ACTION_REMOVE,
(UE_index * NB_RB_MAX) + DRB2LCHAN[i],UNDEF_SECURITY_MODE); (UE_index * NB_RB_MAX) + DRB2LCHAN[i],UNDEF_SECURITY_MODE);
*/ */
rrc_rlc_config_req (Mod_id, UE_index, frameP, 1, ACTION_REMOVE, rrc_rlc_config_req (Mod_id, UE_index, frameP, 1, CONFIG_ACTION_REMOVE,
DRB2LCHAN[i], DRB2LCHAN[i],
RADIO_ACCESS_BEARER, RADIO_ACCESS_BEARER,
Rlc_info_um); Rlc_info_um);
...@@ -2745,9 +2745,9 @@ for (i = 0; i < 8; i++) ...@@ -2745,9 +2745,9 @@ for (i = 0; i < 8; i++)
//LOG_D(RRC,"[eNB %d] RLC AM allocation index@1 is %d\n",Mod_id,rlc[Mod_id].m_rlc_am_array[1].allocation); //LOG_D(RRC,"[eNB %d] RLC AM allocation index@1 is %d\n",Mod_id,rlc[Mod_id].m_rlc_am_array[1].allocation);
LOG_I (RRC,"[eNB %d] CALLING RLC CONFIG SRB1 (rbid %d) for UE %d\n",Mod_id, Idx, UE_index); LOG_I (RRC,"[eNB %d] CALLING RLC CONFIG SRB1 (rbid %d) for UE %d\n",Mod_id, Idx, UE_index);
// rrc_pdcp_config_req (Mod_id, frameP, 1, ACTION_ADD, idx, UNDEF_SECURITY_MODE); // rrc_pdcp_config_req (Mod_id, frameP, 1, CONFIG_ACTION_ADD, idx, UNDEF_SECURITY_MODE);
// rrc_rlc_config_req(Mod_id,frameP,1,ACTION_ADD,Idx,SIGNALLING_RADIO_BEARER,Rlc_info_am_config); // rrc_rlc_config_req(Mod_id,frameP,1,CONFIG_ACTION_ADD,Idx,SIGNALLING_RADIO_BEARER,Rlc_info_am_config);
rrc_pdcp_config_asn1_req (Mod_id, UE_index, frameP, 1, rrc_pdcp_config_asn1_req (Mod_id, UE_index, frameP, 1,
eNB_rrc_inst[Mod_id]. eNB_rrc_inst[Mod_id].
...@@ -2779,7 +2779,7 @@ for (i = 0; i < 8; i++) ...@@ -2779,7 +2779,7 @@ for (i = 0; i < 8; i++)
LOG_D(RRC,"[eNB %d] CALLING RLC CONFIG SRB2 (rbid %d) for UE %d\n", LOG_D(RRC,"[eNB %d] CALLING RLC CONFIG SRB2 (rbid %d) for UE %d\n",
Mod_id,Idx+1,UE_index); Mod_id,Idx+1,UE_index);
Mac_rlc_xface->rrc_rlc_config_req(Mod_id,ACTION_ADD,Idx+1,SIGNALLING_RADIO_BEARER,Rlc_info_am_config); Mac_rlc_xface->rrc_rlc_config_req(Mod_id,CONFIG_ACTION_ADD,Idx+1,SIGNALLING_RADIO_BEARER,Rlc_info_am_config);
LOG_D(RRC,"[eNB %d] RLC AM allocation index@0 is %d\n",Mod_id,rlc[Mod_id].m_rlc_am_array[0].allocation); LOG_D(RRC,"[eNB %d] RLC AM allocation index@0 is %d\n",Mod_id,rlc[Mod_id].m_rlc_am_array[0].allocation);
LOG_D(RRC,"[eNB %d] RLC AM allocation index@1 is %d\n",rlc[Mod_id].m_rlc_am_array[1].allocation); LOG_D(RRC,"[eNB %d] RLC AM allocation index@1 is %d\n",rlc[Mod_id].m_rlc_am_array[1].allocation);
*/ */
...@@ -2989,7 +2989,7 @@ int rrc_eNB_decode_dcch (module_id_t Mod_id, frame_t frameP, uint8_t Srb_id, uin ...@@ -2989,7 +2989,7 @@ int rrc_eNB_decode_dcch (module_id_t Mod_id, frame_t frameP, uint8_t Srb_id, uin
xer_fprint (stdout, &asn_DEF_UL_DCCH_Message, (void *) ul_dcch_msg); xer_fprint (stdout, &asn_DEF_UL_DCCH_Message, (void *) ul_dcch_msg);
#endif #endif
// confirm with PDCP about the security mode for DCCH // confirm with PDCP about the security mode for DCCH
//rrc_pdcp_config_req (Mod_id, frameP, 1,ACTION_SET_SECURITY_MODE, (UE_index * NB_RB_MAX) + DCCH, 0x77); //rrc_pdcp_config_req (Mod_id, frameP, 1,CONFIG_ACTION_SET_SECURITY_MODE, (UE_index * NB_RB_MAX) + DCCH, 0x77);
// continue the procedure // continue the procedure
rrc_eNB_generate_UECapabilityEnquiry (Mod_id, frameP, UE_index); rrc_eNB_generate_UECapabilityEnquiry (Mod_id, frameP, UE_index);
break; break;
......
...@@ -1081,19 +1081,19 @@ void update_otg_eNB(module_id_t enb_module_idP, unsigned int ctime) { ...@@ -1081,19 +1081,19 @@ void update_otg_eNB(module_id_t enb_module_idP, unsigned int ctime) {
// if (frame >= 50) {// only generate when UE can receive MTCH (need to control this value) // if (frame >= 50) {// only generate when UE can receive MTCH (need to control this value)
for (service_id = 0; service_id < 2 ; service_id++) { //maxServiceCount for (service_id = 0; service_id < 2 ; service_id++) { //maxServiceCount
for (session_id = 0; session_id < 2; session_id++) { // maxSessionPerPMCH for (session_id = 0; session_id < 2; session_id++) { // maxSessionPerPMCH
if (pdcp_mbms_array_eNB[enb_module_idP][service_id][session_id].instanciated_instance == enb_module_idP + 1){ // this service/session is configured if (pdcp_mbms_array_eNB[enb_module_idP][service_id][session_id].instanciated_instance == TRUE){ // this service/session is configured
otg_pkt = malloc (sizeof(Packet_otg_elt_t)); otg_pkt = malloc (sizeof(Packet_otg_elt_t));
// LOG_T(OTG,"multicast packet gen for (service/mch %d, session/lcid %d, rb_id %d)\n", service_id, session_id, service_id*maxSessionPerPMCH + session_id); // LOG_T(OTG,"multicast packet gen for (service/mch %d, session/lcid %d, rb_id %d)\n", service_id, session_id, service_id*maxSessionPerPMCH + session_id);
rb_id = pdcp_mbms_array_eNB[enb_module_idP][service_id][session_id].rb_id; rb_id = pdcp_mbms_array_eNB[enb_module_idP][service_id][session_id].rb_id;
(otg_pkt->otg_pkt).sdu_buffer = (uint8_t*) packet_gen_multicast(enb_module_idP, session_id, ctime, &((otg_pkt->otg_pkt).sdu_buffer_size)); (otg_pkt->otg_pkt).sdu_buffer = (uint8_t*) packet_gen_multicast(enb_module_idP, session_id, ctime, &((otg_pkt->otg_pkt).sdu_buffer_size));
if ((otg_pkt->otg_pkt).sdu_buffer != NULL) { if ((otg_pkt->otg_pkt).sdu_buffer != NULL) {
(otg_pkt->otg_pkt).rb_id = rb_id; (otg_pkt->otg_pkt).rb_id = rb_id;
(otg_pkt->otg_pkt).module_id = enb_module_idP; (otg_pkt->otg_pkt).module_id = enb_module_idP;
(otg_pkt->otg_pkt).dst_id = session_id; (otg_pkt->otg_pkt).dst_id = session_id;
(otg_pkt->otg_pkt).is_ue = 0; (otg_pkt->otg_pkt).is_ue = FALSE;
//Adding the packet to the OTG-PDCP buffer //Adding the packet to the OTG-PDCP buffer
(otg_pkt->otg_pkt).mode = PDCP_TRANSMISSION_MODE_TRANSPARENT; (otg_pkt->otg_pkt).mode = PDCP_TRANSMISSION_MODE_TRANSPARENT;
pkt_list_add_tail_eurecom(otg_pkt, &(otg_pdcp_buffer[enb_module_idP])); pkt_list_add_tail_eurecom(otg_pkt, &(otg_pdcp_buffer[enb_module_idP]));
LOG_I(EMU, "[eNB %d] ADD packet (%p) multicast to OTG buffer for dst %d on rb_id %d\n", LOG_I(EMU, "[eNB %d] ADD packet (%p) multicast to OTG buffer for dst %d on rb_id %d\n",
(otg_pkt->otg_pkt).module_id, otg_pkt, (otg_pkt->otg_pkt).dst_id,(otg_pkt->otg_pkt).rb_id); (otg_pkt->otg_pkt).module_id, otg_pkt, (otg_pkt->otg_pkt).dst_id,(otg_pkt->otg_pkt).rb_id);
...@@ -1146,10 +1146,10 @@ void update_otg_eNB(module_id_t enb_module_idP, unsigned int ctime) { ...@@ -1146,10 +1146,10 @@ void update_otg_eNB(module_id_t enb_module_idP, unsigned int ctime) {
(otg_pkt->otg_pkt).sdu_buffer = packet_gen(module_instP, dst_id, ctime, &pkt_size); (otg_pkt->otg_pkt).sdu_buffer = packet_gen(module_instP, dst_id, ctime, &pkt_size);
if (otg_pkt != NULL) { if (otg_pkt != NULL) {
rb_id = dst_id * NB_RB_MAX + DTCH; rb_id = dst_id * NB_RB_MAX + DTCH;
(otg_pkt->otg_pkt).rb_id = rb_id; (otg_pkt->otg_pkt).rb_id = rb_id;
(otg_pkt->otg_pkt).module_id = module_idP; (otg_pkt->otg_pkt).module_id = module_idP;
(otg_pkt->otg_pkt).is_ue = 0; (otg_pkt->otg_pkt).is_ue = FALSE;
(otg_pkt->otg_pkt).mode = PDCP_TRANSMISSION_MODE_DATA; (otg_pkt->otg_pkt).mode = PDCP_TRANSMISSION_MODE_DATA;
//Adding the packet to the OTG-PDCP buffer //Adding the packet to the OTG-PDCP buffer
pkt_list_add_tail_eurecom(otg_pkt, &(otg_pdcp_buffer[module_idP])); pkt_list_add_tail_eurecom(otg_pkt, &(otg_pdcp_buffer[module_idP]));
LOG_I(EMU, "[eNB %d] ADD pkt to OTG buffer for dst %d on rb_id %d\n", (otg_pkt->otg_pkt).module_id, (otg_pkt->otg_pkt).dst_id,(otg_pkt->otg_pkt).rb_id); LOG_I(EMU, "[eNB %d] ADD pkt to OTG buffer for dst %d on rb_id %d\n", (otg_pkt->otg_pkt).module_id, (otg_pkt->otg_pkt).dst_id,(otg_pkt->otg_pkt).rb_id);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment