This is merely a historical archive of years 2008-2021, before the migration to mailman3.
A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.
Pau Espin Pedrol gerrit-no-reply at lists.osmocom.orgPau Espin Pedrol has uploaded this change for review. ( https://gerrit.osmocom.org/11694 Change subject: abis_nm: Add support to parse OML IP and Unit Id in Get Attributes ...................................................................... abis_nm: Add support to parse OML IP and Unit Id in Get Attributes Change-Id: Ia05e0b8fe3e28aaf2b2253d018f0614e83e23caa --- M src/osmo-bsc/abis_nm.c 1 file changed, 22 insertions(+), 0 deletions(-) git pull ssh://gerrit.osmocom.org:29418/osmo-bsc refs/changes/94/11694/1 diff --git a/src/osmo-bsc/abis_nm.c b/src/osmo-bsc/abis_nm.c index eabd4b5..f089787 100644 --- a/src/osmo-bsc/abis_nm.c +++ b/src/osmo-bsc/abis_nm.c @@ -473,6 +473,9 @@ uint16_t len; int i; int rc; + uint16_t port; + struct in_addr ia = {0}; + char unit_id[40]; struct abis_nm_sw_desc sw_descr[MAX_BTS_ATTR]; /* Parse Attribute Response Info content for 3GPP TS 52.021 §9.4.30 Manufacturer Id */ @@ -528,6 +531,25 @@ } } + if (TLVP_PRES_LEN(tp, NM_ATT_IPACC_PRIM_OML_CFG_LIST, 7)) { + data = TLVP_VAL(tp, NM_ATT_IPACC_PRIM_OML_CFG_LIST); + if (NM_ATT_IPACC_PRIM_OML_CFG == *data) { + ia.s_addr = htonl(osmo_load32be(data+1)); + port = osmo_load16be(data+5); + LOGPFOH(DNM, LOGL_INFO, foh, "BTS%u Get Attributes Response: Primary OML IP is %s:%u\n", bts->nr, inet_ntoa(ia), port); + } else { + LOGPFOH(DNM, LOGL_ERROR, foh, "BTS%u Get Attributes Response: PRIM_OML_CFG_LIST unexpected format: %s\n", + bts->nr, osmo_hexdump(data, TLVP_LEN(tp, NM_ATT_IPACC_PRIM_OML_CFG_LIST))); + } + } + + if (TLVP_PRES_LEN(tp, NM_ATT_IPACC_UNIT_ID, 1)) { + data = TLVP_VAL(tp, NM_ATT_IPACC_UNIT_ID); + len = TLVP_LEN(tp, NM_ATT_IPACC_UNIT_ID); + osmo_strlcpy(unit_id, (char*)data, OSMO_MIN(len, sizeof(unit_id))); + LOGPFOH(DNM, LOGL_ERROR, foh, "BTS%u Get Attributes Response: Unit ID is %s\n", bts->nr, unit_id); + } + return 0; } -- To view, visit https://gerrit.osmocom.org/11694 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-bsc Gerrit-Branch: master Gerrit-MessageType: newchange Gerrit-Change-Id: Ia05e0b8fe3e28aaf2b2253d018f0614e83e23caa Gerrit-Change-Number: 11694 Gerrit-PatchSet: 1 Gerrit-Owner: Pau Espin Pedrol <pespin at sysmocom.de> -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20181108/80547873/attachment.htm>