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 3C9E530F927 for ; Tue, 28 Oct 2025 11:54:40 +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=1761652480; cv=none; b=EmVlFFBaUMzqRhsVT7g46yeBwcBxHL8lh8cR7oz5mDX+oR1o0sohr+YETNs3g2i4qvI2MhTh+gYns1YOH0pfLwQDp+rzimrYWQCHUjNZ1lav8Vz0ejz2iZOqU7//QBEplHlu3cmfPpWFr4stj6m8gzWS/k8N546m2ctYx2+wQbU= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1761652480; c=relaxed/simple; bh=mFYk7obInM3TNa78w70AG8iSgqKrceXhLSAiMLeHVys=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=kFIHa6msUDrX41F9NbQKSe7P4kPmbyRPvK5JlvIV6o2x3Y9p9yGwR4kCNIsL1NXjavYUqflG3rVg0Gbe6Ff+S3zQeJ4SRn0XVb1HIYE5PiapqY7RftXV62+3ro1QJ6io68U11Ug5+VkXOj+kNiUjjB5/ZSK9mb1on4poK5nHNRQ= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=0SowOfcl; 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="0SowOfcl" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 5408CC4CEE7; Tue, 28 Oct 2025 11:54:38 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1761652480; bh=mFYk7obInM3TNa78w70AG8iSgqKrceXhLSAiMLeHVys=; h=From:To:Cc:Subject:Date:Reply-to:From; b=0SowOfclNG1KJkU7xCrvtc93nfqQGDEk4nkEX4sq2k67SbdAx0xYZq763uWmN8ppC hcglX70TJB6BDdXsAkNU8x4i88Lcc4+lyTH278BCLefbGUwgpwlKEzH5GNIfQD93SG a0KQTjb9DkTGz5BzpYxEWy1EBuiXHU+WecH+y7Y4= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2025-40058: iommu/vt-d: Disallow dirty tracking if incoherent page walk Date: Tue, 28 Oct 2025 12:48:35 +0100 Message-ID: <2025102815-CVE-2025-40058-0eba@gregkh> X-Mailer: git-send-email 2.51.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=2755; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=pleBzZt5vC/MWfxn2vA+kDp4Jsz13BbJgwBO3BNhCLk=; b=owGbwMvMwCRo6H6F97bub03G02pJDJkMaxt2v/6S8uNrssnxSWev3w9YoF9VXjd3Tr7Mp0ipr oT7i3/6dMSyMAgyMciKKbJ82cZzdH/FIUUvQ9vTMHNYmUCGMHBxCsBE3KMZFjRv9q87OPWW1KmK 83efTXG8ejf9DC/D/NhnVoGuPkx7Z2d7C8tLTxN4nHDPFwA= 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: iommu/vt-d: Disallow dirty tracking if incoherent page walk Dirty page tracking relies on the IOMMU atomically updating the dirty bit in the paging-structure entry. For this operation to succeed, the paging- structure memory must be coherent between the IOMMU and the CPU. In another word, if the iommu page walk is incoherent, dirty page tracking doesn't work. The Intel VT-d specification, Section 3.10 "Snoop Behavior" states: "Remapping hardware encountering the need to atomically update A/EA/D bits in a paging-structure entry that is not snooped will result in a non- recoverable fault." To prevent an IOMMU from being incorrectly configured for dirty page tracking when it is operating in an incoherent mode, mark SSADS as supported only when both ecap_slads and ecap_smpwc are supported. The Linux kernel CVE team has assigned CVE-2025-40058 to this issue. Affected and fixed versions =========================== Issue introduced in 6.7 with commit f35f22cc760eb2c7034bf53251399685d611e03f and fixed in 6.12.53 with commit ebe16d245a00626bb87163862a1b07daf5475a3e Issue introduced in 6.7 with commit f35f22cc760eb2c7034bf53251399685d611e03f and fixed in 6.17.3 with commit 8d096ce0e87bdc361f0b25d7943543bc53aa0b9e Issue introduced in 6.7 with commit f35f22cc760eb2c7034bf53251399685d611e03f and fixed in 6.18-rc1 with commit 57f55048e564dedd8a4546d018e29d6bbfff0a7e 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-40058 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/iommu/intel/iommu.h 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/ebe16d245a00626bb87163862a1b07daf5475a3e https://git.kernel.org/stable/c/8d096ce0e87bdc361f0b25d7943543bc53aa0b9e https://git.kernel.org/stable/c/57f55048e564dedd8a4546d018e29d6bbfff0a7e