aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDaniel Willmann <daniel@totalueberwachung.de>2013-01-04 00:14:11 +0100
committerDaniel Willmann <daniel@totalueberwachung.de>2013-01-04 00:14:11 +0100
commitd6c3fde1f6b7f224bf3929816919a2e68f10c18b (patch)
tree0ebc95eab0f32d9f3955c9ffd4fc7fed8ba9f4c1
parent35a1714367f22a7b902877af9dad60f76f638ef2 (diff)
oml: Print out power setting in txpower completion callbackdaniel/channel-ho-wip
-rw-r--r--src/osmo-bts-sysmo/oml.c24
1 files changed, 19 insertions, 5 deletions
diff --git a/src/osmo-bts-sysmo/oml.c b/src/osmo-bts-sysmo/oml.c
index 881afb12..17192ce1 100644
--- a/src/osmo-bts-sysmo/oml.c
+++ b/src/osmo-bts-sysmo/oml.c
@@ -898,6 +898,24 @@ static void dump_lch_par(int logl, GsmL1_LogChParam_t *lch_par, GsmL1_Sapi_t sap
LOGPC(DL1C, logl, ")\n");
}
+static int chmod_txpower_compl_cb(struct msgb *l1_msg, void *data)
+{
+ struct gsm_bts_trx *trx = data;
+ GsmL1_Prim_t *l1p = msgb_l1prim(l1_msg);
+ GsmL1_MphConfigCnf_t *cc = &l1p->u.mphConfigCnf;
+
+ LOGP(DL1C, LOGL_INFO, "%s MPH-CONFIG.conf (%s) ",
+ gsm_trx_name(trx),
+ get_value_string(femtobts_l1cfgt_names, cc->cfgParamId));
+
+ LOGPC(DL1C, LOGL_INFO, "setTxPower %f dBm\n",
+ cc->cfgParams.setTxPowerLevel.fTxPowerLevel);
+
+ msgb_free(l1_msg);
+
+ return 0;
+}
+
static int chmod_modif_compl_cb(struct msgb *l1_msg, void *data)
{
struct gsm_lchan *lchan = data;
@@ -916,10 +934,6 @@ static int chmod_modif_compl_cb(struct msgb *l1_msg, void *data)
sapi_queue_dispatch(lchan, cc->status);
break;
- case GsmL1_ConfigParamId_SetTxPowerLevel:
- LOGPC(DL1C, LOGL_INFO, "setTxPower %f dBm\n",
- cc->cfgParams.setTxPowerLevel.fTxPowerLevel);
- break;
case GsmL1_ConfigParamId_SetCipheringParams:
switch (lchan->ciph_state) {
case LCHAN_CIPH_RX_REQ:
@@ -1024,7 +1038,7 @@ int l1if_set_txpower(struct femtol1_hdl *fl1h, float tx_power)
conf_req->cfgParamId = GsmL1_ConfigParamId_SetTxPowerLevel;
conf_req->cfgParams.setTxPowerLevel.fTxPowerLevel = tx_power;
- return l1if_req_compl(fl1h, msg, 0, NULL, NULL);
+ return l1if_req_compl(fl1h, msg, 0, chmod_txpower_compl_cb, fl1h->priv);
}
const enum GsmL1_CipherId_t rsl2l1_ciph[] = {