Commit 8513035a authored by wujing's avatar wujing

fix attach fail if there are 8UEs when TDD config1

parent b5957763
...@@ -336,7 +336,7 @@ rx_sdu(const module_id_t enb_mod_idP, ...@@ -336,7 +336,7 @@ rx_sdu(const module_id_t enb_mod_idP,
ra = &mac->common_channels[CC_idP].ra[ii]; ra = &mac->common_channels[CC_idP].ra[ii];
if ((ra->rnti == current_rnti) && (ra->state != IDLE)) { if ((ra->rnti == current_rnti) && (ra->state != IDLE)) {
mac_rrc_data_ind(enb_mod_idP, int8_t ret = mac_rrc_data_ind(enb_mod_idP,
CC_idP, CC_idP,
frameP, subframeP, frameP, subframeP,
old_rnti, old_rnti,
...@@ -344,6 +344,7 @@ rx_sdu(const module_id_t enb_mod_idP, ...@@ -344,6 +344,7 @@ rx_sdu(const module_id_t enb_mod_idP,
(uint8_t *) payload_ptr, (uint8_t *) payload_ptr,
rx_lengths[i], rx_lengths[i],
0); 0);
if(ret == 0){
// prepare transmission of Msg4(RRCConnectionReconfiguration) // prepare transmission of Msg4(RRCConnectionReconfiguration)
ra->state = MSGCRNTI; ra->state = MSGCRNTI;
LOG_I(MAC, LOG_I(MAC,
...@@ -367,6 +368,9 @@ rx_sdu(const module_id_t enb_mod_idP, ...@@ -367,6 +368,9 @@ rx_sdu(const module_id_t enb_mod_idP,
UE_list->UE_template[CC_idP][UE_id].ul_SR = 1; UE_list->UE_template[CC_idP][UE_id].ul_SR = 1;
UE_list->UE_sched_ctrl[UE_id].crnti_reconfigurationcomplete_flag = 1; UE_list->UE_sched_ctrl[UE_id].crnti_reconfigurationcomplete_flag = 1;
}else{
cancel_ra_proc(enb_mod_idP, CC_idP, frameP,current_rnti);
}
break; break;
} }
} }
......
...@@ -261,12 +261,17 @@ mac_rrc_data_ind( ...@@ -261,12 +261,17 @@ mac_rrc_data_ind(
ue_context_p = rrc_eNB_get_ue_context(RC.rrc[ctxt.module_id],rntiP); ue_context_p = rrc_eNB_get_ue_context(RC.rrc[ctxt.module_id],rntiP);
if(ue_context_p) { if(ue_context_p) {
if( ue_context_p->ue_context.Status != RRC_RECONFIGURED){
LOG_E(RRC,"[eNB %d] Received C-RNTI ,but UE %x status(%d) not RRC_RECONFIGURED\n",module_idP,rntiP,ue_context_p->ue_context.Status);
return(-1);
}else{
rrc_eNB_generate_defaultRRCConnectionReconfiguration(&ctxt, rrc_eNB_generate_defaultRRCConnectionReconfiguration(&ctxt,
ue_context_p, ue_context_p,
0); 0);
ue_context_p->ue_context.Status = RRC_RECONFIGURED; ue_context_p->ue_context.Status = RRC_RECONFIGURED;
} }
} }
}
return(0); return(0);
} }
......
...@@ -5622,6 +5622,14 @@ rrc_eNB_decode_ccch( ...@@ -5622,6 +5622,14 @@ rrc_eNB_decode_ccch(
RC.mac[ctxt_pP->module_id]->UE_list.UE_sched_ctrl[UE_id].ue_reestablishment_reject_timer = 1000; RC.mac[ctxt_pP->module_id]->UE_list.UE_sched_ctrl[UE_id].ue_reestablishment_reject_timer = 1000;
ue_context_p->ue_context.ue_reestablishment_timer = 0; ue_context_p->ue_context.ue_reestablishment_timer = 0;
} }
//c-plane not end
if((ue_context_p->ue_context.Status != RRC_RECONFIGURED) && (ue_context_p->ue_context.reestablishment_cause == LTE_ReestablishmentCause_spare1)) {
LOG_E(RRC,
PROTOCOL_RRC_CTXT_UE_FMT" LTE_RRCConnectionReestablishmentRequest (UE %x c-plane is not end), let's reject the UE\n",
PROTOCOL_RRC_CTXT_UE_ARGS(ctxt_pP),c_rnti);
rrc_eNB_generate_RRCConnectionReestablishmentReject(ctxt_pP, ue_context_p, CC_id);
break;
}
if(ue_context_p->ue_context.ue_reestablishment_timer > 0) { if(ue_context_p->ue_context.ue_reestablishment_timer > 0) {
LOG_E(RRC, LOG_E(RRC,
...@@ -6368,7 +6376,7 @@ rrc_eNB_decode_dcch( ...@@ -6368,7 +6376,7 @@ rrc_eNB_decode_dcch(
// activate release timer, if RRCReconfComplete not received after 100 frames, remove UE // activate release timer, if RRCReconfComplete not received after 100 frames, remove UE
ue_context_p->ue_context.ue_reestablishment_timer = 1; ue_context_p->ue_context.ue_reestablishment_timer = 1;
// remove UE after 100 frames after LTE_RRCConnectionRelease is triggered // remove UE after 100 frames after LTE_RRCConnectionRelease is triggered
ue_context_p->ue_context.ue_reestablishment_timer_thres = 1000; ue_context_p->ue_context.ue_reestablishment_timer_thres = 10000;
break; break;
case LTE_UL_DCCH_MessageType__c1_PR_securityModeComplete: case LTE_UL_DCCH_MessageType__c1_PR_securityModeComplete:
......
...@@ -2270,7 +2270,7 @@ void init_RU_proc(RU_t *ru) { ...@@ -2270,7 +2270,7 @@ void init_RU_proc(RU_t *ru) {
pthread_setname_np( proc->pthread_FH, name ); pthread_setname_np( proc->pthread_FH, name );
} }
else if (ru->function == eNodeB_3GPP && ru->if_south == LOCAL_RF) { // DJP - need something else to distinguish between monolithic and PNF else if (ru->function == eNodeB_3GPP && ru->if_south == LOCAL_RF && (ru->do_prach > 0)) { // DJP - need something else to distinguish between monolithic and PNF
LOG_I(PHY,"%s() DJP - added creation of pthread_prach\n", __FUNCTION__); LOG_I(PHY,"%s() DJP - added creation of pthread_prach\n", __FUNCTION__);
pthread_create( &proc->pthread_prach, attr_prach, ru_thread_prach, (void*)ru ); pthread_create( &proc->pthread_prach, attr_prach, ru_thread_prach, (void*)ru );
} }
......
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