pespin submitted this change.
on RUA Connect failure, respond with RUA Disconnect
Related: OS#6283
Related: osmo-ttcn3-hacks I2b5c024a395e736538c0c37db40d34f3b8d99991
Tweaked-by: Oliver Smith <osmith@sysmocom.de>
Change-Id: Iafb30c31a4c5db53ecdda99a0e0b5937b71e362c
---
M src/osmo-hnbgw/hnbgw_rua.c
1 file changed, 15 insertions(+), 0 deletions(-)
diff --git a/src/osmo-hnbgw/hnbgw_rua.c b/src/osmo-hnbgw/hnbgw_rua.c
index 5576fa4..01e9e3a 100644
--- a/src/osmo-hnbgw/hnbgw_rua.c
+++ b/src/osmo-hnbgw/hnbgw_rua.c
@@ -166,6 +166,20 @@
return hnbgw_rua_tx(hnb, msg);
}
+/* Send Disconnect to RUA without RANAP data */
+static void rua_tx_disc_conn_fail(struct hnb_context *hnb, bool is_ps, uint32_t context_id)
+{
+ RUA_Cause_t rua_cause = {
+ .present = RUA_Cause_PR_radioNetwork,
+ .choice.radioNetwork = RUA_CauseRadioNetwork_connect_failed,
+ };
+
+ LOG_HNBP(hnb->persistent, LOGL_INFO, "Tx RUA Disconnect\n");
+
+ if (rua_tx_disc(hnb, is_ps, context_id, &rua_cause, NULL, 0))
+ LOG_HNBP(hnb->persistent, LOGL_ERROR, "Failed to send Disconnect to RUA\n");
+}
+
static struct value_string rua_procedure_code_names[] = {
{ RUA_ProcedureCode_id_Connect, "Connect" },
{ RUA_ProcedureCode_id_DirectTransfer, "DirectTransfer" },
@@ -270,6 +284,7 @@
LOGHNB(hnb, DRUA, LOGL_ERROR,
"Failed to create context map for %s: rx RUA %s with %u bytes RANAP data\n",
is_ps ? "IuPS" : "IuCS", rua_procedure_code_name(rua_procedure), data ? len : 0);
+ rua_tx_disc_conn_fail(hnb, is_ps, context_id);
return -EINVAL;
}
break;
To view, visit change 37807. To unsubscribe, or for help writing mail filters, visit settings.