2
0
mirror of git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git synced 2025-09-04 20:19:47 +08:00
linux/sound/soc/sof
Tamura Dai 6c038b58a2
ASoC: SOF: Intel: hda: Use devm_kstrdup() to avoid memleak.
sof_pdata->tplg_filename can have address allocated by kstrdup()
and can be overwritten. Memory leak was detected with kmemleak:

unreferenced object 0xffff88812391ff60 (size 16):
  comm "kworker/4:1", pid 161, jiffies 4294802931
  hex dump (first 16 bytes):
    73 6f 66 2d 68 64 61 2d 67 65 6e 65 72 69 63 00  sof-hda-generic.
  backtrace (crc 4bf1675c):
    __kmalloc_node_track_caller_noprof+0x49c/0x6b0
    kstrdup+0x46/0xc0
    hda_machine_select.cold+0x1de/0x12cf [snd_sof_intel_hda_generic]
    sof_init_environment+0x16f/0xb50 [snd_sof]
    sof_probe_continue+0x45/0x7c0 [snd_sof]
    sof_probe_work+0x1e/0x40 [snd_sof]
    process_one_work+0x894/0x14b0
    worker_thread+0x5e5/0xfb0
    kthread+0x39d/0x760
    ret_from_fork+0x31/0x70
    ret_from_fork_asm+0x1a/0x30

