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 E076221765F for ; Wed, 26 Feb 2025 02:00:28 +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=1740535228; cv=none; b=oNhcRr4EHSY83RHJX8WSoJndiAqgqNhWVKCXzB0pHS/a4UxFRHmXcnqsV2vyehpgZ1K4CYNPO4LSUNQBCMMZ8jciFJnrVPpvL6oaZ/3a4KQFoRQGO6iIHnUH9RPj2R2tS4HaC//yX72rO64TLaj+82Vdkj520wwfvNpdJfWricM= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1740535228; c=relaxed/simple; bh=Kyru6coEsRnED4IOG9SeM+Sfbqovbt0CsKqkQqtf2mo=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=GRR56LvF3DQAAFSPfbjDX7N6SkH1GfsyUUgcWNJE6ivMZNLH8TvxbqKzm/uyvWgV2jFpdWGpxfK+K840MsqeWcKuLs6ZXLjmjtbXL3r7UZ5UAAoO5QQi7iDVcbDK+4mB1b3hMVDiAdYzQb2k92eSLBfYZCQLGWFKwccRqfY8dgw= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=FLHP2qhE; 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="FLHP2qhE" Received: by smtp.kernel.org (Postfix) with ESMTPSA id B59E5C4CEDD; Wed, 26 Feb 2025 02:00:28 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1740535228; bh=Kyru6coEsRnED4IOG9SeM+Sfbqovbt0CsKqkQqtf2mo=; h=From:To:Cc:Subject:Date:Reply-to:From; b=FLHP2qhElnEbjf1eCh+PeE6cZkKRF5t+Oj+k9hVcqPv/yI++xHBEXyX+GablvvQo6 zeIObBPk2pOb9i+pvCvQ+H+QtMJVgosiT0+3MC8FruanreIKAUEPenZBAQvONZ5S+4 2kfOnS0BGiPFdwekM9DtqZdatwmYU84iAEtvZQaA= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2022-49284: coresight: syscfg: Fix memleak on registration failure in cscfg_create_device Date: Wed, 26 Feb 2025 02:58:09 +0100 Message-ID: <2025022632-CVE-2022-49284-f545@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=2545; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=Kyru6coEsRnED4IOG9SeM+Sfbqovbt0CsKqkQqtf2mo=; b=owGbwMvMwCRo6H6F97bub03G02pJDOn7SiJ8q16aXWZzCeoIMvbIeCFsd0xRL+zblyPOAod0J 0z8t82wI5aFQZCJQVZMkeXLNp6j+ysOKXoZ2p6GmcPKBDKEgYtTACbCfpNhvt9Kx7RIgybxyHnv TPK+b83bum2mCMOCab7voq/+TD3m+/t6xzTJDRl7WpeGAwA= 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: coresight: syscfg: Fix memleak on registration failure in cscfg_create_device device_register() calls device_initialize(), according to doc of device_initialize: Use put_device() to give up your reference instead of freeing * @dev directly once you have called this function. To prevent potential memleak, use put_device() for error handling. The Linux kernel CVE team has assigned CVE-2022-49284 to this issue. Affected and fixed versions =========================== Issue introduced in 5.15 with commit 85e2414c518a03a21dddd4bc88fec2723c5e1197 and fixed in 5.15.33 with commit c61e2fc87f24cae4701f352fe9ecd4c5c143106c Issue introduced in 5.15 with commit 85e2414c518a03a21dddd4bc88fec2723c5e1197 and fixed in 5.16.19 with commit a529af1f5a5c096f3e18f0d5a32cfcc3d82df1ec Issue introduced in 5.15 with commit 85e2414c518a03a21dddd4bc88fec2723c5e1197 and fixed in 5.17.2 with commit 412225b32986d5b11c3c1ad9234c50a3f5c52c76 Issue introduced in 5.15 with commit 85e2414c518a03a21dddd4bc88fec2723c5e1197 and fixed in 5.18 with commit cfa5dbcdd7aece76f3415284569f2f384aff0253 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-49284 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/hwtracing/coresight/coresight-syscfg.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/c61e2fc87f24cae4701f352fe9ecd4c5c143106c https://git.kernel.org/stable/c/a529af1f5a5c096f3e18f0d5a32cfcc3d82df1ec https://git.kernel.org/stable/c/412225b32986d5b11c3c1ad9234c50a3f5c52c76 https://git.kernel.org/stable/c/cfa5dbcdd7aece76f3415284569f2f384aff0253