diff options
author | Pau Espin Pedrol <pespin@sysmocom.de> | 2019-09-28 00:50:51 +0200 |
---|---|---|
committer | pespin <pespin@sysmocom.de> | 2019-10-05 20:50:13 +0000 |
commit | 96cb0c54a97c398512e74d3fd4d14582e3ffb7e4 (patch) | |
tree | 6b4a5941a6f17c5ce5434ade4c13b12fb6dc2ec0 /src/osmo-bts-trx/trx_vty.c | |
parent | 4b72ee924cd66981d73c524d2fca091b8e5d7503 (diff) |
bts-trx: Rework code handling poweron state
Use of variables in each code is confusing and mixing configuration with
POWERON/POWEROFF state (which is at least per phy inst and not per TRX,
since those commands are only expected on the 1st phy inst).
* field "poweron" becomes "enabled", and is used as an indicator for
actions to take during TRX provisioning (hether to power it on and
configure it or to power it off).
* poweron/poweroff state becomes "powered", and it is shared by all trx
in same phy_link, and is updated only after confirmation by TRX.
* poweron_set becomes poweronoff_set (because it's used by both POWERON
and POWEROFF), and becomes shared by all trx in same phy_link, since
those CMDs are usually sent by first phy instance of the link (the first
trx).
Related: OS#4215
Change-Id: Icd0b482f1454236432e1952220bbec9d178b8607
Diffstat (limited to 'src/osmo-bts-trx/trx_vty.c')
-rw-r--r-- | src/osmo-bts-trx/trx_vty.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/osmo-bts-trx/trx_vty.c b/src/osmo-bts-trx/trx_vty.c index f554ae53..993c7809 100644 --- a/src/osmo-bts-trx/trx_vty.c +++ b/src/osmo-bts-trx/trx_vty.c @@ -290,9 +290,9 @@ DEFUN(cfg_phyinst_power_on, cfg_phyinst_power_on_cmd, struct trx_l1h *l1h = pinst->u.osmotrx.hdl; if (strcmp(argv[0], "on")) - vty_out(vty, "OFF: %d%s", trx_if_cmd_poweroff(l1h), VTY_NEWLINE); + vty_out(vty, "OFF: %d%s", trx_if_cmd_poweroff(l1h, NULL), VTY_NEWLINE); else { - vty_out(vty, "ON: %d%s", trx_if_cmd_poweron(l1h), VTY_NEWLINE); + vty_out(vty, "ON: %d%s", trx_if_cmd_poweron(l1h, NULL), VTY_NEWLINE); } return CMD_SUCCESS; |