From 64a4327c34568628d5eb9bfc63fdcf88f60e1c3f Mon Sep 17 00:00:00 2001 From: Holger Hans Peter Freyther Date: Wed, 26 Mar 2014 18:02:08 +0100 Subject: sysmobts: Apply the potentially new max_power_red on the TRX In case the max power reduction has been changed through OML, let us call the l1if_set_txpower routine to update the nominal power. This has been manually verified with both BTS #1 and #57. ./bsc_control.py -d localhost -p 4249 -s bts.0.trx.0.max-power-reduction 0 The above command and GNUradio have been used to determine if the power level has changed at all. Fixes: SYS#268 --- src/osmo-bts-sysmo/oml.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/osmo-bts-sysmo/oml.c b/src/osmo-bts-sysmo/oml.c index c52d80c9..f8f7a0af 100644 --- a/src/osmo-bts-sysmo/oml.c +++ b/src/osmo-bts-sysmo/oml.c @@ -1535,6 +1535,15 @@ int bts_model_check_oml(struct gsm_bts *bts, uint8_t msg_type, int bts_model_apply_oml(struct gsm_bts *bts, struct msgb *msg, struct tlv_parsed *new_attr, int kind, void *obj) { + if (kind == NM_OC_RADIO_CARRIER) { + struct gsm_bts_trx *trx = obj; + struct femtol1_hdl *fl1h = trx_femtol1_hdl(trx); + + /* Did we go through MphInit yet? If yes fire and forget */ + if (fl1h->hLayer1) + l1if_set_txpower(fl1h, trx->nominal_power - trx->max_power_red); + } + /* FIXME: we actaully need to send a ACK or NACK for the OML message */ return oml_fom_ack_nack(msg, 0); } -- cgit v1.2.3