Merge remote-tracking branch 'origin/develop' into bugfix-48-L1L2signaling

Conflicts:
	openair1/PHY/LTE_ESTIMATION/lte_eNB_measurements.c
	openair1/PHY/LTE_TRANSPORT/dlsch_coding.c
	openair1/SCHED/phy_procedures_lte_eNb.c
	openair2/LAYER2/MAC/config.c
	openair2/LAYER2/MAC/pre_processor.c
	openair2/LAYER2/openair2_proc.c
	openair2/RRC/LITE/rrc_eNB.c
	openair3/NAS/UE/API/USIM/usim_api.c
	openair3/NAS/UE/ESM/esm_ebr_context.c
This commit is contained in:
Raymond Knopp
2016-03-31 14:36:12 -07:00
113 changed files with 745 additions and 298 deletions
+6 -2
View File
@@ -355,6 +355,10 @@ mac_rrc_data_ind(
SRB_INFO *Srb_info;
protocol_ctxt_t ctxt;
sdu_size_t sdu_size = 0;
/* for no gcc warnings */
(void)sdu_size;
/*
int si_window;
*/
@@ -389,7 +393,7 @@ mac_rrc_data_ind(
itti_send_msg_to_task (TASK_RRC_UE, ctxt.instance, message_p);
}
#else
decode_BCCH_DLSCH_Message(&ctxt,eNB_indexP,sduP,sdu_lenP, 0, 0);
decode_BCCH_DLSCH_Message(&ctxt,eNB_indexP,(uint8_t*)sduP,sdu_lenP, 0, 0);
#endif
}
@@ -634,7 +638,7 @@ rrc_data_ind(
buffer_pP,
sdu_sizeP);
} else {
#warning "LG put 0 to arg4 that is eNB index"
//#warning "LG put 0 to arg4 that is eNB index"
rrc_ue_decode_dcch(
ctxt_pP,
DCCH_index,
+18 -3
View File
@@ -141,7 +141,9 @@ static uint8_t check_trigger_meas_event(
Q_OffsetRange_t ofn, Q_OffsetRange_t ocn, Hysteresis_t hys,
Q_OffsetRange_t ofs, Q_OffsetRange_t ocs, long a3_offset, TimeToTrigger_t ttt);
#ifdef Rel10
static void decode_MBSFNAreaConfiguration(module_id_t module_idP, uint8_t eNB_index, frame_t frameP,uint8_t mbsfn_sync_area);
#endif
@@ -151,10 +153,13 @@ static void decode_MBSFNAreaConfiguration(module_id_t module_idP, uint8_t eNB_in
/*------------------------------------------------------------------------------*/
/* to avoid gcc warnings when compiling with certain options */
#if defined(ENABLE_USE_MME) || ENABLE_RAL
static Rrc_State_t rrc_get_state (module_id_t ue_mod_idP)
{
return UE_rrc_inst[ue_mod_idP].RrcState;
}
#endif
static Rrc_Sub_State_t rrc_get_sub_state (module_id_t ue_mod_idP)
{
@@ -261,6 +266,7 @@ static void init_SI_UE( const protocol_ctxt_t* const ctxt_pP, const uint8_t eNB_
#ifdef Rel10
//-----------------------------------------------------------------------------
#if 0
static void init_MCCH_UE(module_id_t ue_mod_idP, uint8_t eNB_index)
{
int i;
@@ -274,6 +280,7 @@ static void init_MCCH_UE(module_id_t ue_mod_idP, uint8_t eNB_index)
}
}
#endif
#endif
//-----------------------------------------------------------------------------
static void openair_rrc_ue_init_security( const protocol_ctxt_t* const ctxt_pP )
@@ -697,6 +704,10 @@ rrc_ue_establish_drb(
// add descriptor from RRC PDU
#ifdef PDCP_USE_NETLINK
int oip_ifup=0,ip_addr_offset3=0,ip_addr_offset4=0;
/* avoid gcc warnings */
(void)oip_ifup;
(void)ip_addr_offset3;
(void)ip_addr_offset4;
#endif
LOG_I(RRC,"[UE %d] Frame %d: processing RRCConnectionReconfiguration: reconfiguring DRB %ld/LCID %d\n",
@@ -1296,7 +1307,7 @@ rrc_ue_process_radioResourceConfigDedicated(
UE_rrc_inst[ctxt_pP->module_id].sib1[eNB_index]->cellAccessRelatedInfo.cellIdentity.buf[1],
UE_rrc_inst[ctxt_pP->module_id].sib1[eNB_index]->cellAccessRelatedInfo.cellIdentity.buf[2],
UE_rrc_inst[ctxt_pP->module_id].sib1[eNB_index]->cellAccessRelatedInfo.cellIdentity.buf[3]);
# endif OAI_EMU
# endif /* OAI_EMU */
#endif
}
@@ -2266,6 +2277,9 @@ static const char* SIB2preambleTransMax( long value )
case 10:
return "n200";
}
/* unreachable but gcc warns... */
return "ERR";
}
static const char* SIB2ra_ResponseWindowSize( long value )
{
@@ -3061,9 +3075,10 @@ uint64_t arfcn_to_freq(long arfcn) {
return((uint64_t)3400000000 + ((arfcn-41590)*100000));
else if (arfcn <45590) // Band 43
return((uint64_t)3600000000 + ((arfcn-43950)*100000));
else
else {
LOG_E(RRC,"Unknown EARFCN %d\n",arfcn);
exit(1);
}
}
static void dump_sib5( SystemInformationBlockType5_t *sib5 )
{
+7 -1
View File
@@ -254,6 +254,9 @@ openair_rrc_top_init(
OAI_UECapability_t *UECap = NULL;
int CC_id;
/* for no gcc warnings */
(void)CC_id;
LOG_D(RRC, "[OPENAIR][INIT] Init function start: NB_UE_INST=%d, NB_eNB_INST=%d\n", NB_UE_INST, NB_eNB_INST);
if (NB_UE_INST > 0) {
@@ -412,7 +415,7 @@ rrc_rx_tx(
)
//-----------------------------------------------------------------------------
{
uint8_t UE_id;
//uint8_t UE_id;
int32_t current_timestamp_ms, ref_timestamp_ms;
struct timeval ts;
struct rrc_eNB_ue_context_s *ue_context_p = NULL,*ue_to_be_removed = NULL;
@@ -573,6 +576,9 @@ rrc_rx_tx(
}
#endif
(void)ts; /* remove gcc warning "unused variable" */
(void)ref_timestamp_ms; /* remove gcc warning "unused variable" */
(void)current_timestamp_ms; /* remove gcc warning "unused variable" */
}
VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME(VCD_SIGNAL_DUMPER_FUNCTIONS_RRC_RX_TX,VCD_FUNCTION_OUT);
+24 -11
View File
@@ -800,6 +800,8 @@ rrc_eNB_free_UE(const module_id_t enb_mod_idP,const struct rrc_eNB_ue_context_s*
protocol_ctxt_t ctxt;
#if !defined(ENABLE_USE_MME)
module_id_t ue_module_id;
/* avoid gcc warnings */
(void)ue_module_id;
#endif
rnti_t rnti = ue_context_pP->ue_context.rnti;
@@ -1140,8 +1142,8 @@ rrc_eNB_generate_defaultRRCConnectionReconfiguration(
int i;
// configure SRB1/SRB2, PhysicalConfigDedicated, MAC_MainConfig for UE
eNB_RRC_INST* rrc_inst = &eNB_rrc_inst[ctxt_pP->module_id];
struct PhysicalConfigDedicated** physicalConfigDedicated = &ue_context_pP->ue_context.physicalConfigDedicated;
//eNB_RRC_INST* rrc_inst = &eNB_rrc_inst[ctxt_pP->module_id];
//struct PhysicalConfigDedicated** physicalConfigDedicated = &ue_context_pP->ue_context.physicalConfigDedicated;
struct SRB_ToAddMod *SRB2_config = NULL;
struct SRB_ToAddMod__rlc_Config *SRB2_rlc_config = NULL;
@@ -1172,7 +1174,7 @@ rrc_eNB_generate_defaultRRCConnectionReconfiguration(
#if Rel10
long *sr_ProhibitTimer_r9 = NULL;
// uint8_t sCellIndexToAdd = rrc_find_free_SCell_index(enb_mod_idP, ue_mod_idP, 1);
uint8_t sCellIndexToAdd = 0;
//uint8_t sCellIndexToAdd = 0;
#endif
long *logicalchannelgroup, *logicalchannelgroup_drb;
@@ -1185,6 +1187,8 @@ rrc_eNB_generate_defaultRRCConnectionReconfiguration(
CellsToAddModList_t *CellsToAddModList = NULL;
struct RRCConnectionReconfiguration_r8_IEs__dedicatedInfoNASList *dedicatedInfoNASList = NULL;
DedicatedInfoNAS_t *dedicatedInfoNas = NULL;
/* for no gcc warnings */
(void)dedicatedInfoNas;
C_RNTI_t *cba_RNTI = NULL;
#ifdef CBA
@@ -1297,6 +1301,10 @@ rrc_eNB_generate_defaultRRCConnectionReconfiguration(
DRB_pdcp_config->rlc_AM = NULL;
DRB_pdcp_config->rlc_UM = NULL;
/* avoid gcc warnings */
(void)PDCP_rlc_AM;
(void)PDCP_rlc_UM;
#ifdef RRC_DEFAULT_RAB_IS_AM // EXMIMO_IOT
PDCP_rlc_AM = CALLOC(1, sizeof(*PDCP_rlc_AM));
DRB_pdcp_config->rlc_AM = PDCP_rlc_AM;
@@ -2106,8 +2114,8 @@ rrc_eNB_generate_RRCConnectionReconfiguration_handover(
QuantityConfig_t *quantityConfig;
MobilityControlInfo_t *mobilityInfo;
// HandoverCommand_t handoverCommand;
uint8_t sourceModId =
get_adjacent_cell_mod_id(ue_context_pP->ue_context.handover_info->as_context.reestablishmentInfo->sourcePhysCellId);
//uint8_t sourceModId =
// get_adjacent_cell_mod_id(ue_context_pP->ue_context.handover_info->as_context.reestablishmentInfo->sourcePhysCellId);
#if Rel10
long *sr_ProhibitTimer_r9;
#endif
@@ -2954,7 +2962,7 @@ rrc_eNB_generate_RRCConnectionReconfiguration_handover(
handoverCommand.criticalExtensions.choice.c1.choice.handoverCommand_r8.handoverCommandMessage.buf = buffer;
handoverCommand.criticalExtensions.choice.c1.choice.handoverCommand_r8.handoverCommandMessage.size = size;
*/
#warning "COMPILATION PROBLEM"
//#warning "COMPILATION PROBLEM"
#ifdef PROBLEM_COMPILATION_RESOLVED
if (sourceModId != 0xFF) {
@@ -3012,6 +3020,10 @@ rrc_eNB_process_RRCConnectionReconfigurationComplete(
int oip_ifup = 0;
int dest_ip_offset = 0;
module_id_t ue_module_id = -1;
/* avoid gcc warnings */
(void)oip_ifup;
(void)dest_ip_offset;
(void)ue_module_id;
#endif
uint8_t *kRRCenc = NULL;
@@ -3019,7 +3031,7 @@ rrc_eNB_process_RRCConnectionReconfigurationComplete(
uint8_t *kUPenc = NULL;
DRB_ToAddModList_t* DRB_configList = ue_context_pP->ue_context.DRB_configList;
SRB_ToAddModList_t* SRB_configList = ue_context_pP->ue_context.SRB_configList;
//SRB_ToAddModList_t* SRB_configList = ue_context_pP->ue_context.SRB_configList;
#if defined(ENABLE_SECURITY)
@@ -3710,7 +3722,7 @@ rrc_eNB_decode_ccch(
* the current one must be removed from MAC/PHY (zombie UE)
*/
if ((ue_context_p = rrc_eNB_ue_context_random_exist(ctxt_pP, random_value))) {
#warning "TODO: random_exist: remove UE from MAC/PHY (how?)"
//#warning "TODO: random_exist: remove UE from MAC/PHY (how?)"
// AssertFatal(0 == 1, "TODO: remove UE from MAC/PHY (how?)");
ue_context_p = NULL;
} else {
@@ -3723,7 +3735,8 @@ rrc_eNB_decode_ccch(
m_tmsi_t m_tmsi = BIT_STRING_to_uint32(&s_TMSI.m_TMSI);
random_value = (((uint64_t)mme_code) << 32) | m_tmsi;
if ((ue_context_p = rrc_eNB_ue_context_stmsi_exist(ctxt_pP, mme_code, m_tmsi))) {
#warning "TODO: stmsi_exist: remove UE from MAC/PHY (how?)"
//#warning "TODO: stmsi_exist: remove UE from MAC/PHY (how?)"
LOG_I(RRC," S-TMSI exists, ue_context_p %p\n",ue_context_p);
stmsi_received=1;
ue_context_p->ue_context.rnti = ctxt_pP->rnti;
@@ -4196,7 +4209,7 @@ rrc_eNB_decode_dcch(
// cancel the security mode in PDCP
// followup with the remaining procedure
#warning "LG Removed rrc_eNB_generate_UECapabilityEnquiry after receiving securityModeFailure"
//#warning "LG Removed rrc_eNB_generate_UECapabilityEnquiry after receiving securityModeFailure"
rrc_eNB_generate_UECapabilityEnquiry(ctxt_pP, ue_context_p);
break;
@@ -4464,7 +4477,7 @@ rrc_enb_task(
//SPECTRA: Add the RRC connection reconfiguration with Second cell configuration
case RRC_RAL_CONNECTION_RECONFIGURATION_REQ:
// ue_mod_id = 0; /* TODO force ue_mod_id to first UE, NAS UE not virtualized yet */
#warning "TODO GET RIGHT RNTI"
//#warning "TODO GET RIGHT RNTI"
PROTOCOL_CTXT_SET_BY_INSTANCE(&ctxt,
instance,
ENB_FLAG_YES,
+1
View File
@@ -86,6 +86,7 @@ rrc_eNB_process_GTPV1U_CREATE_TUNNEL_RESP(
create_tunnel_resp_pP->num_tunnels,
ue_context_p->ue_context.enb_gtp_ebi[0],
ue_context_p->ue_context.enb_gtp_teid[0]);
(void)rnti; /* avoid gcc warning "set but not used" */
return 0;
} else {
return -1;
+8 -4
View File
@@ -60,6 +60,9 @@
#endif
#include "msc.h"
#include "gtpv1u_eNB_task.h"
#include "RRC/LITE/rrc_eNB_GTPV1U.h"
/* Value to indicate an invalid UE initial id */
static const uint16_t UE_INITIAL_ID_INVALID = 0;
@@ -233,7 +236,7 @@ rrc_eNB_get_ue_context_from_s1ap_ids(
static e_SecurityAlgorithmConfig__cipheringAlgorithm rrc_eNB_select_ciphering(uint16_t algorithms)
{
#warning "Forced return SecurityAlgorithmConfig__cipheringAlgorithm_eea0, to be deleted in future"
//#warning "Forced return SecurityAlgorithmConfig__cipheringAlgorithm_eea0, to be deleted in future"
return SecurityAlgorithmConfig__cipheringAlgorithm_eea0;
if (algorithms & S1AP_ENCRYPTION_EEA2_MASK) {
@@ -392,6 +395,7 @@ rrc_pdcp_config_security(
#define DEBUG_SECURITY 1
#if defined (DEBUG_SECURITY)
#undef msg
#define msg printf
if (print_keys ==1 ) {
@@ -671,7 +675,7 @@ rrc_eNB_send_S1AP_NAS_FIRST_REQ(
if (rrcConnectionSetupComplete->registeredMME != NULL) {
/* Fill GUMMEI */
struct RegisteredMME *r_mme = rrcConnectionSetupComplete->registeredMME;
int selected_plmn_identity = rrcConnectionSetupComplete->selectedPLMN_Identity;
//int selected_plmn_identity = rrcConnectionSetupComplete->selectedPLMN_Identity;
S1AP_NAS_FIRST_REQ (message_p).ue_identity.presenceMask |= UE_IDENTITIES_gummei;
@@ -858,7 +862,7 @@ int rrc_eNB_process_S1AP_INITIAL_CONTEXT_SETUP_REQ(MessageDef *msg_p, const char
{
uint16_t ue_initial_id;
uint32_t eNB_ue_s1ap_id;
MessageDef *message_gtpv1u_p = NULL;
//MessageDef *message_gtpv1u_p = NULL;
gtpv1u_enb_create_tunnel_req_t create_tunnel_req;
gtpv1u_enb_create_tunnel_resp_t create_tunnel_resp;
@@ -1169,7 +1173,7 @@ int rrc_eNB_process_S1AP_UE_CONTEXT_RELEASE_COMMAND (MessageDef *msg_p, const ch
*/
{
int e_rab;
int mod_id = 0;
//int mod_id = 0;
MessageDef *msg_delete_tunnels_p = NULL;
MSC_LOG_TX_MESSAGE(
+2
View File
@@ -63,6 +63,8 @@ rrc_eNB_S1AP_compare_ue_ids(
struct rrc_ue_s1ap_ids_s* c2_pP
);
struct rrc_rnti_tree_s;
RB_PROTOTYPE(rrc_rnti_tree_s, rrc_ue_s1ap_ids_s, entries, rrc_eNB_S1AP_compare_ue_ids);
struct rrc_ue_s1ap_ids_s*
+10 -4
View File
@@ -88,18 +88,24 @@ struct LogicalChannelConfig__ul_SpecificParameters LCSRB2 = {3,
};
#ifdef Rel10
struct LogicalChannelConfig__ext1 logicalChannelSR_Mask_r9_ext1 = {
logicalChannelSR_Mask_r9: &logicalChannelSR_Mask_r9
};
#endif
// These are the default SRB configurations from 36.331 (Chapter 9, p. 176-179 in v8.6)
LogicalChannelConfig_t SRB1_logicalChannelConfig_defaultValue = {&LCSRB1
LogicalChannelConfig_t SRB1_logicalChannelConfig_defaultValue = {ul_SpecificParameters: &LCSRB1
#ifdef Rel10
,
&logicalChannelSR_Mask_r9
ext1: &logicalChannelSR_Mask_r9_ext1
#endif
};
LogicalChannelConfig_t SRB2_logicalChannelConfig_defaultValue = {&LCSRB2
LogicalChannelConfig_t SRB2_logicalChannelConfig_defaultValue = {ul_SpecificParameters: &LCSRB2
#ifdef Rel10
,
&logicalChannelSR_Mask_r9
ext1: &logicalChannelSR_Mask_r9_ext1
#endif
};