From mboxrd@z Thu Jan 1 00:00:00 1970 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 382055908B0 for ; Fri, 11 Sep 2026 20:05:55 +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=1789157162; cv=none; b=fY4ucdUHZ57+vxiuCYQE3Iowq0qzaT4bX8cDVSsz0dGAfyjykzK0Y1h5sKuEhVd0jHGtgq7DHCYu43NeL49ufzLko8a81+npwL4t+rwpiThpQnnb4cwpUFrL1Swf1lUxpE2rluHu5hN70hS+5vtviyHjB3n0dlbB/JoBdtDaqLU= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1789157162; c=relaxed/simple; bh=wq7yNcjwmUTPphVMfqQU5qJY1DuZ6WXeCtAKKrNikfM=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=IaObv2rv+VxTZIZCAcsBkdxAyrNk/BRD7TIgOc6qnlWGDRGPot6/yzFoVcuKuN78JXJY3L9ySD/d/2A7IpkL5nHgz/EgLpepK8eVNxR0OorOjH3x1LbXeilOqMR7IhgB4WW7ThuR0mvsMbSQn3VwJWMGNQJTQSu1BTHempQjUjg= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=LBPuxsGM; 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="LBPuxsGM" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 725FE1F00898; Fri, 11 Sep 2026 20:05:54 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linuxfoundation.org; s=korg; t=1789157155; bh=YM3V79VOBmB4GmLhcpK2hNGtf2ftJtZtkIOB6chGzoQ=; h=From:To:Cc:Subject:Date:Reply-To; b=LBPuxsGMQQII5F+UQwJhzLFpmzfXGWcB57FwJt4aiGI4/jjhCeQ1jGTPIiU41YJ5c 9CynK3wG+VL0KTQxueHgvCezeSS+FkyVacRJma1a7Dp5x7e5cTMUSrrXhrQlYLLE78 n3rNakKSD2AU1VL41RQhOVkgwHN4Loe0O8ENLaQc= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2026-89755: mm/migrate_device: clear stale mapping after freeing swapcache Date: Fri, 11 Sep 2026 21:47:24 +0200 Message-ID: <2026091108-CVE-2026-89755-0b4d@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=2626; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=t7S74M71XYYkcFNeptPdcKY9s9CtIMG8pCsL1w6y028=; b=owGbwMvMwCRo6H6F97bub03G02pJDFlLIidktVY1hn7Zy+hmKz3z55ylC9U5HvbNWx5sYyT4c ole+eHojlgWBkEmBlkxRZYv23iO7q84pOhlaHsaZg4rE8gQBi5OAZhI0lyGBQcXclg9NnrQZtRW /WjLt3kTOgOsJzDMD36ba7thwZ3nmhkFt9e1z7itos+2HQA= 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: mm/migrate_device: clear stale mapping after freeing swapcache __migrate_device_pages() reads the folio mapping before calling folio_free_swap(). When folio_free_swap() succeeds, the folio is removed from the swap cache, but the saved mapping still points to swap_space. Passing the stale mapping to folio_migrate_mapping() makes it use the mapped-folio path for a folio that is no longer in swapcache. It can then operate on swap_space.i_pages with invalid reference accounting, eventually triggering a folio reference count BUG. After a successful split, nr still contains the number of pages in the original large folio, although each resulting page is now a separate order-0 folio. Reset nr to 1 so each split folio is processed separately, including its own swapcache removal and mapping lookup. Refresh the saved mapping after folio_free_swap() so the current folio state is used during migration. The Linux kernel CVE team has assigned CVE-2026-89755 to this issue. Affected and fixed versions =========================== Issue introduced in 6.6 with commit df263d9a7dffee94ca5391120ee3b0587efa07f1 and fixed in 7.2.4 with commit 8ffedc6573a665cdc31ebe47eae7b32b78d0df83 Issue introduced in 6.6 with commit df263d9a7dffee94ca5391120ee3b0587efa07f1 and fixed in 7.3-rc1 with commit 34a00895d032a414830d41106a09329ae6c251b6 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-89755 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: mm/migrate_device.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/8ffedc6573a665cdc31ebe47eae7b32b78d0df83 https://git.kernel.org/stable/c/34a00895d032a414830d41106a09329ae6c251b6