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 409BD197 for ; Fri, 21 Jun 2024 10:24:22 +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=1718965462; cv=none; b=L+kRyeUJhH+wadMiCSpWcHHJjK6vBqlRSqa+waMRRSuHFANQhUL9BaEGjmvWo66D7zHAkzmab3Ra7D2t4JnXxqFYuoifv82fW1bi0wg+4cMvOg1cjUi76vOR28bQ6SgcmCNnGwLVSwIrCfU1Eac5YgDJ6QIVf/v4K28QYR3gCQM= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1718965462; c=relaxed/simple; bh=cYqBWDRd+kM62JOcBKgO4cRqCeaPQleRTVVifkiIYW4=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=XUWToSts4Sprh9LcDbVxSRfci6JXY1eVYd5ndk2/HIuHvNSaw6/43tXry7IDH+gMKVoTsJzkckdRqkRn2YHZtc9JS1tB5aQ/wbDNWepfQvGeGYa+Vm41eFhRKc/lD3kIw0MsY2BBqWqhCWyG8yuxo8iuyOKEm4yfR+SXWO6gXKs= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=LVXXfqRf; 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="LVXXfqRf" Received: by smtp.kernel.org (Postfix) with ESMTPSA id B0519C2BBFC; Fri, 21 Jun 2024 10:24:21 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1718965462; bh=cYqBWDRd+kM62JOcBKgO4cRqCeaPQleRTVVifkiIYW4=; h=From:To:Cc:Subject:Date:Reply-to:From; b=LVXXfqRfyI4iOnLQDOl5jOzfKWK71v2ksfxUJeUeTsAQGAr2pn5UHDvWXtoBB0bMB iLUjFAnUeCK2O8xz+wx3rsI/kCVYv9SwKlOV4jSVuiN0YYxu6ZvIJH36JHJqhLiI35 wogF55UqeauECy7qE/J8zzvuEmCQM8IUm5jzqFck= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2024-38390: drm/msm/a6xx: Avoid a nullptr dereference when speedbin setting fails Date: Fri, 21 Jun 2024 12:19:45 +0200 Message-ID: <2024062138-CVE-2024-38390-395e@gregkh> X-Mailer: git-send-email 2.45.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=2520; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=cYqBWDRd+kM62JOcBKgO4cRqCeaPQleRTVVifkiIYW4=; b=owGbwMvMwCRo6H6F97bub03G02pJDGmlwbteOQsX6x6xj7611Tow9FjZIT3JKr2AMx71j0XjZ T+l74/qiGVhEGRikBVTZPmyjefo/opDil6Gtqdh5rAygQxh4OIUgIl4zGCYKzxlwTa3y9JHDvyT D27bv6hf3GlhNcN8p2vzdVnqnk/IZVjyt8jJKkz0yaGNAA== 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: drm/msm/a6xx: Avoid a nullptr dereference when speedbin setting fails Calling a6xx_destroy() before adreno_gpu_init() leads to a null pointer dereference on: msm_gpu_cleanup() : platform_set_drvdata(gpu->pdev, NULL); as gpu->pdev is only assigned in: a6xx_gpu_init() |_ adreno_gpu_init |_ msm_gpu_init() Instead of relying on handwavy null checks down the cleanup chain, explicitly de-allocate the LLC data and free a6xx_gpu instead. Patchwork: https://patchwork.freedesktop.org/patch/588919/ The Linux kernel CVE team has assigned CVE-2024-38390 to this issue. Affected and fixed versions =========================== Issue introduced in 6.1 with commit 76efc2453d0e and fixed in 6.1.93 with commit 247849eeb3fd Issue introduced in 6.1 with commit 76efc2453d0e and fixed in 6.6.33 with commit a1955a6df913 Issue introduced in 6.1 with commit 76efc2453d0e and fixed in 6.9.4 with commit 617e3d168050 Issue introduced in 6.1 with commit 76efc2453d0e and fixed in 6.10-rc1 with commit 46d4efcccc68 Issue introduced in 6.0.10 with commit 5fea4202b5fa 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-38390 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/gpu/drm/msm/adreno/a6xx_gpu.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/247849eeb3fd88f8990ed73e33af70d5c10f9aec https://git.kernel.org/stable/c/a1955a6df91355fef72a3a254700acd3cc1fec0d https://git.kernel.org/stable/c/617e3d1680504a3f9d88e1582892c68be155498f https://git.kernel.org/stable/c/46d4efcccc688cbacdd70a238bedca510acaa8e4