Skip to content

Commit 3159ea5

Browse files
FabianEckermanncodebot
authored andcommitted
cu_cp: remove rrc reconfiguration from initial context setup routine if no pdu sessions are setup
1 parent 06a05b5 commit 3159ea5

File tree

5 files changed

+7
-31
lines changed

5 files changed

+7
-31
lines changed

lib/cu_cp/routines/initial_context_setup_routine.cpp

Lines changed: 3 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -134,33 +134,10 @@ void initial_context_setup_routine::operator()(
134134
if (request.nas_pdu.has_value()) {
135135
handle_nas_pdu(request.nas_pdu.value().copy());
136136
}
137-
138137
} else {
139-
// prepare RRC Reconfiguration and call RRC UE notifier
140-
if (!fill_rrc_reconfig_args(rrc_reconfig_args,
141-
ue_context_setup_request.srbs_to_be_setup_list,
142-
{} /* No DRB to setup */,
143-
{} /* No extra DRB to be removed */,
144-
ue_context_setup_response.du_to_cu_rrc_info,
145-
request.nas_pdu.has_value() ? std::vector<byte_buffer>{request.nas_pdu.value().copy()}
146-
: std::vector<byte_buffer>{},
147-
rrc_ue.generate_meas_config(std::nullopt),
148-
false /* No SRBs to reestablish */,
149-
false /* No DRBs to reestablish */,
150-
false /* No keys to update */,
151-
{} /* No SIB1 */,
152-
logger)) {
153-
logger.warning("ue={}: \"{}\" Failed to fill RRCReconfiguration", request.ue_index, name());
154-
handle_failure();
155-
CORO_EARLY_RETURN(make_unexpected(fail_msg));
156-
}
157-
158-
CORO_AWAIT_VALUE(rrc_reconfig_result, rrc_ue.handle_rrc_reconfiguration_request(rrc_reconfig_args));
159-
// Handle RRC Reconfiguration result
160-
if (not rrc_reconfig_result) {
161-
logger.warning("ue={}: \"{}\" RRC Reconfiguration failed", request.ue_index, name());
162-
handle_failure();
163-
CORO_EARLY_RETURN(make_unexpected(fail_msg));
138+
// Handle NAS PDUs from Initial Context Setup Request
139+
if (request.nas_pdu.has_value()) {
140+
handle_nas_pdu(request.nas_pdu.value().copy());
164141
}
165142
}
166143

lib/cu_cp/routines/initial_context_setup_routine.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,6 @@ class initial_context_setup_routine
6060
bool ue_capability_transfer_result = false; // to query the UE capabilities
6161
cu_cp_pdu_session_resource_setup_response pdu_session_setup_response;
6262
bool security_mode_command_result = false;
63-
bool rrc_reconfig_result = false; // the final UE reconfiguration
6463
ngap_init_context_setup_failure fail_msg;
6564
ngap_init_context_setup_response resp_msg;
6665
};

lib/cu_cp/routines/mobility/inter_du_handover_routine.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,7 @@ void inter_du_handover_routine::operator()(coro_context<async_task<cu_cp_inter_d
133133

134134
// Inform CU-UP about new DL tunnels.
135135
{
136-
// get securtiy context of target UE
136+
// get security context of target UE
137137
if (!target_ue->get_security_manager().is_security_context_initialized()) {
138138
logger.warning(
139139
"ue={}: \"{}\" failed. Cause: Security context not initialized", target_ue->get_ue_index(), name());

tests/unittests/cu_cp/mobility/inter_cu_handover_routine_test.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ class inter_cu_handover_routine_test : public mobility_test
5555
generate_ul_rrc_message_transfer(int_to_gnb_cu_ue_f1ap_id(0),
5656
int_to_gnb_du_ue_f1ap_id(0),
5757
srb_id_t::srb1,
58-
make_byte_buffer("000900410004015f741fe0804bf183fc980605b7").value());
58+
make_byte_buffer("000800410004015f741fe0804bf183fcaa6e9699").value());
5959
test_logger.info("Injecting UL RRC message (RRC Measurement Report)");
6060
f1c_gw.get_du(source_du_index).on_new_message(ul_rrc_msg);
6161
}

tests/unittests/cu_cp/mobility/inter_du_handover_routine_test.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ class inter_du_handover_routine_test : public mobility_test
5959
generate_ul_rrc_message_transfer(int_to_gnb_cu_ue_f1ap_id(0),
6060
int_to_gnb_du_ue_f1ap_id(0),
6161
srb_id_t::srb1,
62-
make_byte_buffer("000900410004015f741fe0804bf183fc980605b7").value());
62+
make_byte_buffer("000800410004015f741fe0804bf183fcaa6e9699").value());
6363
test_logger.info("Injecting UL RRC message (RRC Measurement Report)");
6464
f1c_gw.get_du(source_du_index).on_new_message(ul_rrc_msg);
6565
}
@@ -146,7 +146,7 @@ class inter_du_handover_routine_test : public mobility_test
146146
f1ap_message rrc_recfg_complete = generate_ul_rrc_message_transfer(int_to_gnb_cu_ue_f1ap_id(0),
147147
int_to_gnb_du_ue_f1ap_id(0),
148148
srb_id_t::srb1,
149-
make_byte_buffer("80000a00ddc7574a").value());
149+
make_byte_buffer("8000080035c41efd").value());
150150
f1c_gw.get_du(target_du_index).on_new_message(rrc_recfg_complete);
151151
}
152152

0 commit comments

Comments
 (0)