fixeria has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmocom-bb/+/30056 )
Change subject: trxcon: fixup: handle DATA.cnf/TRAFFIC.cnf via TRXCON_EV_TX_DATA_CNF ......................................................................
trxcon: fixup: handle DATA.cnf/TRAFFIC.cnf via TRXCON_EV_TX_DATA_CNF
Found this problem while trying to build with "-flto":
../include/osmocom/bb/trxcon/l1ctl.h:21:5: error: type of 'l1ctl_tx_dt_conf' does not match original declaration [-Werror=lto-type-mismatch] 21 | int l1ctl_tx_dt_conf(struct l1ctl_client *l1c, | ^ l1ctl.c:288:5: note: type mismatch in parameter 2 288 | int l1ctl_tx_dt_conf(struct l1ctl_client *l1c, bool traffic, | ^
The trxcon_fsm is passing only two arguments to l1ctl_tx_dt_conf(). The 'traffic' flag is included in struct trxcon_param_tx_data_cnf, so the 2rd argument is not needed and should have been removed.
Change-Id: Ifc538f940571172fa237ecb7000f3cfea3655edc --- M src/host/trxcon/src/l1ctl.c 1 file changed, 2 insertions(+), 3 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/osmocom-bb refs/changes/56/30056/1
diff --git a/src/host/trxcon/src/l1ctl.c b/src/host/trxcon/src/l1ctl.c index 890e4d2..03cb486 100644 --- a/src/host/trxcon/src/l1ctl.c +++ b/src/host/trxcon/src/l1ctl.c @@ -285,13 +285,12 @@ /** * Handles both L1CTL_DATA_CONF and L1CTL_TRAFFIC_CONF. */ -int l1ctl_tx_dt_conf(struct l1ctl_client *l1c, bool traffic, +int l1ctl_tx_dt_conf(struct l1ctl_client *l1c, struct trxcon_param_tx_data_cnf *cnf) { struct msgb *msg;
- msg = l1ctl_alloc_msg(traffic ? - L1CTL_TRAFFIC_CONF : L1CTL_DATA_CONF); + msg = l1ctl_alloc_msg(cnf->traffic ? L1CTL_TRAFFIC_CONF : L1CTL_DATA_CONF); if (msg == NULL) return -ENOMEM;