Change in libosmo-sccp[master]: improve logging for rejected AS in xua_rkm.c

Neels Hofmeyr gerrit-no-reply at lists.osmocom.org
Thu Mar 14 03:41:59 UTC 2019


Neels Hofmeyr has submitted this change and it was merged. ( https://gerrit.osmocom.org/13229 )

Change subject: improve logging for rejected AS in xua_rkm.c
......................................................................

improve logging for rejected AS in xua_rkm.c

Change a loglevel from NOTICE to ERROR, for when a routing key gets
re-purposed.

Add another error log for insufficient resources case.

Change-Id: Id22e3c6bab5f7b597df3514eedb162277ce0ef7d
---
M src/xua_rkm.c
1 file changed, 3 insertions(+), 1 deletion(-)

Approvals:
  Max: Looks good to me, but someone else must approve
  Pau Espin Pedrol: Looks good to me, approved
  Jenkins Builder: Verified



diff --git a/src/xua_rkm.c b/src/xua_rkm.c
index a77460d..4b760ee 100644
--- a/src/xua_rkm.c
+++ b/src/xua_rkm.c
@@ -214,7 +214,7 @@
 	if (as) {
 		LOGPASP(asp, DLSS7, LOGL_NOTICE, "RKM: Found existing AS for RCTX %u\n", rctx);
 		if (as->cfg.routing_key.pc != dpc) {
-			LOGPASP(asp, DLSS7, LOGL_NOTICE, "RKM: DPC doesn't match (%u != %u)\n",
+			LOGPASP(asp, DLSS7, LOGL_ERROR, "RKM: DPC doesn't match, rejecting AS (%u != %u)\n",
 				as->cfg.routing_key.pc, dpc);
 			msgb_append_reg_res(resp, rk_id, M3UA_RKM_REG_ERR_INVAL_RKEY, 0);
 			return -1;
@@ -250,6 +250,8 @@
 		if (*nas_idx >= max_nas_idx) {
 			osmo_ss7_route_destroy(rt);
 			osmo_ss7_as_destroy(as);
+			LOGPASP(asp, DLSS7, LOGL_ERROR, "RKM: not enough room for newly assigned AS (max %u AS)\n",
+				max_nas_idx+1);
 			msgb_append_reg_res(resp, rk_id, M3UA_RKM_REG_ERR_INSUFF_RESRC, 0);
 			return -1;
 		}

-- 
To view, visit https://gerrit.osmocom.org/13229
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings

Gerrit-Project: libosmo-sccp
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: Id22e3c6bab5f7b597df3514eedb162277ce0ef7d
Gerrit-Change-Number: 13229
Gerrit-PatchSet: 2
Gerrit-Owner: Neels Hofmeyr <nhofmeyr at sysmocom.de>
Gerrit-Reviewer: Jenkins Builder (1000002)
Gerrit-Reviewer: Max <msuraev at sysmocom.de>
Gerrit-Reviewer: Neels Hofmeyr <nhofmeyr at sysmocom.de>
Gerrit-Reviewer: Pau Espin Pedrol <pespin at sysmocom.de>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20190314/57251a3c/attachment.html>


More information about the gerrit-log mailing list