sof/test/cmocka
Seppo Ingalsuo 50bd96ded4 Volume: Allow use of extended volume scale up to 42 dB
This patch alters the volume IPC and ramp to use sQ8.16 gain
values instead of previous Q2.16 kind of unsigned gain value.
The driver has never set the min/max volume values in volume
new() IPC so the macro values VOL_MAX (+42 dB) and VOL_MIN (mute)
are used instead as limits.

The overflow in generic C code with s16 format is fixed. The
comments about volume Q format are updated.

The optimimized xt-xcc version of volume is changed to use 64
bits for multiply result to avoid loss of LSB bits in left shift
after multiply. With 64 bit result there is no need to scale the
volume multiplier as it was done with use of 32 bit multiply
result.

The cmocka volume type is changed to signed integer to match
component type used in this patch. The xtensa AE integer types
are signed so better to avoid unsigned gain values. The volume
scale in reference volume does a small error and cannot handle
above 0 dB max so it is changed as well. The test levels are
changed to exercise gains above and below 0 dB.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2019-04-18 22:06:13 +02:00
..
include cmocka: host: Make sure cmocka builds and runs for host test bench 2018-12-19 10:20:35 +00:00
src Volume: Allow use of extended volume scale up to 42 dB 2019-04-18 22:06:13 +02:00
CMakeLists.txt test: rename CHECK to UNIT_TEST 2019-03-25 14:11:47 +00:00
cmocka-xtensa-xt-toolchain.cmake cmake: cmocka: add toolchain file for xt 2019-03-20 11:37:04 +00:00
memory_mock.x.in Memory: self registering ability for audio components 2019-03-11 15:43:01 +00:00