{"id":"CVE-2025-40162","state":"PUBLISHED","title":"ASoC: amd/sdw_utils: avoid NULL deref when devm_kasprintf() fails","description":"In the Linux kernel, the following vulnerability has been resolved:\n\nASoC: amd/sdw_utils: avoid NULL deref when devm_kasprintf() fails\n\ndevm_kasprintf() may return NULL on memory allocation failure,\nbut the debug message prints cpus->dai_name before checking it.\nMove the dev_dbg() call after the NULL check to prevent potential\nNULL pointer dereference.","publishedAt":"2025-11-12T10:26:22.883Z","updatedAt":"2026-05-11T21:43:56.425Z","severity":null,"assigner":"Linux","products":["Linux Linux"],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"cb8ea62e6402067ba092d4c1d66a9440513a572b","status":"affected","lessThan":"095d692e5997ece300c89f10d903d5230090e6a0","versionType":"git"},{"version":"cb8ea62e6402067ba092d4c1d66a9440513a572b","status":"affected","lessThan":"a1cccbd19676fc36854535a7118ba2c27d0b84b3","versionType":"git"},{"version":"cb8ea62e6402067ba092d4c1d66a9440513a572b","status":"affected","lessThan":"5726b68473f7153a7f6294185e5998b7e2a230a2","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["sound/soc/amd/acp/acp-sdw-sof-mach.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"6.12","status":"affected"},{"version":"0","status":"unaffected","lessThan":"6.12","versionType":"semver"},{"version":"6.12.55","status":"unaffected","lessThanOrEqual":"6.12.*","versionType":"semver"},{"version":"6.17.5","status":"unaffected","lessThanOrEqual":"6.17.*","versionType":"semver"},{"version":"6.18","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["sound/soc/amd/acp/acp-sdw-sof-mach.c"]}],"references":["https://git.kernel.org/stable/c/095d692e5997ece300c89f10d903d5230090e6a0","https://git.kernel.org/stable/c/a1cccbd19676fc36854535a7118ba2c27d0b84b3","https://git.kernel.org/stable/c/5726b68473f7153a7f6294185e5998b7e2a230a2"],"weaknesses":[],"ingestedAt":"2026-10-29T20:09:09.358Z","source":{"repository":"CVEProject/cvelistV5","path":"cves/2025/40xxx/CVE-2025-40162.json","commit":"556c9d3a8cd17e218bb8e452ba7cd619a384ff47"},"raw":{"dataType":"CVE_RECORD","dataVersion":"5.2","cveMetadata":{"cveId":"CVE-2025-40162","state":"PUBLISHED","datePublished":"2025-11-12T10:26:22.883Z","dateUpdated":"2026-05-11T21:43:56.425Z","assignerShortName":"Linux","assignerOrgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateReserved":"2025-04-16T07:20:57.176Z"},"containers":{"cna":{"title":"ASoC: amd/sdw_utils: avoid NULL deref when devm_kasprintf() fails","descriptions":[{"lang":"en","value":"In the Linux kernel, the following vulnerability has been resolved:\n\nASoC: amd/sdw_utils: avoid NULL deref when devm_kasprintf() fails\n\ndevm_kasprintf() may return NULL on memory allocation failure,\nbut the debug message prints cpus->dai_name before checking it.\nMove the dev_dbg() call after the NULL check to prevent potential\nNULL pointer dereference."}],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"cb8ea62e6402067ba092d4c1d66a9440513a572b","status":"affected","lessThan":"095d692e5997ece300c89f10d903d5230090e6a0","versionType":"git"},{"version":"cb8ea62e6402067ba092d4c1d66a9440513a572b","status":"affected","lessThan":"a1cccbd19676fc36854535a7118ba2c27d0b84b3","versionType":"git"},{"version":"cb8ea62e6402067ba092d4c1d66a9440513a572b","status":"affected","lessThan":"5726b68473f7153a7f6294185e5998b7e2a230a2","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["sound/soc/amd/acp/acp-sdw-sof-mach.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"6.12","status":"affected"},{"version":"0","status":"unaffected","lessThan":"6.12","versionType":"semver"},{"version":"6.12.55","status":"unaffected","lessThanOrEqual":"6.12.*","versionType":"semver"},{"version":"6.17.5","status":"unaffected","lessThanOrEqual":"6.17.*","versionType":"semver"},{"version":"6.18","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["sound/soc/amd/acp/acp-sdw-sof-mach.c"]}],"references":[{"url":"https://git.kernel.org/stable/c/095d692e5997ece300c89f10d903d5230090e6a0"},{"url":"https://git.kernel.org/stable/c/a1cccbd19676fc36854535a7118ba2c27d0b84b3"},{"url":"https://git.kernel.org/stable/c/5726b68473f7153a7f6294185e5998b7e2a230a2"}],"providerMetadata":{"shortName":"Linux","orgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateUpdated":"2026-05-11T21:43:56.425Z"},"cpeApplicability":[{"nodes":[{"operator":"OR","negate":false,"cpeMatch":[{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.12","versionEndExcluding":"6.12.55"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.12","versionEndExcluding":"6.17.5"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.12","versionEndExcluding":"6.18"}]}]}],"x_generator":{"engine":"bippy-1.2.0"}}}}}