diff options
Diffstat (limited to 'drivers/iommu/of_iommu.c')
-rw-r--r-- | drivers/iommu/of_iommu.c | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/drivers/iommu/of_iommu.c b/drivers/iommu/of_iommu.c index af1dc6a1c0a1..43429ab62228 100644 --- a/drivers/iommu/of_iommu.c +++ b/drivers/iommu/of_iommu.c | |||
@@ -133,19 +133,25 @@ struct iommu_ops *of_iommu_get_ops(struct device_node *np) | |||
133 | return ops; | 133 | return ops; |
134 | } | 134 | } |
135 | 135 | ||
136 | struct iommu_ops *of_iommu_configure(struct device *dev) | 136 | struct iommu_ops *of_iommu_configure(struct device *dev, |
137 | struct device_node *master_np) | ||
137 | { | 138 | { |
138 | struct of_phandle_args iommu_spec; | 139 | struct of_phandle_args iommu_spec; |
139 | struct device_node *np; | 140 | struct device_node *np; |
140 | struct iommu_ops *ops = NULL; | 141 | struct iommu_ops *ops = NULL; |
141 | int idx = 0; | 142 | int idx = 0; |
142 | 143 | ||
144 | if (dev_is_pci(dev)) { | ||
145 | dev_err(dev, "IOMMU is currently not supported for PCI\n"); | ||
146 | return NULL; | ||
147 | } | ||
148 | |||
143 | /* | 149 | /* |
144 | * We don't currently walk up the tree looking for a parent IOMMU. | 150 | * We don't currently walk up the tree looking for a parent IOMMU. |
145 | * See the `Notes:' section of | 151 | * See the `Notes:' section of |
146 | * Documentation/devicetree/bindings/iommu/iommu.txt | 152 | * Documentation/devicetree/bindings/iommu/iommu.txt |
147 | */ | 153 | */ |
148 | while (!of_parse_phandle_with_args(dev->of_node, "iommus", | 154 | while (!of_parse_phandle_with_args(master_np, "iommus", |
149 | "#iommu-cells", idx, | 155 | "#iommu-cells", idx, |
150 | &iommu_spec)) { | 156 | &iommu_spec)) { |
151 | np = iommu_spec.np; | 157 | np = iommu_spec.np; |