Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id AF9EC2ECEA9 for ; Fri, 25 Jul 2025 12:57:05 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1753448225; cv=none; b=hl1pwKr1Jtx0ZmC10QBBK2xjHyb+kcNC58qB2ni8BywbMIOYjsyGKAqhpIGV8oLNquO5nWe4oFekE+y3UR6kEhth083a7/GpCeQcFEFfGteFWuSzE6UC3AjMR+qfLfLPJwX3qGyR5xN8aaZ76EzhTbiqPKx5vX2PQWhY5OcVoXw= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1753448225; c=relaxed/simple; bh=HPIkoyDSLtqcrWZU5Kr6zSr/UK7fL1QMRNOCcf8KcmY=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=jE6s1ajv9K+1RAE+ktPILFxCloGapStqhdrZGF/QFhYauROgo3wPn+nvyhcrpsRdWOXBX4w5xtJEghA2m7FVDfQFBMx61FywLc3KWPlQsDWk1cV3Ts0dgRCyI3f4wK8z0aW+XgMeKzkK6Py0SkLITJAyg6EOPmjck2q4GlW03rQ= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=HZ+t2Zwh; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="HZ+t2Zwh" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 226EEC4CEE7; Fri, 25 Jul 2025 12:57:04 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1753448225; bh=HPIkoyDSLtqcrWZU5Kr6zSr/UK7fL1QMRNOCcf8KcmY=; h=From:To:Cc:Subject:Date:Reply-to:From; b=HZ+t2ZwhpJurtJe6CKOAAqS3XWUMLBfJZek16myIcUwRjZGMxyT3sYLy8tUNC+NgR hfUkkWYjUonGaFe6wrHy6V5A1GChNFM5odIIFtE8ELSsJ9Dlz4E0HdpofVGZ5OIeSf 35awt/sJtioG2z/Ig/LdN5ty2ssperooNXGPYRqo= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2025-38401: mtk-sd: Prevent memory corruption from DMA map failure Date: Fri, 25 Jul 2025 14:55:32 +0200 Message-ID: <2025072510-CVE-2025-38401-789b@gregkh> X-Mailer: git-send-email 2.50.1 Precedence: bulk X-Mailing-List: linux-cve-announce@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Reply-to: , X-Developer-Signature: v=1; a=openpgp-sha256; l=3436; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=ajktX2YoeJlDj7sT4r/yqm084JRvwihnZztT+3QdOp0=; b=owGbwMvMwCRo6H6F97bub03G02pJDBnNdes/1N+ukw3yKAj698dj6ZPXlzt6dt+MTr0uZ9S46 anGq6fKHbEsDIJMDLJiiixftvEc3V9xSNHL0PY0zBxWJpAhDFycAjCR4oMMc0U+hB94GX1i1dGN thV879Oi2uTXuDEsOHe2Pk/K69v80rlvJaJXMDUcW+T6GAA= X-Developer-Key: i=gregkh@linuxfoundation.org; a=openpgp; fpr=F4B60CC5BF78C2214A313DCB3147D40DDB2DFB29 Content-Transfer-Encoding: 8bit From: Greg Kroah-Hartman Description =========== In the Linux kernel, the following vulnerability has been resolved: mtk-sd: Prevent memory corruption from DMA map failure If msdc_prepare_data() fails to map the DMA region, the request is not prepared for data receiving, but msdc_start_data() proceeds the DMA with previous setting. Since this will lead a memory corruption, we have to stop the request operation soon after the msdc_prepare_data() fails to prepare it. The Linux kernel CVE team has assigned CVE-2025-38401 to this issue. Affected and fixed versions =========================== Issue introduced in 4.2 with commit 208489032bdd8d4a7de50f3057c175058f271956 and fixed in 5.4.296 with commit 5ac9e9e2e9cd6247d8c2d99780eae4556049e1cc Issue introduced in 4.2 with commit 208489032bdd8d4a7de50f3057c175058f271956 and fixed in 5.10.240 with commit d54771571f74a82c59830a32e76af78a8e57ac69 Issue introduced in 4.2 with commit 208489032bdd8d4a7de50f3057c175058f271956 and fixed in 5.15.187 with commit 48bf4f3dfcdab02b22581d8e350a2d23130b72c0 Issue introduced in 4.2 with commit 208489032bdd8d4a7de50f3057c175058f271956 and fixed in 6.1.144 with commit 63e8953f16acdcb23e2d4dd8a566d3c34df3e200 Issue introduced in 4.2 with commit 208489032bdd8d4a7de50f3057c175058f271956 and fixed in 6.6.97 with commit 61cdd663564674ea21ceb50aa9d3697cbe9e45f9 Issue introduced in 4.2 with commit 208489032bdd8d4a7de50f3057c175058f271956 and fixed in 6.12.37 with commit 3419bc6a7b65cbbb91417bb9970208478e034c79 Issue introduced in 4.2 with commit 208489032bdd8d4a7de50f3057c175058f271956 and fixed in 6.15.6 with commit a5f5f67b284d81776d4a3eb1f8607e4b7f91f11c Issue introduced in 4.2 with commit 208489032bdd8d4a7de50f3057c175058f271956 and fixed in 6.16-rc5 with commit f5de469990f19569627ea0dd56536ff5a13beaa3 Please see https://www.kernel.org for a full list of currently supported kernel versions by the kernel community. Unaffected versions might change over time as fixes are backported to older supported kernel versions. The official CVE entry at https://cve.org/CVERecord/?id=CVE-2025-38401 will be updated if fixes are backported, please check that for the most up to date information about this issue. Affected files ============== The file(s) affected by this issue are: drivers/mmc/host/mtk-sd.c Mitigation ========== The Linux kernel CVE team recommends that you update to the latest stable kernel version for this, and many other bugfixes. Individual changes are never tested alone, but rather are part of a larger kernel release. Cherry-picking individual commits is not recommended or supported by the Linux kernel community at all. If however, updating to the latest release is impossible, the individual changes to resolve this issue can be found at these commits: https://git.kernel.org/stable/c/5ac9e9e2e9cd6247d8c2d99780eae4556049e1cc https://git.kernel.org/stable/c/d54771571f74a82c59830a32e76af78a8e57ac69 https://git.kernel.org/stable/c/48bf4f3dfcdab02b22581d8e350a2d23130b72c0 https://git.kernel.org/stable/c/63e8953f16acdcb23e2d4dd8a566d3c34df3e200 https://git.kernel.org/stable/c/61cdd663564674ea21ceb50aa9d3697cbe9e45f9 https://git.kernel.org/stable/c/3419bc6a7b65cbbb91417bb9970208478e034c79 https://git.kernel.org/stable/c/a5f5f67b284d81776d4a3eb1f8607e4b7f91f11c https://git.kernel.org/stable/c/f5de469990f19569627ea0dd56536ff5a13beaa3