Received: from smtp.kernel.org (aws-us-west-2-korg-mail-alma10-1.taild15c8.ts.net [100.103.45.18]) (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 3922439E9DE for ; Sun, 19 Jul 2026 14:58:44 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=100.103.45.18 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1784473126; cv=none; b=aerys/QOOZNWQ/n9FqFH78Wst7JMfSJiIFxTN99OQAeJXBk5E/8Ez/RwDIBX5cMKVQJAA7/b2TbrNBwv6TTnLEa8KjduwsiS4TqjlABzZY8kQo9GH5SIYz4JHeQD9tCYsWz6qjGUZMXFP5T9awa7QJ9Cw+mJ56FtR9lLf+cZvgg= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1784473126; c=relaxed/simple; bh=EH6J26LnHBYhn+DY4ydNQY6KNI6MJjJ4WcdawDoqZFI=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=ipHAT594GQdAm45no35xjj8+TjtnlxeDMgbEHn+OxCaZ7uhd2HtJhlvzsoj5x4f51P8Fz272pDJKj+CZekvjdrEmuowkDIuBHWtbf3b6oZQvwWhLxsm/2fEbzE6GBA3SjZTY0AzG/cxAVVTsd1uus+gBqqWyigMcsZDvePNRLF8= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=Vl9TVeuI; arc=none smtp.client-ip=100.103.45.18 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="Vl9TVeuI" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 5101E1F000E9; Sun, 19 Jul 2026 14:58:44 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linuxfoundation.org; s=korg; t=1784473124; bh=Gb5MVfMjyHTw8eSU286wMu7RnKTAKLsPON0rA/KZepw=; h=From:To:Cc:Subject:Date:Reply-To; b=Vl9TVeuIYSj0qVgjcboIub/4MoyNkbJyJ29gPPS4E7Rb7RR7pT8UMlL8hJNef1g6B UM0xgRYHtHGRlX0SMaugZDnRhQ++YAk4uSJnWNZ/vrkNxW+AUIAD4E40lJPmBUOs8k J2GHxsHS7GyjLG/aC2g2XGkracJIIyIFub/+QNww= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2026-63878: drm/amdgpu: check num_entries in GEM_OP GET_MAPPING_INFO Date: Sun, 19 Jul 2026 16:55:38 +0200 Message-ID: <2026071938-CVE-2026-63878-d23a@gregkh> X-Mailer: git-send-email 2.55.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=2625; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=PfHCY16bB5kkoma3DG69sgG96raQtCc1adDrhUfNrYE=; b=owGbwMvMwCRo6H6F97bub03G02pJDFkxT7POvhS9vOD0pJWy1ZPWdv7SO8V0L8zyTmrXV6uri wJm+cxd0RHLwiDIxCArpsjyZRvP0f0VhxS9DG1Pw8xhZQIZwsDFKQAT2S/LMFfyY5hlSp/nb5cN L9i0j0vKbjh11IFhniZjhs21e9FM9Z+ifK4sPbuadWfMQQA= 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: drm/amdgpu: check num_entries in GEM_OP GET_MAPPING_INFO kvcalloc(args->num_entries, sizeof(*vm_entries), GFP_KERNEL) at amdgpu_gem.c:1050 uses the user-supplied num_entries directly without any upper bounds check. Since num_entries is a __u32 and sizeof(drm_amdgpu_gem_vm_entry) is 32 bytes, a large num_entries produces an allocation exceeding INT_MAX, triggering WARNING in __kvmalloc_node_noprof(), causing a kernel WARNING, TAINT_WARN, and panic on CONFIG_PANIC_ON_WARN=y systems. Add a size bounds check before we invoke the kvzalloc() to reject oversized num_entries early with -EINVAL. (cherry picked from commit 1fe7bf5457f6efd7be60b17e23163ba54341d73d) The Linux kernel CVE team has assigned CVE-2026-63878 to this issue. Affected and fixed versions =========================== Issue introduced in 6.18 with commit 4d82724f7f2b847eb0454b1aab5450545b39abd4 and fixed in 6.18.35 with commit f059b4c493df3e54fe3ffe4658009c31864275da Issue introduced in 6.18 with commit 4d82724f7f2b847eb0454b1aab5450545b39abd4 and fixed in 7.0.12 with commit 967a00b8e06a7734aded23861faba9ee2462be87 Issue introduced in 6.18 with commit 4d82724f7f2b847eb0454b1aab5450545b39abd4 and fixed in 7.1 with commit a1ba4594232c87c3b8defd6f89a2e40f8b08395d 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-2026-63878 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/amd/amdgpu/amdgpu_gem.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/f059b4c493df3e54fe3ffe4658009c31864275da https://git.kernel.org/stable/c/967a00b8e06a7734aded23861faba9ee2462be87 https://git.kernel.org/stable/c/a1ba4594232c87c3b8defd6f89a2e40f8b08395d