Commit 40fa84e1 authored by Arnd Bergmann's avatar Arnd Bergmann Committed by Joerg Roedel

iommu: rockchip: fix building without CONFIG_OF

We get a build error when compiling the iommu driver without CONFIG_OF:

drivers/iommu/rockchip-iommu.c: In function 'rk_iommu_of_xlate':
drivers/iommu/rockchip-iommu.c:1101:2: error: implicit declaration of function 'of_dev_put'; did you mean 'of_node_put'? [-Werror=implicit-function-declaration]

This replaces the of_dev_put() with the equivalent
platform_device_put().

Fixes: 5fd577c3 ("iommu/rockchip: Use OF_IOMMU to attach devices automatically")
Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
Signed-off-by: default avatarJoerg Roedel <jroedel@suse.de>
parent a85894cd
...@@ -1098,7 +1098,7 @@ static int rk_iommu_of_xlate(struct device *dev, ...@@ -1098,7 +1098,7 @@ static int rk_iommu_of_xlate(struct device *dev,
data->iommu = platform_get_drvdata(iommu_dev); data->iommu = platform_get_drvdata(iommu_dev);
dev->archdata.iommu = data; dev->archdata.iommu = data;
of_dev_put(iommu_dev); platform_device_put(iommu_dev);
return 0; return 0;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment