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 85A6C197A76 for ; Thu, 27 Feb 2025 02:18:51 +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=1740622731; cv=none; b=kDiMFNHpm2CqV86re3oG3+v/6Pidu1vH8962iBARppu9ZnGoPBA/5QR+k85dwA/gnw2WatVG/MFji8w6hJHRutQFWKr5GhhlWDKeyCGh+Wr1goj/LdNPxnmPuiBRjCMJ48srT2YVT5rdavpaYW8Wriq5S4SkJcTAfEeSy7X5L7E= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1740622731; c=relaxed/simple; bh=LMaLz7S25dffPCIgo07a9UoJgZjL4+eQ5iZLumhAE+Y=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=EGRNguacYVqn2jUWP4z6wUGUb4zAFBIpqC2P9bRP4s/HCwuLEYTA7Hm3ChkvUff81mov/iK0EZR2r3lzDYs2WmaKqtyO+ZJQR0Q7u6JGLezV0TOVexPdzs7Cz5p9/6X5CDcLeseiERpDs7AP3oI6LlSdchox0NCO1MTppmYVe4s= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=UlKuxLnv; 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="UlKuxLnv" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 57F71C4CED6; Thu, 27 Feb 2025 02:18:51 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1740622731; bh=LMaLz7S25dffPCIgo07a9UoJgZjL4+eQ5iZLumhAE+Y=; h=From:To:Cc:Subject:Date:Reply-to:From; b=UlKuxLnvHa8cI+kqKiM9V2Ho3UGjxeFDC5ebTIc513OSQg5HCH1fSriusSJ1bRP+f HMgsv1CCSjRiRKhcQnZuGYE8pLWGpHArqjtpnDxdbEkiZQqKphqbrue7E8+FdllWCc YG9WlBv8arqjgWYbhiISy9j9DC6293wOoU6CNGNU= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2025-21770: iommu: Fix potential memory leak in iopf_queue_remove_device() Date: Wed, 26 Feb 2025 18:17:26 -0800 Message-ID: <2025022606-CVE-2025-21770-d7e0@gregkh> X-Mailer: git-send-email 2.48.1 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=2551; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=LMaLz7S25dffPCIgo07a9UoJgZjL4+eQ5iZLumhAE+Y=; b=owGbwMvMwCRo6H6F97bub03G02pJDOn7Tyud+7r3TEFU93HmhN0fZayWZD/ZpTmTO9bT1rmJ+ UyNs8jBjlgWBkEmBlkxRZYv23iO7q84pOhlaHsaZg4rE8gQBi5OAZiIrhDDggZbvbgbGb+deezY s7nP/NxQ1lsvw7Bg2627MS+CuEqCV3IYKfi2Fmp0S4gBAA== 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: iommu: Fix potential memory leak in iopf_queue_remove_device() The iopf_queue_remove_device() helper removes a device from the per-iommu iopf queue when PRI is disabled on the device. It responds to all outstanding iopf's with an IOMMU_PAGE_RESP_INVALID code and detaches the device from the queue. However, it fails to release the group structure that represents a group of iopf's awaiting for a response after responding to the hardware. This can cause a memory leak if iopf_queue_remove_device() is called with pending iopf's. Fix it by calling iopf_free_group() after the iopf group is responded. The Linux kernel CVE team has assigned CVE-2025-21770 to this issue. Affected and fixed versions =========================== Issue introduced in 6.9 with commit 19911232713573a2ebea84a25bd4d71d024ed86b and fixed in 6.12.16 with commit db60d2d896a17decd58d143eef92cf22eb0a0176 Issue introduced in 6.9 with commit 19911232713573a2ebea84a25bd4d71d024ed86b and fixed in 6.13.4 with commit 90d5429cd2921ca2714684ed525898d431bb9283 Issue introduced in 6.9 with commit 19911232713573a2ebea84a25bd4d71d024ed86b and fixed in 6.14-rc3 with commit 9759ae2cee7cd42b95f1c48aa3749bd02b5ddb08 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-2025-21770 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/iommu/io-pgfault.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/db60d2d896a17decd58d143eef92cf22eb0a0176 https://git.kernel.org/stable/c/90d5429cd2921ca2714684ed525898d431bb9283 https://git.kernel.org/stable/c/9759ae2cee7cd42b95f1c48aa3749bd02b5ddb08