[PATCH] ppc64 iSeries: allow build with no PCI
[linux-2.6-block.git] / arch / ppc64 / kernel / dma.c
index ce714c9271344f6f1e7df5ca71bb903928f16d5f..4da8e31b2b61da90c4bd93b49d630687049ad5d4 100644 (file)
 
 static struct dma_mapping_ops *get_dma_ops(struct device *dev)
 {
+#ifdef CONFIG_PCI
        if (dev->bus == &pci_bus_type)
                return &pci_dma_ops;
+#endif
 #ifdef CONFIG_IBMVIO
        if (dev->bus == &vio_bus_type)
                return &vio_dma_ops;
@@ -37,8 +39,10 @@ EXPORT_SYMBOL(dma_supported);
 
 int dma_set_mask(struct device *dev, u64 dma_mask)
 {
+#ifdef CONFIG_PCI
        if (dev->bus == &pci_bus_type)
                return pci_set_dma_mask(to_pci_dev(dev), dma_mask);
+#endif
 #ifdef CONFIG_IBMVIO
        if (dev->bus == &vio_bus_type)
                return -EIO;