<p>osmith has uploaded this change for <strong>review</strong>.</p><p><a href="https://gerrit.osmocom.org/c/osmo-bts/+/15326">View Change</a></p><pre style="font-family: monospace,monospace; white-space: pre-wrap;">pcu_sock: fix endian-swapped CellID<br><br>Restore the correct endianness of the cell identity stored in the system<br>information type 3 struct, just like we do it with the location area<br>code.<br><br>In the Osmocom stack, the CellID is configured in OsmoBSC, sent via RSL<br>to OsmoBTS, then with a socket to OsmoPCU. OsmoBTS was always sending<br>the swapped CellID to OsmoPCU. In March 2018, a regression in OsmoPCU<br>([1]) caused it to swap the CellID again, by chance resulting in the<br>correct value sent from OsmoBSC. This regression was fixed in March<br>2019 ([2]).<br><br>I've verified this fix with a TTCN3 test [3].<br><br>[1] I787fed84a7b613158a5618dd5cffafe4e4927234 (osmo-pcu)<br>[2] I2f6cc930c5dbf8dac386b24b0756df2efe8199e4 (osmo-pcu)<br>[3] I6516808f4b9e9a2301f9ccc1e55ded14e7334c33 (osmo-ttcn3-hacks)<br><br>Related: OS#3854<br>Change-Id: I68faf4558f0686fb2a3db24077dceaae05bf0262<br>---<br>M src/common/pcu_sock.c<br>1 file changed, 1 insertion(+), 1 deletion(-)<br><br></pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;">git pull ssh://gerrit.osmocom.org:29418/osmo-bts refs/changes/26/15326/1</pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;"><span>diff --git a/src/common/pcu_sock.c b/src/common/pcu_sock.c</span><br><span>index 36cc6ed..84a98f5 100644</span><br><span>--- a/src/common/pcu_sock.c</span><br><span>+++ b/src/common/pcu_sock.c</span><br><span>@@ -259,7 +259,7 @@</span><br><span>                                           bts->si_buf[SYSINFO_TYPE_3];</span><br><span>              osmo_plmn_from_bcd(si3->lai.digits, &net->plmn);</span><br><span>           bts->location_area_code = ntohs(si3->lai.lac);</span><br><span style="color: hsl(0, 100%, 40%);">-            bts->cell_identity = si3->cell_identity;</span><br><span style="color: hsl(120, 100%, 40%);">+                bts->cell_identity = ntohs(si3->cell_identity);</span><br><span>                avail_lai = 1;</span><br><span>               break;</span><br><span>       case S_NEW_NSE_ATTR:</span><br><span></span><br></pre><p>To view, visit <a href="https://gerrit.osmocom.org/c/osmo-bts/+/15326">change 15326</a>. To unsubscribe, or for help writing mail filters, visit <a href="https://gerrit.osmocom.org/settings">settings</a>.</p><div itemscope itemtype="http://schema.org/EmailMessage"><div itemscope itemprop="action" itemtype="http://schema.org/ViewAction"><link itemprop="url" href="https://gerrit.osmocom.org/c/osmo-bts/+/15326"/><meta itemprop="name" content="View Change"/></div></div>

<div style="display:none"> Gerrit-Project: osmo-bts </div>
<div style="display:none"> Gerrit-Branch: master </div>
<div style="display:none"> Gerrit-Change-Id: I68faf4558f0686fb2a3db24077dceaae05bf0262 </div>
<div style="display:none"> Gerrit-Change-Number: 15326 </div>
<div style="display:none"> Gerrit-PatchSet: 1 </div>
<div style="display:none"> Gerrit-Owner: osmith <osmith@sysmocom.de> </div>
<div style="display:none"> Gerrit-MessageType: newchange </div>