mirror of
https://github.com/AsahiLinux/u-boot
synced 2024-11-24 21:54:01 +00:00
iommu: fix compilation when CONFIG_PCI disabled
The dev_pci_iommu_enable() function is only available when CONFIG_PCI is enabled, replace the runtime check with a preprocessor one to fix compilation with pci disabled. Signed-off-by: Caleb Connolly <caleb.connolly@linaro.org>
This commit is contained in:
parent
f1b809c55c
commit
e96ecbe719
1 changed files with 3 additions and 2 deletions
|
@ -100,9 +100,10 @@ int dev_iommu_enable(struct udevice *dev)
|
|||
dev->iommu = dev_iommu;
|
||||
}
|
||||
|
||||
if (CONFIG_IS_ENABLED(PCI) && count < 0 &&
|
||||
device_is_on_pci_bus(dev))
|
||||
#if CONFIG_IS_ENABLED(PCI)
|
||||
if (count < 0 && device_is_on_pci_bus(dev))
|
||||
return dev_pci_iommu_enable(dev);
|
||||
#endif
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue