diff --git a/src/audio/tdfb/tdfb_direction.c b/src/audio/tdfb/tdfb_direction.c index 8bb87a973406..73617d144657 100644 --- a/src/audio/tdfb/tdfb_direction.c +++ b/src/audio/tdfb/tdfb_direction.c @@ -280,9 +280,9 @@ static void level_update(struct tdfb_comp_data *cd, int frames, int ch_count, in /* Calculate mean square level */ for (n = 0; n < frames; n++) { s = *p; + tmp += ((int32_t)s * s); p += ch_count; tdfb_cinc_s16(&p, cd->direction.d_end, cd->direction.d_size); - tmp += ((int64_t)s * s); } /* Calculate mean square power */