diff options
authorNeels Hofmeyr <neels@hofmeyr.de>2018-12-19 16:01:33 +0100
committerNeels Hofmeyr <neels@hofmeyr.de>2018-12-21 02:05:08 +0100
commitaecee598a10fd1dbf7bf1f802aeaf57826015532 (patch)
parentea6008e4cdca649ca224d4c57f77ac21da42642e (diff)
err log: suggest ways to resolve AMR modes mismatch
Speech modes are limited by so many things that it can be hard to realize a simple mismatch in the osmo-bsc.cfg between 'msc' allowed AMR rates and the rates allowed in the per-bts 'amr tch-x modes'. Explicitly hint at that. It looks like this: DCHAN ERROR lchan(0-0-2-TCH_F_TCH_H_PDCH-0)[0x612000006520]{WAIT_TS_READY}: (type=TCH_H) Intersection of AMR rate configurations is empty: osmo-bsc.cfg=0x08 & requested-codec-list=0x02. In the config: make sure that the 'msc'/'amr-config' allows AMR rates that are also allowed in 'network'/'bts N'/'amr tch-h modes ...' (lchan_fsm.c:449) Change-Id: Idaf212ca5ec6d0d77f2421860a040bf4524b25a6
1 files changed, 11 insertions, 1 deletions
diff --git a/src/osmo-bsc/lchan_fsm.c b/src/osmo-bsc/lchan_fsm.c
index c87302587..ac57027c3 100644
--- a/src/osmo-bsc/lchan_fsm.c
+++ b/src/osmo-bsc/lchan_fsm.c
@@ -436,8 +436,18 @@ static int lchan_mr_config(struct gsm_lchan *lchan, const struct gsm48_multi_rat
* are not used in the multirate configuration IE. */
rc_rate = calc_amr_rate_intersection(&mr_conf_filtered, &msc->amr_conf, mr_conf);
if (rc_rate < 0) {
+ /* The msc->amr_conf comes from osmo-bsc.cfg's 'msc' / 'amr-config *k (forbidden|allowed)'.
+ * The mr_conf ultimately comes from the Assignment Request received from the MSC,
+ * see bssmap_handle_assignm_req(): first we gsm0808_dec_speech_codec_list() and then we
+ * match_codec_pref() to overlay the permitted speech with the BTS-specific AMR modes for this tch type,
+ * to obtain the s15_s0 bits, which end up in mr_conf. */
- "can not encode multirate configuration (invalid amr rate setting, MSC)\n");
+ "Intersection of AMR rate configurations is empty:"
+ " osmo-bsc.cfg=0x%02x & (requested-codec-list & permitted-modes)=0x%02x."
+ " In the config: make sure that the 'msc'/'amr-config' allows AMR rates"
+ " that are also allowed in 'network'/'bts N'/'amr %s modes ...'\n",
+ ((uint8_t*)&msc->amr_conf)[1], ((uint8_t*)mr_conf)[1],
+ full_rate ? "tch-f" : "tch-h");
return -EINVAL;