diff options
author | Charles Keepax <ckeepax@opensource.cirrus.com> | 2021-11-17 16:22:53 +0300 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2021-11-18 01:16:21 +0300 |
commit | 2925748eadc33cba3bded7b69475a1b002b124ac (patch) | |
tree | ec7130df3cbf7ab0d164d820a7141374f2585ecf /include/linux/firmware | |
parent | 5065cfabec21a4acf562932f1d0a814c119e0a69 (diff) | |
download | linux-2925748eadc33cba3bded7b69475a1b002b124ac.tar.xz |
firmware: cs_dsp: Add version checks on coefficient loading
The firmware coefficient files contain version information that is
currently ignored by the cs_dsp code. This information specifies which
version of the firmware the coefficient were generated for. Add a check
into the code which prints a warning in the case the coefficient and
firmware differ in version, in many cases this will be ok but it is not
always, so best to let the user know there is a potential issue.
Co-authored-by: Simon Trimmer <simont@opensource.cirrus.com>
Signed-off-by: Simon Trimmer <simont@opensource.cirrus.com>
Signed-off-by: Charles Keepax <ckeepax@opensource.cirrus.com>
Link: https://lore.kernel.org/r/20211117132300.1290-3-ckeepax@opensource.cirrus.com
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'include/linux/firmware')
-rw-r--r-- | include/linux/firmware/cirrus/cs_dsp.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/include/linux/firmware/cirrus/cs_dsp.h b/include/linux/firmware/cirrus/cs_dsp.h index 3a54b1afc48f..ce54705e2bec 100644 --- a/include/linux/firmware/cirrus/cs_dsp.h +++ b/include/linux/firmware/cirrus/cs_dsp.h @@ -54,12 +54,14 @@ struct cs_dsp_region { * struct cs_dsp_alg_region - Describes a logical algorithm region in DSP address space * @list: List node for internal use * @alg: Algorithm id + * @ver: Expected algorithm version * @type: Memory region type * @base: Address of region */ struct cs_dsp_alg_region { struct list_head list; unsigned int alg; + unsigned int ver; int type; unsigned int base; }; |