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 ECD9D305058 for ; Wed, 12 Nov 2025 10:54: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=1762944846; cv=none; b=oCp5B2IzfsS0hLUot4KBH0pw6G3QdsPV5KWG9joMHVjg3MUPTvSr3VWQagsqqgG6PDj4YFTOam4FdHqeduNBCB6J0Pum5ecSssP9ijYhds+YKVZjgR8OgZ1sUqo2751IOhuTUXEqnsQi03NKwsfFrxGfPleMOO0kD++4dKwYW3A= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1762944846; c=relaxed/simple; bh=ypu1AbHgEV9OyKCqVrLzut7WjmZP9mxC0zexgFgnuKQ=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=P6DMNkLSQaWxiyaPnomLEDk71wqT0ueJhbQe4l4Z54hbZg6tCjjl5A7PjTzjhyJ9JjBXAL8OpeUokX2PQK1zPq3JgLCVHrGQP/fa8EKAbWLtNFD1kQpgTQbPn2e6mL8hKfnMN1zWXB5HSwOBBmS1laDb1Ifd5tb49pKv66bUDV4= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=VjjSHi4i; 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="VjjSHi4i" Received: by smtp.kernel.org (Postfix) with ESMTPSA id AB7D5C19423; Wed, 12 Nov 2025 10:54:05 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1762944845; bh=ypu1AbHgEV9OyKCqVrLzut7WjmZP9mxC0zexgFgnuKQ=; h=From:To:Cc:Subject:Date:Reply-to:From; b=VjjSHi4iny32QpNSKcNSKdte5/MUGvfBftBinpfLjnCXvH9wTFzRD2AQbV6BPbZgV i6Np8H40k5Jp0ywM8Uyu7MlyHpbwrpCRxzojxI12tgc/cwWHS948heljCUtvPiFNwZ aEV2SJYiWrmwlGSqxvZ0SnUhPl2TDSMhZ4Uh12BA= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2025-40174: x86/mm: Fix SMP ordering in switch_mm_irqs_off() Date: Wed, 12 Nov 2025 05:53:57 -0500 Message-ID: <2025111255-CVE-2025-40174-b076@gregkh> X-Mailer: git-send-email 2.51.2 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=2102; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=vQbJpgGRWI7a7ybmDW9tCKYhjqogLQHVrlWh3+fANu0=; b=owGbwMvMwCRo6H6F97bub03G02pJDJki6c7eoTx7ph3dtuhQ0p1QFss3F1M9K6X2OzDurpvNk KIvn/OmI5aFQZCJQVZMkeXLNp6j+ysOKXoZ2p6GmcPKBDKEgYtTACZycAvDfG8Wtv/vvwhcPrpm yh/95sV6pxaUrGFYsG/FBMmmYwfaTk8r3KHv9+gLg1HUAwA= 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: x86/mm: Fix SMP ordering in switch_mm_irqs_off() Stephen noted that it is possible to not have an smp_mb() between the loaded_mm store and the tlb_gen load in switch_mm(), meaning the ordering against flush_tlb_mm_range() goes out the window, and it becomes possible for switch_mm() to not observe a recent tlb_gen update and fail to flush the TLBs. [ dhansen: merge conflict fixed by Ingo ] The Linux kernel CVE team has assigned CVE-2025-40174 to this issue. Affected and fixed versions =========================== Issue introduced in 6.14 with commit 209954cbc7d0ce1a190fc725d20ce303d74d2680 and fixed in 6.17.5 with commit 0fe5e3f5fb75c5d88dad24dece3ee75e9d87adeb Issue introduced in 6.14 with commit 209954cbc7d0ce1a190fc725d20ce303d74d2680 and fixed in 6.18-rc2 with commit 83b0177a6c4889b3a6e865da5e21b2c9d97d0551 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-40174 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: arch/x86/mm/tlb.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/0fe5e3f5fb75c5d88dad24dece3ee75e9d87adeb https://git.kernel.org/stable/c/83b0177a6c4889b3a6e865da5e21b2c9d97d0551