rrc-nr: temporary fix to handle inactivity timeout

Fixes issue #3689

Signed-off-by: Carlo Galiotto <carlo@srs.io>
This commit is contained in:
Carlo Galiotto 2021-11-25 15:50:51 +01:00 committed by Francisco Paisana
parent 68ec3eaba0
commit f9ff6758aa
3 changed files with 16 additions and 2 deletions

View File

@ -73,6 +73,7 @@ public:
void rem_user(uint16_t rnti);
int update_user(uint16_t new_rnti, uint16_t old_rnti) final;
void set_activity_user(uint16_t rnti) final;
int rrc_release(uint16_t rnti);
// RLC interface
// TODO

View File

@ -203,6 +203,13 @@ void rrc_nr::rem_user(uint16_t rnti)
}
}
/// This function is called when the INACTIVITY TIMER FOR
int rrc_nr::rrc_release(uint16_t rnti)
{
// TODO: we do not have yet a defined procedure to handle this
return SRSRAN_SUCCESS;
}
/* Function called by MAC after the reception of a C-RNTI CE indicating that the UE still has a
* valid RNTI.
*/

View File

@ -92,10 +92,16 @@ void rrc_nr::ue::activity_timer_expired(const activity_timeout_type_t type)
switch (type) {
case MSG5_RX_TIMEOUT:
case UE_INACTIVITY_TIMEOUT:
case UE_INACTIVITY_TIMEOUT: {
state = rrc_nr_state_t::RRC_INACTIVE;
parent->rrc_eutra->sgnb_inactivity_timeout(eutra_rnti);
if (parent->cfg.is_standalone) {
// TODO: This procedure needs to be defined
parent->rrc_release(rnti);
} else {
parent->rrc_eutra->sgnb_inactivity_timeout(eutra_rnti);
}
break;
}
case MSG3_RX_TIMEOUT: {
// MSG3 timeout, no need to notify NGAP or LTE stack. Just remove UE
state = rrc_nr_state_t::RRC_IDLE;