diff options
author | Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com> | 2020-09-17 13:56:32 +0300 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2020-09-17 15:53:20 +0100 |
commit | 0e4ea878708be903566ad93d4972ad3dd4c1c30e (patch) | |
tree | a8e55e074d3a1d6cf468073b9b413ecfed36236e /drivers/rtc/rtc-ab3100.c | |
parent | db69bcf915a37d7b8e54acf5f67d09d8159eb616 (diff) | |
download | linux-0e4ea878708be903566ad93d4972ad3dd4c1c30e.tar.bz2 |
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>
Diffstat (limited to 'drivers/rtc/rtc-ab3100.c')
0 files changed, 0 insertions, 0 deletions