linux-stable/sound/soc
Ravulapati Vishnu Vardhan Rao 57f9a9a232 ASoC: codecs: tx-macro: Fix for KASAN: slab-out-of-bounds
[ Upstream commit e5e7e398f6 ]

When we run syzkaller we get below Out of Bound.
    "KASAN: slab-out-of-bounds Read in regcache_flat_read"

    Below is the backtrace of the issue:

    dump_backtrace+0x0/0x4c8
    show_stack+0x34/0x44
    dump_stack_lvl+0xd8/0x118
    print_address_description+0x30/0x2d8
    kasan_report+0x158/0x198
    __asan_report_load4_noabort+0x44/0x50
    regcache_flat_read+0x10c/0x110
    regcache_read+0xf4/0x180
    _regmap_read+0xc4/0x278
    _regmap_update_bits+0x130/0x290
    regmap_update_bits_base+0xc0/0x15c
    snd_soc_component_update_bits+0xa8/0x22c
    snd_soc_component_write_field+0x68/0xd4
    tx_macro_digital_mute+0xec/0x140

    Actually There is no need to have decimator with 32 bits.
    By limiting the variable with short type u8 issue is resolved.

Signed-off-by: Ravulapati Vishnu Vardhan Rao <quic_visr@quicinc.com>
Link: https://lore.kernel.org/r/20230304080702.609-1-quic_visr@quicinc.com
Signed-off-by: Mark Brown <broonie@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2023-04-06 12:10:37 +02:00
..
adi
amd ASoC: amd: yc: Add DMI entries to support HP OMEN 16-n0xxx (8A43) 2023-03-30 12:49:15 +02:00
apple ASoC: apple: mca: Improve handling of unavailable DMA channels 2023-03-11 13:55:31 +01:00
atmel ASoC: mchp-spdifrx: Fix uninitialized use of mr in mchp_spdifrx_hw_params() 2023-03-10 09:33:19 +01:00
au1x
bcm ASoC: bcm2835-i2s: Switch to use dev_err_probe() helper 2022-09-14 15:06:00 +01:00
cirrus
codecs ASoC: codecs: tx-macro: Fix for KASAN: slab-out-of-bounds 2023-04-06 12:10:37 +02:00
dwc
fsl ASoC: fsl_sai: initialize is_dsp_mode flag 2023-03-10 09:33:12 +01:00
generic ASoC: audio-graph-card: fix refcount leak of cpu_ep in __graph_for_each_link() 2022-12-31 13:33:06 +01:00
hisilicon
img
intel ASoC: Intel: soc-acpi: fix copy-paste issue in topology names 2023-03-22 13:34:04 +01:00
jz4740 ASoC: jz4740-i2s: Handle independent FIFO flush bits 2023-01-07 11:11:51 +01:00
kirkwood ASoC: kirkwood: Iterate over array indexes instead of using pointer math 2023-03-10 09:33:58 +01:00
mediatek ASoC: mediatek: mt8195: add missing initialization 2023-03-11 13:55:31 +01:00
meson
mxs
pxa ASoC: pxa: fix null-pointer dereference in filter() 2022-12-31 13:32:11 +01:00
qcom ASoC: qcom: q6prm: fix incorrect clk_root passed to ADSP 2023-03-22 13:34:05 +01:00
rockchip ASoC: rockchip: spdif: Add missing clk_disable_unprepare() in rk_spdif_runtime_resume() 2022-12-31 13:33:07 +01:00
samsung ASoC: soc.h: remove num_cpus/codecs 2022-09-20 12:19:30 +01:00
sh ASoC: rsnd: fixup #endif position 2023-03-10 09:33:19 +01:00
sof ASoC: SOF: ipc4-topology: set dmic dai index from copier 2023-03-22 13:33:40 +01:00
spear
sprd
sti
stm ASoC: stm32: i2s: remove irqf_oneshot flag 2022-11-10 17:50:52 +00:00
sunxi ASoC: sunxi: fix declaration compile error 2022-09-21 10:28:19 +01:00
tegra
ti ASoC: ti: omap-mcbsp: remove useless assignment 2022-08-31 12:13:05 +01:00
uniphier
ux500
xilinx
xtensa
Kconfig ASoC: apple: mca: Start new platform driver 2022-08-25 13:51:34 +01:00
Makefile ASoC: apple: mca: Start new platform driver 2022-08-25 13:51:34 +01:00
soc-ac97.c ASoC: Variable type completion 2022-08-17 13:00:27 +01:00
soc-acpi.c
soc-card.c
soc-component.c Revert "ASoC: soc-component: using pm_runtime_resume_and_get instead of pm_runtime_get_sync" 2022-10-04 14:09:30 +01:00
soc-compress.c ASoC: soc-compress: Reposition and add pcm_mutex 2023-03-10 09:33:58 +01:00
soc-core.c ASoC: core: Fix use-after-free in snd_soc_exit() 2022-10-28 12:58:04 +01:00
soc-dai.c ASoC: Change handling of unimplemented set_bclk_ratio 2022-08-19 13:19:59 +01:00
soc-dapm.c ASoC: dapm: Don't use prefix for regulator name 2022-10-26 14:17:34 +01:00
soc-devres.c
soc-generic-dmaengine-pcm.c ASoC: soc.h: remove num_cpus/codecs 2022-09-20 12:19:30 +01:00
soc-jack.c
soc-link.c
soc-ops.c ASoC: ops: Correct bounds check for second channel on SX controls 2022-11-25 16:29:33 +00:00
soc-pcm.c ASoC: soc-pcm: Add NULL check in BE reparenting 2022-11-22 12:23:00 +00:00
soc-topology-test.c
soc-topology.c ASoC: topology: Properly access value coming from topology file 2023-03-10 09:33:18 +01:00
soc-utils-test.c ASoC: soc-utils-test: Add test for snd_soc_params_to_bclk() 2022-08-17 15:19:14 +01:00
soc-utils.c ASoC: soc-utils: Remove __exit for snd_soc_util_exit() 2022-11-07 13:37:04 +00:00