Commit f79b0e7d authored by gauthier's avatar gauthier

added hotfix for DCCH bad size limitation (to be checked after merge with...

added hotfix for DCCH bad size limitation (to be checked after merge with develop).  Changed UL idle scheduling to improve 5MHz performance, changed DCI aggregation for ue-specific DCIs (reduces contention with SI and RA in subframe 5 for 5 MHz). Added RRC timer for UE release which cleans L1.  Still issues in 10 MHz throughput with TCP. 5 MHz seems almost fine.
parent 26f5d0d9
......@@ -2980,8 +2980,9 @@ void prach_procedures(PHY_VARS_eNB *phy_vars_eNB,uint8_t sched_subframe,uint8_t
mac_xface->macphy_exit("Exiting for PRACH debug\n");
*/
UE_id = find_next_ue_index(phy_vars_eNB);
UE_id = find_next_ue_index(phy_vars_eNB);
if (UE_id>=0) {
phy_vars_eNB->eNB_UE_stats[(uint32_t)UE_id].UE_timing_offset = preamble_delay_list[preamble_max]&0x1FFF; //limit to 13 (=11+2) bits
//phy_vars_eNb->eNB_UE_stats[(uint32_t)UE_id].mode = PRACH;
......
......@@ -145,7 +145,7 @@ void eNB_dlsch_ulsch_scheduler(module_id_t module_idP,uint8_t cooperation_flag,
UE_list->UE_sched_ctrl[i].ra_pdcch_order_sent=1;
// add a format 1A dci for this UE to request an RA procedure (only one UE per subframe)
LOG_I(MAC,"UE %d rnti %x: sending PDCCH order for RAPROC (failure timer %d) \n",i,rnti,UE_list->UE_sched_ctrl[i].ul_failure_timer);
LOG_D(MAC,"UE %d rnti %x: sending PDCCH order for RAPROC (failure timer %d) \n",i,rnti,UE_list->UE_sched_ctrl[i].ul_failure_timer);
DLSCH_dci = (void *)UE_list->UE_template[CC_id][i].DLSCH_DCI[0];
*(uint32_t*)DLSCH_dci = 0;
if (PHY_vars_eNB_g[module_idP][CC_id]->lte_frame_parms.frame_type == TDD) {
......@@ -224,7 +224,7 @@ void eNB_dlsch_ulsch_scheduler(module_id_t module_idP,uint8_t cooperation_flag,
// check threshold
if (UE_list->UE_sched_ctrl[i].ul_failure_timer > 200) {
// inform RRC of failure and clear timer
LOG_I(MAC,"UE %d rnti %x: UL Failure Triggering RRC \n",i,rnti,UE_list->UE_sched_ctrl[i].ul_failure_timer);
LOG_I(MAC,"UE %d rnti %x: UL Failure after repeated PDCCH orders: Triggering RRC \n",i,rnti,UE_list->UE_sched_ctrl[i].ul_failure_timer);
mac_eNB_rrc_ul_failure(module_idP,CC_id,frameP,subframeP,rnti);
UE_list->UE_sched_ctrl[i].ul_failure_timer=0;
UE_list->UE_sched_ctrl[i].ul_out_of_sync=1;
......
......@@ -193,7 +193,7 @@ uint8_t find_active_UEs(module_id_t module_idP,int CC_id){
// get aggregatiob form phy for a give UE
unsigned char process_ue_cqi (module_id_t module_idP, int ue_idP)
{
unsigned char aggregation=2;
unsigned char aggregation=1;
// check the MCS and SNR and set the aggregation accordingly
return aggregation;
}
......@@ -707,7 +707,7 @@ uint8_t UE_is_to_be_scheduled(module_id_t module_idP,int CC_id,uint8_t UE_id)
(UE_template->bsr_info[LCGID2]>0) ||
(UE_template->bsr_info[LCGID3]>0) ||
(UE_template->ul_SR>0) || // uplink scheduling request
((UE_sched_ctl->ul_inactivity_timer>50)&&
((UE_sched_ctl->ul_inactivity_timer>20)&&
(UE_sched_ctl->ul_scheduled==0))|| // every 2 frames when RRC_CONNECTED
((UE_sched_ctl->ul_inactivity_timer>10)&&
(UE_sched_ctl->ul_scheduled==0)&&
......
......@@ -400,7 +400,6 @@ void rx_sdu(
UE_list->UE_template[CC_idP][UE_id].ul_buffer_info[UE_list->UE_template[CC_idP][UE_id].lcgidmap[rx_lcids[i]]] = 0;
// This check is just to make sure we didn't get a bogus SDU length, to be removed ...
if (rx_lengths[i]<CCCH_PAYLOAD_SIZE_MAX) {
LOG_D(MAC,"[eNB %d] CC_id %d Frame %d : ULSCH -> UL-DCCH, received %d bytes form UE %d on LCID %d \n",
enb_mod_idP,CC_idP,frameP, rx_lengths[i], UE_id, rx_lcids[i]);
......@@ -418,7 +417,6 @@ void rx_sdu(
NULL);//(unsigned int*)crc_status);
UE_list->eNB_UE_stats[CC_idP][UE_id].num_pdu_rx[rx_lcids[i]]+=1;
UE_list->eNB_UE_stats[CC_idP][UE_id].num_bytes_rx[rx_lcids[i]]+=rx_lengths[i];
}
} /* UE_id != -1 */
// }
......
......@@ -358,6 +358,7 @@ typedef struct eNB_RRC_UE_s {
rb_id_t enb_gtp_ebi[S1AP_MAX_E_RAB];
#endif
uint32_t ul_failure_timer;
uint32_t ue_release_timer;
} eNB_RRC_UE_t;
typedef uid_t ue_uid_t;
......
......@@ -531,6 +531,15 @@ rrc_rx_tx(
break;
}
}
if (ue_context_p->ue_context.ue_release_timer>0) {
ue_context_p->ue_context.ue_release_timer++;
if (ue_context_p->ue_context.ue_release_timer >= 100) {
// remove UE after 10 frames after RRCConnectionRelease is triggered
LOG_I(RRC,"Removing UE %x instance\n",ue_context_p->ue_context.rnti);
ue_to_be_removed = ue_context_p;
break;
}
}
}
if (ue_to_be_removed)
rrc_eNB_free_UE(ctxt_pP->module_id,ue_to_be_removed);
......
......@@ -1090,6 +1090,8 @@ rrc_eNB_generate_RRCConnectionRelease(
memset(buffer, 0, RRC_BUF_SIZE);
size = do_RRCConnectionRelease(ctxt_pP->module_id, buffer,rrc_eNB_get_next_transaction_identifier(ctxt_pP->module_id));
// set release timer
ue_context_pP->ue_context.ue_release_timer=1;
LOG_I(RRC,
PROTOCOL_RRC_CTXT_UE_FMT" Logical Channel DL-DCCH, Generate RRCConnectionRelease (bytes %d)\n",
......
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