Change in osmo-bsc[master]: abis_nm: Support parsing nanoBTS format for Get Attributes Info

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.org
Fri Nov 9 15:50:47 UTC 2018


Pau Espin Pedrol has submitted this change and it was merged. ( https://gerrit.osmocom.org/11695 )

Change subject: abis_nm: Support parsing nanoBTS format for Get Attributes Info
......................................................................

abis_nm: Support parsing nanoBTS format for Get Attributes Info

Spec compliant format is defined in:
* 3GPP TS 52.021 §8.11.3 "Get Attribute Response"
* 3GPP TS 52.021 §9.4.64 "Get Attribute Response Info".

On nanoBTS, however, reported attribute list is provided directly inside/after
the foh header instead of being enveloped inside the Get Attributes Response Info.
Furthermore, The Get Attributes Response Info can still appear and be at any position
in the reported attribute list, and it only contains the unreported
attribute ID list inside.

Change-Id: I81a613d53bddf432a79fa5cb0bf9d847b4bdee37
---
M src/osmo-bsc/abis_nm.c
1 file changed, 9 insertions(+), 1 deletion(-)

Approvals:
  Neels Hofmeyr: Looks good to me, approved
  Jenkins Builder: Verified



diff --git a/src/osmo-bsc/abis_nm.c b/src/osmo-bsc/abis_nm.c
index 89a6d82..d147606 100644
--- a/src/osmo-bsc/abis_nm.c
+++ b/src/osmo-bsc/abis_nm.c
@@ -494,7 +494,8 @@
 		     bts_nr, get_value_string(abis_nm_att_names, ari[i + 1]));
 
 	/* the data starts right after the list of unreported attributes + space for length of that list */
-	*out_len = ari_len - (num_unreported + 2);
+	if (out_len)
+		*out_len = ari_len - (num_unreported + 2);
 
 	return ari + num_unreported + 1; /* we have to account for 1st byte with number of unreported attributes */
 }
@@ -575,6 +576,13 @@
 			bts->nr, unit_id);
 	}
 
+	/* nanoBTS provides Get Attribute Response Info at random position and only the unreported part of it. */
+	if (TLVP_PRES_LEN(tp, NM_ATT_GET_ARI, 1)) {
+		data = TLVP_VAL(tp, NM_ATT_GET_ARI);
+		len = TLVP_LEN(tp, NM_ATT_GET_ARI);
+		parse_attr_resp_info_unreported(bts->nr, data, len, NULL);
+	}
+
 	return 0;
 }
 

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

Gerrit-Project: osmo-bsc
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: I81a613d53bddf432a79fa5cb0bf9d847b4bdee37
Gerrit-Change-Number: 11695
Gerrit-PatchSet: 3
Gerrit-Owner: Pau Espin Pedrol <pespin at sysmocom.de>
Gerrit-Reviewer: Jenkins Builder (1000002)
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/20181109/818ffa5e/attachment.htm>


More information about the gerrit-log mailing list