]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
ASoC: Intel: sof_sdw: Add space for a terminator into DAIs array
authorCharles Keepax <ckeepax@opensource.cirrus.com>
Thu, 12 Dec 2024 10:57:42 +0000 (10:57 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 19 Dec 2024 17:13:20 +0000 (18:13 +0100)
commitb21a849764a4111b0bc14a5ffe987a0582419de2
treec7e83e0e8f177869b435b81691a4972b2bd784ea
parente500152469fdb36812372621069b7cd01e4b9a3e
ASoC: Intel: sof_sdw: Add space for a terminator into DAIs array

[ Upstream commit 255cc582e6e16191a20d54bcdbca6c91d3e90c5e ]

The code uses the initialised member of the asoc_sdw_dailink struct to
determine if a member of the array is in use. However in the case the
array is completely full this will lead to an access 1 past the end of
the array, expand the array by one entry to include a space for a
terminator.

Fixes: 27fd36aefa00 ("ASoC: Intel: sof-sdw: Add new code for parsing the snd_soc_acpi structs")
Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com>
Reviewed-by: Péter Ujfalusi <peter.ujfalusi@linux.intel.com>
Signed-off-by: Charles Keepax <ckeepax@opensource.cirrus.com>
Link: https://patch.msgid.link/20241212105742.1508574-1-ckeepax@opensource.cirrus.com
Signed-off-by: Mark Brown <broonie@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
sound/soc/intel/boards/sof_sdw.c