DTX: add explicit check if DTX enabled

Check explicitly if DTX is enabled for AMR before checking if SID frame
repetition is optional.

Change-Id: I660688d56505798cade1495c30338fd6806a3259
Related: OS#1801
This commit is contained in:
Max 2016-12-08 14:44:02 +01:00
parent 960dd993cd
commit 55a7b07417
1 changed files with 3 additions and 0 deletions

View File

@ -257,6 +257,9 @@ static inline void dtx_sti_unset(struct gsm_lchan *lchan)
*/
static inline bool dtx_amr_sid_optional(struct gsm_lchan *lchan, uint32_t fn)
{
if (!dtx_dl_amr_enabled(lchan))
return true;
/* Compute approx. time delta x26 based on Fn duration */
uint32_t dx26 = 120 * (fn - lchan->tch.dtx.fn);