linux-stable/sound/soc/sof
Guennadi Liakhovetski 0e4ea87870
ASoC: SOF: fix range checks
On multiple locations checks are performed of untrusted values after adding
a constant to them. This is wrong, because the addition might overflow and
the result can then pass the check, although the original value is invalid.
Fix multiple such issues by checking the actual value and not a sum of it
and a constant.

Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
Reviewed-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
Link: https://lore.kernel.org/r/20200917105633.2579047-8-kai.vehmanen@linux.intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>
2020-09-17 15:53:20 +01:00
..
imx ASoC: SOF: imx: Add debug support for imx platforms 2020-09-17 15:53:15 +01:00
intel ASoC: SOF: Intel: hda-loader: s/master/primary 2020-09-11 15:29:32 +01:00
xtensa ASoC: SOF/Intel: clarify SPDX license with GPL-2.0-only 2020-05-01 17:45:24 +01:00
compress.c ASoC: SOF/Intel: clarify SPDX license with GPL-2.0-only 2020-05-01 17:45:24 +01:00
compress.h ASoC: SOF/Intel: clarify SPDX license with GPL-2.0-only 2020-05-01 17:45:24 +01:00
control.c ASoC: SOF: fix range checks 2020-09-17 15:53:20 +01:00
core.c ASoC: SOF: core: fix null-ptr-deref bug during device removal 2020-07-08 15:02:02 +01:00
debug.c ASoC: SOF: debug: update test for pm_runtime_get_sync() 2020-09-17 15:53:17 +01:00
ipc.c ASoC: SOF: IPC: reduce verbosity of IPC pointer updates 2020-08-25 20:39:37 +01:00
Kconfig ASoC: Intel: use consistent HDAudio spelling in comments/docs 2020-08-25 20:39:39 +01:00
loader.c ASoC: SOF: loader: Add debug box region 2020-08-26 12:44:09 +01:00
Makefile ASoC: SOF/Intel: clarify SPDX license with GPL-2.0-only 2020-05-01 17:45:24 +01:00
nocodec.c ASoC: SOF: nocodec: add missing .owner field 2020-06-26 13:35:11 +01:00
ops.c ASoC: SOF/Intel: clarify SPDX license with GPL-2.0-only 2020-05-01 17:45:24 +01:00
ops.h ASoC: SOF/Intel: clarify SPDX license with GPL-2.0-only 2020-05-01 17:45:24 +01:00
pcm.c ASoC: Intel: use consistent HDAudio spelling in comments/docs 2020-08-25 20:39:39 +01:00
pm.c ASoC: SOF: support topology components on secondary cores 2020-09-04 10:12:22 +01:00
probe.c ASoC: SOF/Intel: clarify SPDX license with GPL-2.0-only 2020-05-01 17:45:24 +01:00
probe.h ASoC: SOF: Replace zero-length array with flexible-array 2020-06-15 23:08:32 -05:00
sof-acpi-dev.c ASoC: SOF: acpi: add dev_dbg() log for probe completion 2020-08-25 20:39:38 +01:00
sof-audio.c ASoC: SOF: remove several superfluous type-casts 2020-09-17 15:53:19 +01:00
sof-audio.h ASoC: SOF: Implement snd_sof_bytes_ext_volatile_get kcontrol IO 2020-09-08 13:55:00 +01:00
sof-of-dev.c ASoC: SOF/Intel: clarify SPDX license with GPL-2.0-only 2020-05-01 17:45:24 +01:00
sof-pci-dev.c ASoC: SOF: Intel: Use DMI oem string search for tgl_max98373_rt5682 2020-09-11 15:52:19 +01:00
sof-priv.h ASoC: SOF: add a "core" parameter to widget loading functions 2020-09-04 10:12:21 +01:00
topology.c ASoC: SOF: fix range checks 2020-09-17 15:53:20 +01:00
trace.c ASoC: SOF/Intel: clarify SPDX license with GPL-2.0-only 2020-05-01 17:45:24 +01:00
utils.c ASoC: SOF/Intel: clarify SPDX license with GPL-2.0-only 2020-05-01 17:45:24 +01:00