Commit 80aa5184 authored by Johan Hovold's avatar Johan Hovold Committed by Joerg Roedel
Browse files

iommu/ipmmu-vmsa: fix device leak on of_xlate()



Make sure to drop the reference taken to the iommu platform device when
looking up its driver data during of_xlate().

Fixes: 7b2d5961 ("iommu/ipmmu-vmsa: Replace local utlb code with fwspec ids")
Cc: stable@vger.kernel.org	# 4.14
Cc: Magnus Damm <damm+renesas@opensource.se>
Acked-by: default avatarRobin Murphy <robin.murphy@arm.com>
Signed-off-by: default avatarJohan Hovold <johan@kernel.org>
Signed-off-by: default avatarJoerg Roedel <joerg.roedel@amd.com>
parent 05913cc4
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -720,6 +720,8 @@ static int ipmmu_init_platform_device(struct device *dev,

	dev_iommu_priv_set(dev, platform_get_drvdata(ipmmu_pdev));

	put_device(&ipmmu_pdev->dev);

	return 0;
}