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 5DDA72E542B for ; Tue, 9 Dec 2025 01:31:11 +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=1765243872; cv=none; b=P7hXmeT5E3qm+rAhWtrr7NBQ3kx1ytmE1K/qIMPWDLirD55J1DxHajD/oHtJNCBhWGgilxeBrgY9QiM78uEhAAOjhd3uPtmfzJf7luBGlwSIgck1rwJiqcCTSlo8DC/j0Hphp2ViBVjGFB4lPVUDY8knaaAFCqT9spZXjOYz3C8= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1765243872; c=relaxed/simple; bh=zuzYnwLYLiCXcRVl96Sl71czoPVivjDKcWGWFnUF/VY=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=MnIXVp8b5R4QsTGhPJHh3RmYaTQuKqr0PBuVjmjW0tjlr8ai/pP53vLfEZJb1LnD2Bdl2XoWnF3+grAS2Z25TqvK3cuZojVMvHUMYG/p6sQSbcov/i5FOH5WZ9fg6ulmy2OPqYH0W/a/PoGEqg5hjj2musguTX0BYuDRPyPe2Bk= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=hybmFD5Y; 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="hybmFD5Y" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 48AD6C4CEF1; Tue, 9 Dec 2025 01:31:11 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1765243871; bh=zuzYnwLYLiCXcRVl96Sl71czoPVivjDKcWGWFnUF/VY=; h=From:To:Cc:Subject:Date:Reply-To:From; b=hybmFD5Y4+pJ5CF9+2QJMt6vkER0NDJIHqltGqBInqpdL/9AOciwTfy3Ze3uRDLsH DZOdIKASOoMdZaO4UcYjWIELN/yzYpZdH7z33Fjjnt73cX9wFc27ioQkeZgkMysjF+ lPP7THfQSLr3oWRMIfio+9quNFaYXZb5xmA3qj9I= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2022-50658: cpufreq: qcom: fix memory leak in error path Date: Tue, 9 Dec 2025 10:30:43 +0900 Message-ID: <2025120941-CVE-2022-50658-77b4@gregkh> X-Mailer: git-send-email 2.52.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=2429; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=7gMAAYZcdVuVTy3CfEVc82DlsNaKAs6IYxN7VcYivnI=; b=owGbwMvMwCRo6H6F97bub03G02pJDJnm1Qejaz7U307dKtv5V/lY69ujpi/XnjqwYkdC+S3Om 9dr8w+ldcSyMAgyMciKKbJ82cZzdH/FIUUvQ9vTMHNYmUCGMHBxCsBExLMZ5vA9ObC5jl2/XTLe 7a9b3q/zFhqylxnmCkz79HPyv8+TNy2ZyK86q6NgWoWFHgA= 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: cpufreq: qcom: fix memory leak in error path If for some reason the speedbin length is incorrect, then there is a memory leak in the error path because we never free the speedbin buffer. This commit fixes the error path to always free the speedbin buffer. The Linux kernel CVE team has assigned CVE-2022-50658 to this issue. Affected and fixed versions =========================== Issue introduced in 5.7 with commit a8811ec764f95a04ba82f6f457e28c5e9e36e36b and fixed in 5.10.152 with commit e55feb31df3fc78b880d6e9d4b5853f05c974833 Issue introduced in 5.7 with commit a8811ec764f95a04ba82f6f457e28c5e9e36e36b and fixed in 5.15.76 with commit b5606e3ab1f7cc00d89903f4a11fe57747bb3a68 Issue introduced in 5.7 with commit a8811ec764f95a04ba82f6f457e28c5e9e36e36b and fixed in 6.0.6 with commit b6ea267e0c6bdf5463358e2a2e5280cfa6cacc48 Issue introduced in 5.7 with commit a8811ec764f95a04ba82f6f457e28c5e9e36e36b and fixed in 6.1 with commit 9f42cf54403a42cb092636804d2628d8ecf71e75 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-50658 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/cpufreq/qcom-cpufreq-nvmem.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/e55feb31df3fc78b880d6e9d4b5853f05c974833 https://git.kernel.org/stable/c/b5606e3ab1f7cc00d89903f4a11fe57747bb3a68 https://git.kernel.org/stable/c/b6ea267e0c6bdf5463358e2a2e5280cfa6cacc48 https://git.kernel.org/stable/c/9f42cf54403a42cb092636804d2628d8ecf71e75