summaryrefslogtreecommitdiff
path: root/scripts/gdb/linux/utils.py
diff options
context:
space:
mode:
authorCharles Keepax <ckeepax@opensource.cirrus.com>2024-12-20 20:35:14 +0300
committerMark Brown <broonie@kernel.org>2024-12-25 01:44:55 +0300
commitc36297b1bd6e52a75a8ed75eb5dbf35c50402398 (patch)
treea1ec145f4647046d982eb091303b1735604385c4 /scripts/gdb/linux/utils.py
parent935cd06bfad4b715195befaf527a2d4fd36361d9 (diff)
downloadlinux-c36297b1bd6e52a75a8ed75eb5dbf35c50402398.tar.xz
ASoC: SDCA: Add bounds check for function address
SDCA only supports 3-bits for the function address, but the ACPI value is 64-bits. Update the code that parses this to do a bounds check and error out on invalid addresses. Currently, an invalid address would truncate to the bottom 3-bits when used and thus use a likely incorrect address. With the bounds check, it is also now safe to shrink the size of the adr member of sdca_function_desc to a u8 and rearrange the struct members to pack better with the new size of adr. Signed-off-by: Charles Keepax <ckeepax@opensource.cirrus.com> Link: https://patch.msgid.link/20241220173516.907406-3-ckeepax@opensource.cirrus.com Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'scripts/gdb/linux/utils.py')
0 files changed, 0 insertions, 0 deletions