<p>neels has uploaded this change for <strong>review</strong>.</p><p><a href="https://gerrit.osmocom.org/c/osmo-bsc/+/24930">View Change</a></p><pre style="font-family: monospace,monospace; white-space: pre-wrap;">ensure trigger_ho() returns zero only when HO or AS was indeed triggered<br><br>In an upcoming patch, handover_decision_2.c will use this indicator to<br>decide whether to start a penalty timer:<br>"hodec2: add low-rxqual-assignment penalty timer (2/2)"<br>Id00a07313fe04eec509b336c0637b59c707760e0<br><br>Related: SYS#5198<br>Change-Id: I5de385e0666f716184a62e6e70d656545ac5d2ee<br>---<br>M include/osmocom/bsc/handover_fsm.h<br>M src/osmo-bsc/handover_decision_2.c<br>M src/osmo-bsc/handover_fsm.c<br>3 files changed, 6 insertions(+), 6 deletions(-)<br><br></pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;">git pull ssh://gerrit.osmocom.org:29418/osmo-bsc refs/changes/30/24930/1</pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;"><span>diff --git a/include/osmocom/bsc/handover_fsm.h b/include/osmocom/bsc/handover_fsm.h</span><br><span>index 1628d8f..052e09d 100644</span><br><span>--- a/include/osmocom/bsc/handover_fsm.h</span><br><span>+++ b/include/osmocom/bsc/handover_fsm.h</span><br><span>@@ -57,7 +57,7 @@</span><br><span> </span><br><span> void handover_fsm_init();</span><br><span> </span><br><span style="color: hsl(0, 100%, 40%);">-void handover_request(struct handover_out_req *req);</span><br><span style="color: hsl(120, 100%, 40%);">+int handover_request(struct handover_out_req *req);</span><br><span> void handover_start(struct handover_out_req *req);</span><br><span> void handover_start_inter_bsc_in(struct gsm_subscriber_connection *conn,</span><br><span>                             struct msgb *ho_request_msg);</span><br><span>diff --git a/src/osmo-bsc/handover_decision_2.c b/src/osmo-bsc/handover_decision_2.c</span><br><span>index 3fa1084..3ebce90 100644</span><br><span>--- a/src/osmo-bsc/handover_decision_2.c</span><br><span>+++ b/src/osmo-bsc/handover_decision_2.c</span><br><span>@@ -854,7 +854,7 @@</span><br><span>            if ((requirements & REQUIREMENT_TCHF_MASK)) {</span><br><span>                    if (c->current.bts == c->target.bts) {</span><br><span>                                 LOGPHOLCHAN(c->current.lchan, LOGL_INFO, "Not performing assignment: Already on target type\n");</span><br><span style="color: hsl(0, 100%, 40%);">-                           return 0;</span><br><span style="color: hsl(120, 100%, 40%);">+                             return -EALREADY;</span><br><span>                    }</span><br><span>                    full_rate = true;</span><br><span>                    break;</span><br><span>@@ -899,8 +899,8 @@</span><br><span>                 LOGPHOLCHAN(c->current.lchan, LOGL_NOTICE, "Triggering assignment to %s, due to %s\n",</span><br><span>                      full_rate ? "TCH/F" : "TCH/H",</span><br><span>                           ho_reason_name(global_ho_reason));</span><br><span style="color: hsl(0, 100%, 40%);">-          reassignment_request_to_chan_type(ASSIGN_FOR_CONGESTION_RESOLUTION, c->current.lchan,</span><br><span style="color: hsl(0, 100%, 40%);">-                                                  full_rate? GSM_LCHAN_TCH_F : GSM_LCHAN_TCH_H);</span><br><span style="color: hsl(120, 100%, 40%);">+              return reassignment_request_to_chan_type(ASSIGN_FOR_CONGESTION_RESOLUTION, c->current.lchan,</span><br><span style="color: hsl(120, 100%, 40%);">+                                                        full_rate? GSM_LCHAN_TCH_F : GSM_LCHAN_TCH_H);</span><br><span>      } else {</span><br><span>             struct handover_out_req req = {</span><br><span>                      .from_hodec_id = HODEC2,</span><br><span>diff --git a/src/osmo-bsc/handover_fsm.c b/src/osmo-bsc/handover_fsm.c</span><br><span>index 5f4b892..797a336 100644</span><br><span>--- a/src/osmo-bsc/handover_fsm.c</span><br><span>+++ b/src/osmo-bsc/handover_fsm.c</span><br><span>@@ -219,7 +219,7 @@</span><br><span>      } while(0)</span><br><span> </span><br><span> /* issue handover to a cell identified by ARFCN and BSIC */</span><br><span style="color: hsl(0, 100%, 40%);">-void handover_request(struct handover_out_req *req)</span><br><span style="color: hsl(120, 100%, 40%);">+int handover_request(struct handover_out_req *req)</span><br><span> {</span><br><span>    struct gsm_subscriber_connection *conn;</span><br><span>      OSMO_ASSERT(req->old_lchan);</span><br><span>@@ -229,7 +229,7 @@</span><br><span> </span><br><span>    /* To make sure we're allowed to start a handover, go through a gscon event dispatch. If that is accepted, the</span><br><span>    * same req is passed to handover_start(). */</span><br><span style="color: hsl(0, 100%, 40%);">-   osmo_fsm_inst_dispatch(conn->fi, GSCON_EV_HANDOVER_START, req);</span><br><span style="color: hsl(120, 100%, 40%);">+    return osmo_fsm_inst_dispatch(conn->fi, GSCON_EV_HANDOVER_START, req);</span><br><span> }</span><br><span> </span><br><span> /* Check that ho has old_lchan and/or new_lchan and conn pointers match.</span><br><span></span><br></pre><p>To view, visit <a href="https://gerrit.osmocom.org/c/osmo-bsc/+/24930">change 24930</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-bsc/+/24930"/><meta itemprop="name" content="View Change"/></div></div>

<div style="display:none"> Gerrit-Project: osmo-bsc </div>
<div style="display:none"> Gerrit-Branch: master </div>
<div style="display:none"> Gerrit-Change-Id: I5de385e0666f716184a62e6e70d656545ac5d2ee </div>
<div style="display:none"> Gerrit-Change-Number: 24930 </div>
<div style="display:none"> Gerrit-PatchSet: 1 </div>
<div style="display:none"> Gerrit-Owner: neels <nhofmeyr@sysmocom.de> </div>
<div style="display:none"> Gerrit-MessageType: newchange </div>