From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-alma10-1.taild15c8.ts.net [100.103.45.18]) (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 EAE5B35C68D for ; Sat, 15 Aug 2026 06:16:49 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=100.103.45.18 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1786774611; cv=none; b=ZieuwfJBNnbLZax5LzCygLZt/R4+NFIRACGKKpRYP2qK1Vol7Zy4kvO7EhbE5eWZH2CNn9Jtpzn5kyPqeK5PaDBkejDPv0FDhnZi+GEiSoIiqcgF4o3RszNCkcbNezfkFb40XV2ZuRaM3IhPumsHrFLM/8QHbaKm/afh/KNNM0w= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1786774611; c=relaxed/simple; bh=KK4jQpR1KogFHqXnGgd7/rdRhd6in79TAWAVu+nAKdQ=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=cy0xpajfUaCs3c5BQCR0Fm4ctVF+poKfyYhc4MOKVNgRqGVpKtFuthSmxGyl76mdsIjB0LmOLXmsL2OO4ar6QKB3kAmb0orwWwUcdxbSb3x7ngKgcxn5ra2X38xhxgVEETmTYQ3bqskcp47N2xB/8Rby7zZ9xk7YFJA1cvYAx/w= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=mg/BCctp; arc=none smtp.client-ip=100.103.45.18 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="mg/BCctp" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 4F2851F000E9; Sat, 15 Aug 2026 06:16:49 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linuxfoundation.org; s=korg; t=1786774609; bh=Y1fkwbFUd3R2E/ZD4cZ4DrLWgRrQIoKb9Zx7PT1ad7Q=; h=From:To:Cc:Subject:Date:Reply-To; b=mg/BCctpg6I6hjsyCe6dhA05xqIhLFkV5mebGuYQEu9XRNk9pa5Sbl0WaE/eqPTtq 9P+FIdiLuRDHGUvGS79Soq99MAoG4VINrcK+5c0SXX0C3/bmXa9c2RyTwRxpOzaJby Idz5aPSIb9rQoce5+hcl+msl4+dE4fBCC8N0RK+o= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2026-72175: fs/proc/task_mmu: fix make_uffd_wp_huge_pte() prot-update race Date: Sat, 15 Aug 2026 15:04:14 +0900 Message-ID: <2026081538-CVE-2026-72175-37d8@gregkh> X-Mailer: git-send-email 2.55.0 Reply-To: , Precedence: bulk X-Mailing-List: linux-cve-announce@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=5080; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=4cMHAYbNdzDzHDMDmK5FELeQ2kPNJtAbma1FH3uoSb8=; b=owGbwMvMwCRo6H6F97bub03G02pJDFkNDId0oj8t7JW7s7HvvBRfzSPlLOGQvMOcPMLrPyZvq LtndlSyI5aFQZCJQVZMkeXLNp6j+ysOKXoZ2p6GmcPKBDKEgYtTACYyz51hfrjF7aM8B2rMPuxj npc6o11Z8M+XaIZ5mu8br078zCGhK1gcnON7eaKvzq4DAA== 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: fs/proc/task_mmu: fix make_uffd_wp_huge_pte() prot-update race Patch series "userfaultfd/pagemap: pre-existing fixes". These are pre-existing bug fixes that were carried at the front of the userfaultfd RWP working-set-tracking series up to v5 [1]. Per review feedback that fixes should not sit in the middle of a feature series, they are split out and sent on their own; the RWP series is reposted rebased on top of this. All six were flagged by the Sashiko AI review of the RWP series and carry independent of RWP, apply to mm-new directly, and carry Cc: stable@. 1: fs/proc/task_mmu: a missing huge_ptep_modify_prot_start() in make_uffd_wp_huge_pte() can lose hardware Dirty/Accessed updates when PAGEMAP_SCAN write-protects a hugetlb PTE. 2: fs/proc/task_mmu: pagemap_scan_hugetlb_entry() compares the range against HPAGE_SIZE rather than the hstate page size, so it never write-protects gigantic hugetlb pages. 3: fs/proc/task_mmu: PAGEMAP_SCAN with PM_SCAN_WP_MATCHING over an unpopulated hugetlb range self-deadlocks -- pagemap_scan_pte_hole() calls uffd_wp_range() while walk_hugetlb_range() holds the hugetlb vma lock for read, and hugetlb_change_protection() then takes it for write. Install the marker inline instead. 4: mm/huge_memory: change_non_present_huge_pmd() drops pmd_swp_uffd_wp on a device-private PMD permission downgrade, silently losing the uffd-wp marker. 5: userfaultfd: must_wait() applies pte_write() to a locklessly read PTE without checking pte_present(), so swap/migration entries decode random offset bits and a thread can stay parked on a stale fault. 6: userfaultfd: __VMA_UFFD_FLAGS feeds VMA_UFFD_MINOR_BIT (41) to mk_vma_flags() unconditionally, an out-of-bounds write into the single-word vma_flags_t on 32-bit. Build the mask from config-gated per-mode masks so an unavailable bit is never materialised. This patch (of 6): make_uffd_wp_huge_pte() arms the UFFD_WP bit on a present HugeTLB PTE by calling huge_ptep_modify_prot_commit() with a ptent snapshot that was fetched without the corresponding huge_ptep_modify_prot_start(). The start helper is what atomically clears the entry so the kernel-owned snapshot stays consistent until the commit; without it, the hardware may set Dirty or Accessed in the live PTE between the original read and the commit, and huge_ptep_modify_prot_commit() (whose generic implementation just calls set_huge_pte_at()) then writes the stale snapshot back over the live hardware bits, losing the update. The non-hugetlb sibling make_uffd_wp_pte() does this correctly via ptep_modify_prot_start() / ptep_modify_prot_commit(). Mirror that pattern for the present-PTE branch. The migration case stays as-is -- migration entries are non-present, so there's no hardware update to race against. The Linux kernel CVE team has assigned CVE-2026-72175 to this issue. Affected and fixed versions =========================== Issue introduced in 6.7 with commit 52526ca7fdb905a768a93f8faa418e9b988fc34b and fixed in 6.12.101 with commit 50a25249a6355db74c2c1b6be541b4caab9f3655 Issue introduced in 6.7 with commit 52526ca7fdb905a768a93f8faa418e9b988fc34b and fixed in 6.18.42 with commit 8e39ed92d7c5c6bfc08dc45153916f49a4e98bab Issue introduced in 6.7 with commit 52526ca7fdb905a768a93f8faa418e9b988fc34b and fixed in 7.1.5 with commit 6b7f774b8882445d9174681747d37c42548686a4 Issue introduced in 6.7 with commit 52526ca7fdb905a768a93f8faa418e9b988fc34b and fixed in 7.2-rc1 with commit 04718f7c9290f95385f0dd328758753dc1c36dec 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-2026-72175 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: fs/proc/task_mmu.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/50a25249a6355db74c2c1b6be541b4caab9f3655 https://git.kernel.org/stable/c/8e39ed92d7c5c6bfc08dc45153916f49a4e98bab https://git.kernel.org/stable/c/6b7f774b8882445d9174681747d37c42548686a4 https://git.kernel.org/stable/c/04718f7c9290f95385f0dd328758753dc1c36dec