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 C16AA481A3 for ; Wed, 1 May 2024 05:31:50 +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=1714541510; cv=none; b=fBBJt785H/bx4TBHX5lROD8pxUinD1G29PW3hsaWNLwoHf6LJpVa9XqK0ccafOAYWrtUpA4ss0t/7FgkVq6U2iKGeTKo1C+XNBW0g8kLPfMbQ2E2XMCv6+m6ppBp47+A1S7HuPN1Jz5nl/69FwKPpAJFCbXrNbJaf2WTPk1OpBg= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1714541510; c=relaxed/simple; bh=Aqn91OE2YNKj9ecgxHG0JdC5YXhjnMOtoHsEDExUvR0=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=PXiQ6wQdd4kwy9Rw1cfXbsQQ+0cc3lrCQlcFeDBx5o1FI2PR1UXjrQGetPMilELyOYHt9gvE3zeQsV525HGCickAEust0h0ivFgBldOu82EgWsd6C/0CVgytqh6gEOd60+th1fMXaYjsWhEmTPmrkqlQIN7mbBG5T3N71r+8dbE= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=2jEqdULX; 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="2jEqdULX" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 48C7DC113CC; Wed, 1 May 2024 05:31:50 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1714541510; bh=Aqn91OE2YNKj9ecgxHG0JdC5YXhjnMOtoHsEDExUvR0=; h=From:To:Cc:Subject:Date:Reply-to:From; b=2jEqdULXZ8GKzLpIcBGAZTisqqSQklGLuqOzAmM8FFbnEHvDt/a2rWDCHppCuvySB cMxx5aRS/p1fuGsubZYXlcUT95KThy0Lm7tdmSOEHafzRd9964no1owp0uY8hYQNKa LQflSYxWjvw8IbYUb3zkNasfGhP3Nfvre7mhaDBU= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2024-27003: clk: Get runtime PM before walking tree for clk_summary Date: Wed, 1 May 2024 07:31:04 +0200 Message-ID: <2024050146-CVE-2024-27003-c862@gregkh> X-Mailer: git-send-email 2.44.0 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=2641; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=Aqn91OE2YNKj9ecgxHG0JdC5YXhjnMOtoHsEDExUvR0=; b=owGbwMvMwCRo6H6F97bub03G02pJDGmGl9seN7xxXKsUufzJ18kHAvosr0l0rEhxZHX7PbeJW URK3E+5I5aFQZCJQVZMkeXLNp6j+ysOKXoZ2p6GmcPKBDKEgYtTACZS6cSwYP7ieduW7u/IyC6L ecKooSp6/Uz4O4Z5xhw3eTeGTiko0xSeMP/D58wP5kc7AA== 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: clk: Get runtime PM before walking tree for clk_summary Similar to the previous commit, we should make sure that all devices are runtime resumed before printing the clk_summary through debugfs. Failure to do so would result in a deadlock if the thread is resuming a device to print clk state and that device is also runtime resuming in another thread, e.g the screen is turning on and the display driver is starting up. We remove the calls to clk_pm_runtime_{get,put}() in this path because they're superfluous now that we know the devices are runtime resumed. This also squashes a bug where the return value of clk_pm_runtime_get() wasn't checked, leading to an RPM count underflow on error paths. The Linux kernel CVE team has assigned CVE-2024-27003 to this issue. Affected and fixed versions =========================== Issue introduced in 5.17 with commit 1bb294a7981c and fixed in 6.1.88 with commit 83ada89e4a86 Issue introduced in 5.17 with commit 1bb294a7981c and fixed in 6.6.29 with commit 2c077fdfd09d Issue introduced in 5.17 with commit 1bb294a7981c and fixed in 6.8.8 with commit b457105309d3 Issue introduced in 5.17 with commit 1bb294a7981c and fixed in 6.9-rc5 with commit 9d1e795f754d 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-2024-27003 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/clk/clk.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/83ada89e4a86e2b28ea2b5113c76d6dc7560a4d0 https://git.kernel.org/stable/c/2c077fdfd09dffb31a890e5095c8ab205138a42e https://git.kernel.org/stable/c/b457105309d388e4081c716cf7b81d517ff74db4 https://git.kernel.org/stable/c/9d1e795f754db1ac3344528b7af0b17b8146f321