Unverified Commit 9b33a4fc authored by Richard Fitzgerald's avatar Richard Fitzgerald Committed by Mark Brown
Browse files

firmware: cs_dsp: Add KUnit testing of control cache



Add KUnit test cases for the caching of control content.

The test cases can be divided into four groups:
1) The cache is correctly initialized when the firmware is first
   downloaded.
2) Reads return the correct data.
3) Writes update the registers and cache.
4) If a value has been written to the control it is retained in
   the cache and written out to the registers when the firmware
   is started.

There are multiple test suites to cover:
 - V1 and V2 format files on 16-bit and 32-bit ADSP2.
 - V3 format files on Halo Core DSPs.

V1 format files, and some V2 format files, didn't provide access
flags for the controls. There are a couple of test cases for
unspecified flags to ensure backwards compatibility with the
original implementation of these older firmware versions.

The obsolete V0 format does not have controls, so no testing of
that format is needed.

Signed-off-by: default avatarRichard Fitzgerald <rf@opensource.cirrus.com>
Link: https://patch.msgid.link/20241212143725.1381013-9-rf@opensource.cirrus.com


Signed-off-by: default avatarMark Brown <broonie@kernel.org>
parent 83baecd9
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment