Merge remote-tracking branch 'Rakesh_B_B/fix-ngap-time-in-cell' into integration_2026_w02 (!3838)
NR NGAP (N2HO) : Fix Time UE Stayed in Cell IE type and calculation According to 3GPP TS 38.413, the 'Time UE Stayed in Cell' IE is an integer ranging from 0 to 4095. This patch updates the data structure to reflect the correct bit width and implements the dynamic calculation based on the UE's residence time. - Change time_in_cell from long to uint16_t in ngap_messages_types.h. - Replace dummy value with real-time calculation in rrc_gNB_NGAP.c. - Implement a ceiling of 4095 to comply with the 12-bit protocol limit. Ref: 3GPP TS 38.413 Section 9.3.1.97
This commit is contained in:
@@ -473,8 +473,8 @@ typedef struct {
|
||||
cell_id_t id;
|
||||
// Cell type
|
||||
uint8_t type;
|
||||
// Time UE Stayed in Cell
|
||||
long time_in_cell;
|
||||
// Time UE Stayed in Cell (seconds)
|
||||
uint16_t time_in_cell;
|
||||
// Cause
|
||||
ngap_cause_t *cause;
|
||||
} last_visited_ngran_cell_info_t;
|
||||
|
||||
@@ -1649,7 +1649,7 @@ void rrc_gNB_send_NGAP_HANDOVER_REQUIRED(gNB_RRC_INST *rrc,
|
||||
msg.source2target->ue_history_info.cause->type = NGAP_CAUSE_RADIO_NETWORK;
|
||||
msg.source2target->ue_history_info.cause->value = NGAP_CAUSE_RADIO_NETWORK_HANDOVER_DESIRABLE_FOR_RADIO_REASON;
|
||||
msg.source2target->ue_history_info.type = NGAP_CellSize_small;
|
||||
msg.source2target->ue_history_info.time_in_cell = 500; // dummy number for now
|
||||
msg.source2target->ue_history_info.time_in_cell = min(time(NULL) - UE->last_seen, 4095);
|
||||
msg.source2target->ue_history_info.id = target_cell;
|
||||
|
||||
/* Fill both PDU Session Resource List IE (M) in Handover Required
|
||||
|
||||
Reference in New Issue
Block a user