diff options
author | 2024-07-26 16:10:44 +0200 | |
---|---|---|
committer | 2024-07-29 13:36:35 +0100 | |
commit | eb11c3bb64ad0a05aeacdb01039863aa2aa3614b (patch) | |
tree | 3a4706ddf483b4ef572fa91ed5d1212bc9286590 /tools/perf/scripts/python/call-graph-from-postgresql.py | |
parent | ASoC: codecs: wcd939x-sdw: Correct Soundwire ports mask (diff) | |
download | wireguard-linux-eb11c3bb64ad0a05aeacdb01039863aa2aa3614b.tar.xz wireguard-linux-eb11c3bb64ad0a05aeacdb01039863aa2aa3614b.zip |
ASoC: codecs: wsa881x: Correct Soundwire ports mask
Device has up to WSA881X_MAX_SWR_PORTS number of ports and the array
assigned to prop.sink_dpn_prop has 0..WSA881X_MAX_SWR_PORTS-1 elements.
On the other hand, GENMASK(high, low) creates an inclusive mask between
<high, low>, so we need the mask from 0 up to WSA881X_MAX_SWR_PORTS-1.
Theoretically, too wide mask could cause an out of bounds read in
sdw_get_slave_dpn_prop() in stream.c, however only in the case of buggy
driver, e.g. adding incorrect number of ports via
sdw_stream_add_slave().
Fixes: a0aab9e1404a ("ASoC: codecs: add wsa881x amplifier support")
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Link: https://patch.msgid.link/20240726-asoc-wcd-wsa-swr-ports-genmask-v1-4-d4d7a8b56f05@linaro.org
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'tools/perf/scripts/python/call-graph-from-postgresql.py')
0 files changed, 0 insertions, 0 deletions