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 90FC23E1CED for ; Thu, 24 Sep 2026 16:18:11 +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=1790266692; cv=none; b=PiPmeD3aUGcs2ZEBZ1Wkw3QTo7ArRh5Q8unxKXvSg5vpj3ckiEdESaObRWkjg9ExWjgBFAfWJy0BdtmakR5FzMbppxFWaG1zKnvpy5azMsAZih5Pd+m7j1yIHVrDZHUQXTV+PD+POBB8CX0dLveeUi+OPIDPmcD66SPf+4Z/meM= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1790266692; c=relaxed/simple; bh=Aez4FAJiNMSWWy0GIoRCDcP4LoudA30SkzC+tGKacy4=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=qVcxmselQhWnl34BrK4O44iUXZeamvqw++mcO64YnY85DdB0c0ukL4LG5gcllTtpqTWdY34zslEgMjU5dvmg14IUkO4A7c+OZMexUFSZiZ74WENg9UZaPkhQFCouFoQbyUUlN+Gmb/rb6gXJWWW6C7ix4sdF4vpU4VIm1A0qOB4= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=gOzrMJkp; 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="gOzrMJkp" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 6A91C1F000FF; Thu, 24 Sep 2026 16:18:10 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linuxfoundation.org; s=korg; t=1790266691; bh=oKUqh8EfiQAHHr9Pt7kdHIyKfvHTgz3G94NSvQduTVc=; h=From:To:Cc:Subject:Date:Reply-To; b=gOzrMJkpIXkyMVI8peUfN4RhMUA1oAKP5fdrOaphVHZIMH/nnGxY6xG90UbJa+iOp //Qol5kzGE76lD0aT5woxfNTizIV9CqWFYWt109jtDgwl9qpFRmtt5I7HyVgt39pv9 V46uoROnM7rXNLZ0HQK8CD9kzp4aLIIr30e7hJes= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2026-97478: virt: acrn: Fix irqfd use-after-free during eventfd shutdown Date: Thu, 24 Sep 2026 18:04:03 +0200 Message-ID: <2026092436-CVE-2026-97478-369e@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=3888; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=y8zbLrdcJtbnPgr826kjo/q8hGRyhbKuIr4W9m7E+Ls=; b=owGbwMvMwCRo6H6F97bub03G02pJDFlbPed0KzyaZLp3pez19dzzlmR/5WALkJn/2IhtZ2nOQ s1/5nWWHbEsDIJMDLJiiixftvEc3V9xSNHL0PY0zBxWJpAhDFycAjARE2GGeeZyLu83s6+YHPvH 7ap24rFXzeUNjAxz5SfPC8jdd/bQFId25quO6vqG5cn3AA== 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: virt: acrn: Fix irqfd use-after-free during eventfd shutdown acrn_irqfd_deassign() and the eventfd EPOLLHUP wakeup can race and free the same struct hsm_irqfd: CPU0 CPU1 ---- ---- eventfd_release() wake_up_poll(EPOLLHUP) hsm_irqfd_wakeup() queue_work(&irqfd->shutdown) acrn_irqfd_deassign() hsm_irqfd_shutdown() list_del_init() eventfd_ctx_remove_wait_queue() eventfd_ctx_put() kfree(irqfd) hsm_irqfd_shutdown_work() container_of(work, ..., shutdown) irqfd->vm <-- use-after-free The deassign path freed the irqfd while a shutdown work item was already queued by EPOLLHUP (or vice versa), so the work item could resurrect a dangling pointer through container_of(). Switch to the lifetime model used by KVM irqfds: - Deassign/deinit only deactivate the irqfd: remove it from vm->irqfds under irqfds_lock and queue the cleanup work. - hsm_irqfd_shutdown_work() becomes the sole owner that unhooks the eventfd waitqueue entry, drops the eventfd reference and frees the irqfd. - A new HSM_IRQFD_FLAG_SHUTDOWN bit guarded by test_and_set_bit() ensures the cleanup work is queued at most once, no matter how many of {EPOLLHUP, deassign, deinit} fire concurrently. This is safe to call from the waitqueue callback, which runs with wqh->lock held and IRQs disabled and therefore cannot take irqfds_lock. - acrn_irqfd_deassign() flushes vm->irqfd_wq before returning so the eventfd is fully detached on return. acrn_irqfd_deinit() deactivates every irqfd, flushes the workqueue and only then destroys it, so no path can queue_work() onto a torn-down workqueue. - acrn_irqfd_assign() now installs the eventfd waitqueue entry and publishes the irqfd to vm->irqfds under irqfds_lock, so the irqfd is never visible to deassign/deinit before its waitqueue entry is in place, and any EPOLLHUP that fires in the assign window queues cleanup work that blocks on irqfds_lock until publication is done. The Linux kernel CVE team has assigned CVE-2026-97478 to this issue. Affected and fixed versions =========================== Fixed in 6.18.53 with commit d8156aacfcabb81f52c20ef89094945434d08079 Fixed in 7.2 with commit 666c7f9e07925aa0863348f960e09bb89f8f05a3 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-97478 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/virt/acrn/irqfd.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/d8156aacfcabb81f52c20ef89094945434d08079 https://git.kernel.org/stable/c/666c7f9e07925aa0863348f960e09bb89f8f05a3