aboutsummaryrefslogtreecommitdiffstats
path: root/arch/powerpc/platforms/cell/iommu.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/powerpc/platforms/cell/iommu.c')
-rw-r--r--arch/powerpc/platforms/cell/iommu.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/arch/powerpc/platforms/cell/iommu.c b/arch/powerpc/platforms/cell/iommu.c
index 45646b2b4af..eeacb3a52ca 100644
--- a/arch/powerpc/platforms/cell/iommu.c
+++ b/arch/powerpc/platforms/cell/iommu.c
@@ -540,7 +540,7 @@ static unsigned long cell_dma_direct_offset;
540static unsigned long dma_iommu_fixed_base; 540static unsigned long dma_iommu_fixed_base;
541struct dma_mapping_ops dma_iommu_fixed_ops; 541struct dma_mapping_ops dma_iommu_fixed_ops;
542 542
543static void cell_dma_dev_setup_iommu(struct device *dev) 543static struct iommu_table *cell_get_iommu_table(struct device *dev)
544{ 544{
545 struct iommu_window *window; 545 struct iommu_window *window;
546 struct cbe_iommu *iommu; 546 struct cbe_iommu *iommu;
@@ -555,11 +555,11 @@ static void cell_dma_dev_setup_iommu(struct device *dev)
555 printk(KERN_ERR "iommu: missing iommu for %s (node %d)\n", 555 printk(KERN_ERR "iommu: missing iommu for %s (node %d)\n",
556 archdata->of_node ? archdata->of_node->full_name : "?", 556 archdata->of_node ? archdata->of_node->full_name : "?",
557 archdata->numa_node); 557 archdata->numa_node);
558 return; 558 return NULL;
559 } 559 }
560 window = list_entry(iommu->windows.next, struct iommu_window, list); 560 window = list_entry(iommu->windows.next, struct iommu_window, list);
561 561
562 archdata->dma_data = &window->table; 562 return &window->table;
563} 563}
564 564
565static void cell_dma_dev_setup_fixed(struct device *dev); 565static void cell_dma_dev_setup_fixed(struct device *dev);
@@ -572,7 +572,7 @@ static void cell_dma_dev_setup(struct device *dev)
572 if (get_dma_ops(dev) == &dma_iommu_fixed_ops) 572 if (get_dma_ops(dev) == &dma_iommu_fixed_ops)
573 cell_dma_dev_setup_fixed(dev); 573 cell_dma_dev_setup_fixed(dev);
574 else if (get_pci_dma_ops() == &dma_iommu_ops) 574 else if (get_pci_dma_ops() == &dma_iommu_ops)
575 cell_dma_dev_setup_iommu(dev); 575 archdata->dma_data = cell_get_iommu_table(dev);
576 else if (get_pci_dma_ops() == &dma_direct_ops) 576 else if (get_pci_dma_ops() == &dma_direct_ops)
577 archdata->dma_data = (void *)cell_dma_direct_offset; 577 archdata->dma_data = (void *)cell_dma_direct_offset;
578 else 578 else