Signed-off-by: Tamura Dai <kirinode0@gmail.com>
Link: https://patch.msgid.link/20250615235548.8591-1-kirinode0@gmail.com
Signed-off-by: Mark Brown <broonie@kernel.org>
2025-06-24 16:39:42 +01:00
..
amd sound updates for 6.16-rc1 2025-05-27 15:05:18 -07:00
imx ASoC: SOF: imx8: add core shutdown operation for imx8/imx8x 2025-06-16 13:26:13 +01:00
intel ASoC: SOF: Intel: hda: Use devm_kstrdup() to avoid memleak. 2025-06-24 16:39:42 +01:00
mediatek ASoC: SOF: mediatek: Commonize duplicated functions 2025-03-20 18:56:50 +00:00
xtensa module: Convert symbol namespace to string literal 2024-12-02 11:34:44 -08:00
compress.c ASoC: SOF: Use no_reply calls for TX 2023-04-20 12:51:45 +01:00
control.c ASoC: SOF: Intel: clarify Copyright information 2024-05-06 23:59:35 +09:00
core.c ASoC: SOF: set disable_function_topology if override_tplg_filename is set 2025-05-06 22:48:04 +09:00
debug.c ASoC: SOF: Intel: clarify Copyright information 2024-05-06 23:59:35 +09:00
fw-file-profile.c ASoC: SOF: Intel: clarify Copyright information 2024-05-06 23:59:35 +09:00
iomem-utils.c move asm/unaligned.h to linux/unaligned.h 2024-10-02 17:23:23 -04:00
ipc3-control.c ASoC: SOF: Intel: clarify Copyright information 2024-05-06 23:59:35 +09:00
ipc3-dtrace.c ASoC: SOF: Intel: clarify Copyright information 2024-05-06 23:59:35 +09:00
ipc3-loader.c ASoC: SOF: ipc3-loader: 'Handle' PROBE_INFO ext_manifest type when parsing 2024-11-07 13:03:23 +00:00
ipc3-pcm.c ASoC: SOF: pcm: Add snd_sof_pcm specific wrappers for dev_dbg() and dev_err() 2025-02-06 11:25:43 +00:00
ipc3-priv.h ASoC: SOF: Intel: clarify Copyright information 2024-05-06 23:59:35 +09:00
ipc3-topology.c ASoC: SOF: Relocate and rework functionality for PCM stream freeing 2025-02-06 11:25:41 +00:00
ipc3.c ASoC: SOF: ipc3: Use str_enabled_disabled() helper function 2025-02-17 12:09:40 +00:00
ipc4-control.c ASoC: SOF: ipc4-control: Use SOF_CTRL_CMD_BINARY as numid for bytes_ext 2025-05-09 18:20:13 +09:00
ipc4-fw-reg.h ASoC: SOF: Intel: clarify Copyright information 2024-05-06 23:59:35 +09:00
ipc4-loader.c ASoC: SOF: ipc4: Add support for Intel HW managed mic privacy messaging 2025-03-08 16:06:40 +00:00
ipc4-mtrace.c ASoC: SOF: Intel: clarify Copyright information 2024-05-06 23:59:35 +09:00
ipc4-pcm.c Merge branch 'for-linus' into for-next 2025-05-22 20:34:24 +02:00
ipc4-priv.h ASoC: SOF: ipc4: Add support for Intel HW managed mic privacy messaging 2025-03-08 16:06:40 +00:00
ipc4-telemetry.c ASoC: SOF: Intel: clarify Copyright information 2024-05-06 23:59:35 +09:00
ipc4-telemetry.h ASoC: SOF: Intel: clarify Copyright information 2024-05-06 23:59:35 +09:00
ipc4-topology.c ASoC: SOF: ipc4-topology: Allocate ref_params on stack 2025-03-13 12:46:22 +00:00
ipc4-topology.h ASoC: SOF: ipc4-topology/pcm: Rename sof_ipc4_copier_is_single_format() 2024-05-30 12:33:30 +01:00
ipc4.c ASoC: SOF: ipc4: Add support for Intel HW managed mic privacy messaging 2025-03-08 16:06:40 +00:00
ipc.c ASoC: SOF: Intel: clarify Copyright information 2024-05-06 23:59:35 +09:00
Kconfig ASoC: SOF: core: Implement IPC version fallback if firmware files are missing 2023-11-29 13:25:15 +00:00
loader.c ASoC: SOF: Intel: clarify Copyright information 2024-05-06 23:59:35 +09:00
Makefile ASoC: SOF: Use *-y instead of *-objs in Makefile 2024-05-08 11:39:30 +09:00
nocodec.c ASoC: sof: remove dpcm_xxx flags 2024-10-23 13:01:56 +01:00
ops.c ASoC: SOF: Intel: clarify Copyright information 2024-05-06 23:59:35 +09:00
ops.h iopoll/regmap/phy/snd: Fix comment referencing outdated timer documentation 2024-10-16 00:36:47 +02:00
pcm.c ASoC: Merge up fixes 2025-03-05 19:10:50 +00:00
pm.c ASoC: SOF: Intel: clarify Copyright information 2024-05-06 23:59:35 +09:00
sof-acpi-dev.c ASoC: SOF: acpi: Convert to EXPORT_NS_DEV_PM_OPS() 2025-03-17 10:14:55 +00:00
sof-acpi-dev.h ASoC: SOF: Intel: clarify Copyright information 2024-05-06 23:59:35 +09:00
sof-audio.c ASoC: SOF: Relocate and rework functionality for PCM stream freeing 2025-02-06 11:25:41 +00:00
sof-audio.h ASoC: SOF: pcm: Add snd_sof_pcm specific wrappers for dev_dbg() and dev_err() 2025-02-06 11:25:43 +00:00
sof-client-ipc-flood-test.c sof-client-ipc-flood-test: don't mess with ->d_name 2025-01-15 13:14:37 +01:00
sof-client-ipc-kernel-injector.c module: Convert symbol namespace to string literal 2024-12-02 11:34:44 -08:00
sof-client-ipc-msg-injector.c module: Convert symbol namespace to string literal 2024-12-02 11:34:44 -08:00
sof-client-probes-ipc3.c ASoC: SOF: Intel: clarify Copyright information 2024-05-06 23:59:35 +09:00
sof-client-probes-ipc4.c ASoC: SOF: sof-client-probes-ipc4: Set param_size extension bits 2024-11-07 15:35:52 +00:00
sof-client-probes.c module: Convert symbol namespace to string literal 2024-12-02 11:34:44 -08:00
sof-client-probes.h
sof-client.c module: Convert symbol namespace to string literal 2024-12-02 11:34:44 -08:00
sof-client.h ASoC: SOF: Add IPC3 Kernel Injector 2023-06-09 10:44:40 +01:00
sof-of-dev.c ASoC: SOF: of: Convert to EXPORT_DEV_PM_OPS() 2025-03-17 10:14:57 +00:00
sof-of-dev.h ASoC: SOF: Move sof_of_machine_select() to core.c from sof-of-dev.c 2023-12-04 17:02:15 +00:00
sof-pci-dev.c ASoC: sof: Use pure devres PCI 2025-05-05 19:32:11 +09:00
sof-pci-dev.h ASoC: SOF: Intel: clarify Copyright information 2024-05-06 23:59:35 +09:00
sof-priv.h ASoC: SOF: sof-priv: Remove unused SOF_DAI_STREAM() and SOF_FORMATS 2024-12-13 13:25:52 +00:00
sof-utils.c move asm/unaligned.h to linux/unaligned.h 2024-10-02 17:23:23 -04:00
sof-utils.h ASoC: SOF: Intel: clarify Copyright information 2024-05-06 23:59:35 +09:00
stream-ipc.c ASoC: SOF: stream-ipc: Check for cstream nullity in sof_ipc_msg_data() 2025-02-05 14:06:26 +00:00
topology.c Merge branch 'for-linus' into for-next 2025-05-22 20:34:24 +02:00
trace.c ASoC: SOF: Intel: clarify Copyright information 2024-05-06 23:59:35 +09:00