abis_rsl: fix encoding RSL_IE_IPAC_RTP_CSD_FORMAT
The A-bis/IP RTP CSD Format IR Values need to be shifted by 4 bits instead of 5. See OsmoBTS Abis Protocol Specification § 5.8.14 RSL_IE_IPAC_RTP_CSD_FORMAT. Related: https://ftp.osmocom.org/docs/osmo-bts/master/osmobts-abis.pdf Related: OS#4393 Change-Id: I9ce0b2d9b77eef61a6d4dce417efe4e853217dc5changes/66/32366/1
parent
a4cc4ef8ea
commit
d128791919
|
@ -2590,18 +2590,18 @@ int ipacc_rtp_csd_fmt_transp(const struct channel_mode_and_rate *ch_mode_rate,
|
|||
switch (ch_mode_rate->data_rate.t) {
|
||||
case RSL_CMOD_CSD_T_32k0:
|
||||
case RSL_CMOD_CSD_T_29k0:
|
||||
ret |= RSL_IPAC_RTP_CSD_IR_32k << 5;
|
||||
ret |= RSL_IPAC_RTP_CSD_IR_32k << 4;
|
||||
break;
|
||||
case RSL_CMOD_CSD_T_14k4:
|
||||
case RSL_CMOD_CSD_T_9k6:
|
||||
ret |= RSL_IPAC_RTP_CSD_IR_16k << 5;
|
||||
ret |= RSL_IPAC_RTP_CSD_IR_16k << 4;
|
||||
break;
|
||||
case RSL_CMOD_CSD_T_4k8:
|
||||
case RSL_CMOD_CSD_T_2k4:
|
||||
case RSL_CMOD_CSD_T_1k2:
|
||||
case RSL_CMOD_CSD_T_600:
|
||||
case RSL_CMOD_CSD_T_1200_75:
|
||||
ret |= RSL_IPAC_RTP_CSD_IR_8k << 5;
|
||||
ret |= RSL_IPAC_RTP_CSD_IR_8k << 4;
|
||||
break;
|
||||
default:
|
||||
return -EINVAL;
|
||||
|
@ -2622,19 +2622,19 @@ int ipacc_rtp_csd_fmt_non_transp(const struct channel_mode_and_rate *ch_mode_rat
|
|||
case RSL_CMOD_CSD_NTA_14k5_43k5:
|
||||
case RSL_CMOD_CSD_NTA_29k0_43k5:
|
||||
case RSL_CMOD_CSD_NT_43k5:
|
||||
ret |= RSL_IPAC_RTP_CSD_IR_64k << 5;
|
||||
ret |= RSL_IPAC_RTP_CSD_IR_64k << 4;
|
||||
break;
|
||||
case RSL_CMOD_CSD_NTA_29k0_14k5:
|
||||
case RSL_CMOD_CSD_NTA_14k5_29k0:
|
||||
case RSL_CMOD_CSD_NT_28k8:
|
||||
ret |= RSL_IPAC_RTP_CSD_IR_32k << 5;
|
||||
ret |= RSL_IPAC_RTP_CSD_IR_32k << 4;
|
||||
break;
|
||||
case RSL_CMOD_CSD_NT_14k5:
|
||||
case RSL_CMOD_CSD_NT_12k0:
|
||||
ret |= RSL_IPAC_RTP_CSD_IR_16k << 5;
|
||||
ret |= RSL_IPAC_RTP_CSD_IR_16k << 4;
|
||||
break;
|
||||
case RSL_CMOD_CSD_NT_6k0:
|
||||
ret |= RSL_IPAC_RTP_CSD_IR_8k << 5;
|
||||
ret |= RSL_IPAC_RTP_CSD_IR_8k << 4;
|
||||
break;
|
||||
default:
|
||||
return -EINVAL;
|
||||
|
|
Loading…
Reference in New Issue