summaryrefslogtreecommitdiff
path: root/lib/mpi/mpi-cmp.c
diff options
context:
space:
mode:
authorVidyakumar Athota <vathota@codeaurora.org>2015-08-12 16:10:00 -0700
committerGerrit - the friendly Code Review server <code-review@localhost>2016-08-14 23:06:47 -0700
commitfba97387bef7f702fb2881e63cf0438036ad16f0 (patch)
tree1291282d6436a95e38568f9ab127a13ad371c2c6 /lib/mpi/mpi-cmp.c
parent2e45ea728118fa88ba245a0a755d0a3844d9f54e (diff)
ASoC: soundwire: fix out of boundary access issues
In soundwire read/write commands, register value is defined as 8 bit but it is accessed through 32 bit pointer which may cause out of boundary memory access. Fix this issue by typecast appropriately. BUG: KASan: out of bounds access in swrm_read+0x1dc/0x30c at addr ffffffc089871880 Write of size 4 by task kworker/u8:5/236 ==addr ffffffc089871880 [<ffffffc00081d174>] swrm_read+0x1d8/0x30c [<ffffffc000819808>] swr_read+0x5c/0x74 [<ffffffc000741e58>] regmap_swr_read+0xd8/0x11c [<ffffffc00073a350>] _regmap_raw_read+0x210/0x314 [<ffffffc00073a4b0>] _regmap_bus_read+0x5c/0xb4 [<ffffffc000739548>] _regmap_read+0xe0/0x1ec [<ffffffc0007396b8>] regmap_read+0x64/0xa8 [<ffffffc000dc9dd4>] snd_soc_component_read+0x34/0x70 [<ffffffc000dc9f44>] snd_soc_read+0x6c/0x94 Memory state around the buggy address: ffffffc089871780: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffffffc089871800: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc Change-Id: I3c56dffb4ca197e8fc23d54a44282a60254dd001 Signed-off-by: Vidyakumar Athota <vathota@codeaurora.org>
Diffstat (limited to 'lib/mpi/mpi-cmp.c')
0 files changed, 0 insertions, 0 deletions