Attention is currently required from: osmith, pespin.
fixeria has posted comments on this change by fixeria. ( https://gerrit.osmocom.org/c/osmocom-bb/+/43828?usp=email )
Change subject: trxcon/trx_if: migrate to libosmo-trx ......................................................................
Patch Set 2:
(1 comment)
File src/host/trxcon/src/trx_if.c:
https://gerrit.osmocom.org/c/osmocom-bb/+/43828/comment/0910cf06_29b7cd51?us... : PS1, Line 642: osmo_trx_ep_send_ctrl_msg(trx->ep, 0, &cmd_poweroff);
If the API takes care, why then sending it explicitly here?
Not sure what you mean by "explicitly". `osmo_trx_ep` does not make any assumptions regarding POWERON/POWEROFF, so there's simply no implicit "send POWEROFF on close()" logic.
`fi->state == TRX_ST_POWERON` here in `trx_fsm_cleanup_cb()` is actually an abnormal case. It can happen if the L1CTL peer does not shutdown trxcon properly (i.e. does not send `L1CTL_RESET_REQ`) before disconnecting. In this case we (the FSM) enqueue TRXC POWEROFF message, so that we do not leave the transceiver running.