Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=100.103.45.18 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1795154374; b=LUZi9DBR32MAtBjEVIHJxjjhLoJqnIsLqB7q0A7+I3hEZ0XCXG/TukhXD21+uFzD2vh1 DqN+QrNJR91AYXUxQuH1zMd63fTMoQB/bP5VGSaGMQMnKATMVzOgs65xoKX6psNp+IZiF Tlx4cGvGbgbF5O00ltoF9YbGi3WIsF8ignnvlJ7y5WjZUsR36LG4VgGiEr2cbn4yzEF8q CKKsv0Z9yyn+5fe+UZeP4vAjKLo6tLYPQza+SeidIPt6tAovzMRsUldPhZwMsBY4/e9dn 8AfWzlKLEYVRvaoF7jI9f+vlpEqQv86sGETXcsW2L8hlB6QksmDnntFb0cfmSZTJryg== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1795154374; h=Received:DKIM-Signature:From:To:Cc:Subject:Date:Message-ID:X-Mailer: Reply-To:MIME-Version:Lines:X-Developer-Signature:X-Developer-Key: Content-Transfer-Encoding; bh=4SNr93ZlaJqciVbG4IFd5LK0IHJJNvvQqj8vfW9IoOQ=; b=kNrv1Zd/Pj680hYT/e9J5M5seUP3o853bIJnn5EbjE9fhSJn5SfOoc88xAlO3pUjhFqn MymIP2HFjFwjhM++rl5X5Y2mRhOk6PajhEWQxHnAN+dkxgCi200OsVZQc1cGMWfk5o/9E GHYPC82YVVFJm5iMeOgck4JdoSBLi5PSSYq3KyOo3hfhwNOVt5kSyum35/w7huw7zk/a4 clJhyCIC5hiovbxtc9vC/uD1cQWP6iWTpnF2oyEkdApu4vQA+0bfQPYzJo/P9AsjhyJBP GaZYp7ZgCU5lgX4vgtOImb7XsJAQt7QKXHUac1cEepBNw1YPpzZtorNdEzkpv9TFTAw== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass header.d=linuxfoundation.org header.i=@linuxfoundation.org header.a=rsa-sha256 header.s=korg header.b=QGILzMEz; arc=none smtp.remote-ip=100.103.45.18 Received: from smtp.kernel.org (quasi.space.kernel.org [100.103.45.18]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 8C33D606A50B for ; Fri, 20 Nov 2026 05:59:34 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.a=rsa-sha256 header.s=korg header.b=QGILzMEz Received: by smtp.kernel.org (Postfix) with ESMTPSA id DC7361F000CA; Fri, 20 Nov 2026 05:59:33 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linuxfoundation.org; s=korg; t=1795154374; bh=4SNr93ZlaJqciVbG4IFd5LK0IHJJNvvQqj8vfW9IoOQ=; h=From:To:Cc:Subject:Date:Reply-To; b=QGILzMEz+hhNShLSLz9qmsAk8M8KB5Xdn+DoXM6Nx+dPPeZfm7fA6HP/xU/dP4zDi lA4T0EajKvSxvl4bL9x7N2we+kF9Z7ZBBgOLS6jH+7/owEhRCJtAlkX3TBFqSyBcGN xVW25aIx6sgcyTxggZ+2JiniX8j2UMjRMFuWu/O0= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2026-99714: nvme: Do not drop the cdev reference twice when cdev_device_add() fails Date: Fri, 20 Nov 2026 06:51:40 +0100 Message-ID: <2026112007-CVE-2026-99714-5b04@gregkh> X-Mailer: git-send-email 2.56.1 Reply-To: , X-Mailing-List: linux-cve-announce@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=3135; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=aLeHpH/CjsXR5x6Rux45rXzaReBSBaYl7i+O4fkV/2M=; b=owGbwMvMwCRo6H6F97bub03G02pJDFn/7/d7N0z1LRSL/qd92yFl28qlvV+yb/SHaXwXcNZ+s nhl+q/jHbEsDIJMDLJiiixftvEc3V9xSNHL0PY0zBxWJpAhDFycAjARbi2G+dV8l74EOWz508r2 PCZ5dstF/wmBSgzzlG4aVHZnV3+bWqFlUrj71NbJin1PAQ== 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: nvme: Do not drop the cdev reference twice when cdev_device_add() fails Since commit 9952f3882ecb ("nvme: fix cdev lifetime"), nvme_add_ns_cdev() and nvme_add_ns_head_cdev() take a reference to the namespace (or namespace head) before calling nvme_cdev_add(), to be dropped by the char device's release, nvme_cdev_rel(), and drop it themselves when nvme_cdev_add() fails. But when cdev_device_add() fails, nvme_cdev_add() has already put the device, and nvme_cdev_rel() has already dropped that reference: the caller drops it a second time. With one allocation failure injected into cdev_device_add() for a namespace on an NVMe over loop controller, deleting the controller gives, with native multipath: BUG: KASAN: slab-use-after-free in nvme_put_ns_head+0x21/0x140 Write of size 4 at addr ff1100000a4ea078 by task init/1 nvme_put_ns_head nvme_put_ns nvme_remove_namespaces nvme_do_delete_ctrl nvme_delete_ctrl_sync nvme_sysfs_delete Freed by task 1: kfree nvme_ns_remove nvme_remove_namespaces refcount_t: underflow; use-after-free. Take the reference in nvme_cdev_add() instead, right before cdev_device_add(), and let the callers neither take nor drop it. Add nvme_is_ns_cdev() for the check that nvme_cdev_rel() and nvme_cdev_add() now share. The Linux kernel CVE team has assigned CVE-2026-99714 to this issue. Affected and fixed versions =========================== Issue introduced in 7.3 with commit 9952f3882ecba709092379b71e02b09762b26f96 and fixed in 7.3.5 with commit 45d0c2d7d338ae1606984ed92d254ca0efcef921 Issue introduced in 7.3 with commit 9952f3882ecba709092379b71e02b09762b26f96 and fixed in 7.4-rc2 with commit 7dfe79db5615df8d37ae7de6d3ec099b71bf3e03 Issue introduced in 7.2.10 with commit 98b09ad7934482e64db4b4477d91e3bbf43adf4c 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-99714 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/nvme/host/core.c drivers/nvme/host/multipath.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/45d0c2d7d338ae1606984ed92d254ca0efcef921 https://git.kernel.org/stable/c/7dfe79db5615df8d37ae7de6d3ec099b71bf3e03