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 BAC0F14264C for ; Tue, 21 May 2024 14:39:09 +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=1716302349; cv=none; b=rDMXvug7DU8AT11IbP4Ep98Cqrhsa7miBeKreUlpaltE3xfUwgZH8++m5Ez2MnD2C7grEGrgxxSingXrw9qxm3Rj2mOXA8VMBFEN7h+UlhBI7nuMBta9U9tGFeMfy2bb47SUfWfnxgQaDSp0xwLtgFTs9q6Hp64Zfxnkt2ieKSQ= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1716302349; c=relaxed/simple; bh=Tf/LkiPvDyVGVdL42MqV1cVLNzcVGrDNPd2gEhLkbaU=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=pY9m3xLFeLrCzcLEvoJBjgOw/HJ4IYiqk2rlGuqzhG8Uqb/OjKwYvhqG5hIDt9NMR7Obpei5nubyY/JMq7+fC9mOIY+HyBqmuaWwROUHmQxN22hSpNpnyqiKosrzG3/ehGsl+E3XtZQfLub0mZdIDoiTQnQsAl19r8a2VRU8J9E= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=ecCbcrRp; 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="ecCbcrRp" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 47865C2BD11; Tue, 21 May 2024 14:39:09 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1716302349; bh=Tf/LkiPvDyVGVdL42MqV1cVLNzcVGrDNPd2gEhLkbaU=; h=From:To:Cc:Subject:Date:Reply-to:From; b=ecCbcrRp/yu732jYWvZoMF4tTfDHeO761iYJNiYCSgBvmnu8dP2LQRS3HjnxVXcVm pVugD8VYau/Y4BgI1xVO/MPPO1aERs46EvtzrRD9xuDgtBrj1SUQbvG2p3y9u3gArY Y4yHHJllJCcz9BBwYCSpHndiaZjUBo+DcRnR5y2o= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2021-47325: iommu/arm-smmu: Fix arm_smmu_device refcount leak in address translation Date: Tue, 21 May 2024 16:35:59 +0200 Message-ID: <2024052133-CVE-2021-47325-f4e8@gregkh> X-Mailer: git-send-email 2.45.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=2265; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=Tf/LkiPvDyVGVdL42MqV1cVLNzcVGrDNPd2gEhLkbaU=; b=owGbwMvMwCRo6H6F97bub03G02pJDGk+G00PGU21VL922izLplnqr5OkEdOaD3MVjh1fsOmxS jBHtsSxjlgWBkEmBlkxRZYv23iO7q84pOhlaHsaZg4rE8gQBi5OAZjIxJkM8/2mLnp7OyB1m1bN DZac7UvnfWOavZ5hftp/iXmCFUv0K+Y9W7nB0pilquOoNAA= 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/arm-smmu: Fix arm_smmu_device refcount leak in address translation The reference counting issue happens in several exception handling paths of arm_smmu_iova_to_phys_hard(). When those error scenarios occur, the function forgets to decrease the refcount of "smmu" increased by arm_smmu_rpm_get(), causing a refcount leak. Fix this issue by jumping to "out" label when those error scenarios occur. The Linux kernel CVE team has assigned CVE-2021-47325 to this issue. Affected and fixed versions =========================== Fixed in 5.4.134 with commit b11220803ad1 Fixed in 5.10.52 with commit 43d1aaa1965f Fixed in 5.12.19 with commit 0f0c5ea09139 Fixed in 5.13.4 with commit 5f9741a9a91f Fixed in 5.14 with commit 7c8f176d6a3f 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-2021-47325 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/arm/arm-smmu/arm-smmu.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/b11220803ad14a2a880cc06d8e01fe2548cc85b0 https://git.kernel.org/stable/c/43d1aaa1965f9b58035196dac49b1e1e6c9c25eb https://git.kernel.org/stable/c/0f0c5ea09139777d90729d408b807021f2ea6492 https://git.kernel.org/stable/c/5f9741a9a91f25c89e04b408cd61e3ab050ce24b https://git.kernel.org/stable/c/7c8f176d6a3fa18aa0f8875da6f7c672ed2a8554