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 8895E21ADCE for ; Wed, 26 Feb 2025 02:27:44 +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=1740536864; cv=none; b=ku7uf+vaaY7qx1DIEYno0AGfjRqHVMFbFFynCHx3FSPstDwrvij63BhD9UTjAVTV7peYPdWawvj0qko+dU8RzsayQ1/gfCsS5AnaH9wcl6xfU6HoeLVVLLBs8UTiyx/wxXV+AppvLlG7H21hdlr0qyWVPXMep4Q85FIRSRzDZRE= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1740536864; c=relaxed/simple; bh=dLqcDUvUibwG7bU0wR4upplJLnho3u+kTG+IUo+dGu0=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=jYn53fx4sKX4UYzu0oPirXMMA+ApKergw6JWdqbOgslIaEVwYtdu5wTUWhPMDl7inRV+9sJtT2rqiZzbDpych0BUyNdbJpgAMwmawVDoROUdQKQOtoC6NVrv0ckNejdSvoGEpK5jidZnmUJ4X2rDcS2LzymNxPvP4HFOUkXKSiI= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=C53F/npr; 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="C53F/npr" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 53584C4CEDD; Wed, 26 Feb 2025 02:27:44 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1740536864; bh=dLqcDUvUibwG7bU0wR4upplJLnho3u+kTG+IUo+dGu0=; h=From:To:Cc:Subject:Date:Reply-to:From; b=C53F/nprOJKLLBlkIQOUiy57RovzqNul0TxOUI4WdFEiWq8FwxSN2h4cjXnMhoz9J wSA56bh5yr2ivYoyuNawTu2kSju86P0CWpAkT/ZNwjVLQEjxa1ulm7Z1bJoAdgF88O F8254DoNR80ftoGJtyHIST1+95f4se1E6iJ7uepw= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2022-49709: cfi: Fix __cfi_slowpath_diag RCU usage with cpuidle Date: Wed, 26 Feb 2025 03:24:32 +0100 Message-ID: <2025022630-CVE-2022-49709-f834@gregkh> X-Mailer: git-send-email 2.48.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=2611; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=dLqcDUvUibwG7bU0wR4upplJLnho3u+kTG+IUo+dGu0=; b=owGbwMvMwCRo6H6F97bub03G02pJDOn7qp7dfLyp7CUbb4rwAsWJYQ/Fv95Ku7rsQEx9W6iDy armh1zfOmJZGASZGGTFFFm+bOM5ur/ikKKXoe1pmDmsTCBDGLg4BWAi17oY5ntsNJ6Q4y+XqNWh +zPg56daG92OhQzzs1aqPPF8X8KzJXLWFrZ69j6TAx4NAA== X-Developer-Key: i=gregkh@linuxfoundation.org; a=openpgp; fpr=F4B60CC5BF78C2214A313DCB3147D40DDB2DFB29 Content-Transfer-Encoding: 8bit Description =========== In the Linux kernel, the following vulnerability has been resolved: cfi: Fix __cfi_slowpath_diag RCU usage with cpuidle RCU_NONIDLE usage during __cfi_slowpath_diag can result in an invalid RCU state in the cpuidle code path: WARNING: CPU: 1 PID: 0 at kernel/rcu/tree.c:613 rcu_eqs_enter+0xe4/0x138 ... Call trace: rcu_eqs_enter+0xe4/0x138 rcu_idle_enter+0xa8/0x100 cpuidle_enter_state+0x154/0x3a8 cpuidle_enter+0x3c/0x58 do_idle.llvm.6590768638138871020+0x1f4/0x2ec cpu_startup_entry+0x28/0x2c secondary_start_kernel+0x1b8/0x220 __secondary_switched+0x94/0x98 Instead, call rcu_irq_enter/exit to wake up RCU only when needed and disable interrupts for the entire CFI shadow/module check when we do. The Linux kernel CVE team has assigned CVE-2022-49709 to this issue. Affected and fixed versions =========================== Issue introduced in 5.13 with commit cf68fffb66d60d96209446bfc4a15291dc5a5d41 and fixed in 5.15.49 with commit 75f3a5fa2ad049c85ab5d5ee1ed9cfaa7e62c5ed Issue introduced in 5.13 with commit cf68fffb66d60d96209446bfc4a15291dc5a5d41 and fixed in 5.18.6 with commit ca3897f2ac02ceae5e6fa794f83c36f9885b93da Issue introduced in 5.13 with commit cf68fffb66d60d96209446bfc4a15291dc5a5d41 and fixed in 5.19 with commit 57cd6d157eb479f0a8e820fd36b7240845c8a937 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-2022-49709 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: kernel/cfi.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/75f3a5fa2ad049c85ab5d5ee1ed9cfaa7e62c5ed https://git.kernel.org/stable/c/ca3897f2ac02ceae5e6fa794f83c36f9885b93da https://git.kernel.org/stable/c/57cd6d157eb479f0a8e820fd36b7240845c8a937