<p>neels has uploaded this change for <strong>review</strong>.</p><p><a href="https://gerrit.osmocom.org/c/osmo-bsc/+/19837">View Change</a></p><pre style="font-family: monospace,monospace; white-space: pre-wrap;">CBSP VTY: add 'cbc' / 'restart' command<br><br>To change between CBC server and client modes, the ttcn3-bsc-tests suite must<br>be able to restart the CBSP link in a running osmo-bsc.<br><br>I first considered doing that by the 'remote-ip' (client) and 'listen-port'<br>(server) commands, but since those also have a remote-port and listen-ip<br>setting to go with those, it is better to explicitly restart.<br><br>Related: I7eea0dd39de50ed80af79e0f10c836b8685d8644 (osmo-ttcn3-hacks)<br>Change-Id: I5724369527cf38bd7b82f3db5e2b44254d22f8d5<br>---<br>M src/osmo-bsc/cbsp_link.c<br>1 file changed, 12 insertions(+), 0 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/37/19837/1</pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;"><span>diff --git a/src/osmo-bsc/cbsp_link.c b/src/osmo-bsc/cbsp_link.c</span><br><span>index d6e688e..034f7b4 100644</span><br><span>--- a/src/osmo-bsc/cbsp_link.c</span><br><span>+++ b/src/osmo-bsc/cbsp_link.c</span><br><span>@@ -377,6 +377,17 @@</span><br><span>     return CMD_SUCCESS;</span><br><span> }</span><br><span> </span><br><span style="color: hsl(120, 100%, 40%);">+DEFUN(cfg_cbc_restart, cfg_cbc_restart_cmd,</span><br><span style="color: hsl(120, 100%, 40%);">+     "restart",</span><br><span style="color: hsl(120, 100%, 40%);">+  "Restart the CBSP link, so that configuration on the 'cbc' node takes effect.\n")</span><br><span style="color: hsl(120, 100%, 40%);">+{</span><br><span style="color: hsl(120, 100%, 40%);">+        if (bsc_cbc_link_restart()) {</span><br><span style="color: hsl(120, 100%, 40%);">+         vty_out(vty, "%% Error restarting CBSP link%s", VTY_NEWLINE);</span><br><span style="color: hsl(120, 100%, 40%);">+               return CMD_WARNING;</span><br><span style="color: hsl(120, 100%, 40%);">+   }</span><br><span style="color: hsl(120, 100%, 40%);">+     return CMD_SUCCESS;</span><br><span style="color: hsl(120, 100%, 40%);">+}</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span> static struct cmd_node cbc_node = {</span><br><span>      CBC_NODE,</span><br><span>    "%s(config-cbc)# ",</span><br><span>@@ -440,4 +451,5 @@</span><br><span>  install_element(CBC_NODE, &cfg_cbc_listen_port_cmd);</span><br><span>     install_element(CBC_NODE, &cfg_cbc_no_listen_port_cmd);</span><br><span>  install_element(CBC_NODE, &cfg_cbc_listen_ip_cmd);</span><br><span style="color: hsl(120, 100%, 40%);">+        install_element(CBC_NODE, &cfg_cbc_restart_cmd);</span><br><span> }</span><br><span></span><br></pre><p>To view, visit <a href="https://gerrit.osmocom.org/c/osmo-bsc/+/19837">change 19837</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/+/19837"/><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: I5724369527cf38bd7b82f3db5e2b44254d22f8d5 </div>
<div style="display:none"> Gerrit-Change-Number: 19837 </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>