Commit 474e3d56 authored by Michael Ellerman's avatar Michael Ellerman Committed by Benjamin Herrenschmidt

powerpc/pseries: Remove uses of abs_to_virt() and virt_to_abs()

These days they are just __va() and __pa() respectively.
Signed-off-by: default avatarMichael Ellerman <michael@ellerman.id.au>
Signed-off-by: default avatarBenjamin Herrenschmidt <benh@kernel.crashing.org>
parent 3d267523
...@@ -41,7 +41,6 @@ ...@@ -41,7 +41,6 @@
#include <asm/iommu.h> #include <asm/iommu.h>
#include <asm/pci-bridge.h> #include <asm/pci-bridge.h>
#include <asm/machdep.h> #include <asm/machdep.h>
#include <asm/abs_addr.h>
#include <asm/pSeries_reconfig.h> #include <asm/pSeries_reconfig.h>
#include <asm/firmware.h> #include <asm/firmware.h>
#include <asm/tce.h> #include <asm/tce.h>
...@@ -99,7 +98,7 @@ static int tce_build_pSeries(struct iommu_table *tbl, long index, ...@@ -99,7 +98,7 @@ static int tce_build_pSeries(struct iommu_table *tbl, long index,
while (npages--) { while (npages--) {
/* can't move this out since we might cross MEMBLOCK boundary */ /* can't move this out since we might cross MEMBLOCK boundary */
rpn = (virt_to_abs(uaddr)) >> TCE_SHIFT; rpn = __pa(uaddr) >> TCE_SHIFT;
*tcep = proto_tce | (rpn & TCE_RPN_MASK) << TCE_RPN_SHIFT; *tcep = proto_tce | (rpn & TCE_RPN_MASK) << TCE_RPN_SHIFT;
uaddr += TCE_PAGE_SIZE; uaddr += TCE_PAGE_SIZE;
...@@ -148,7 +147,7 @@ static int tce_build_pSeriesLP(struct iommu_table *tbl, long tcenum, ...@@ -148,7 +147,7 @@ static int tce_build_pSeriesLP(struct iommu_table *tbl, long tcenum,
int ret = 0; int ret = 0;
long tcenum_start = tcenum, npages_start = npages; long tcenum_start = tcenum, npages_start = npages;
rpn = (virt_to_abs(uaddr)) >> TCE_SHIFT; rpn = __pa(uaddr) >> TCE_SHIFT;
proto_tce = TCE_PCI_READ; proto_tce = TCE_PCI_READ;
if (direction != DMA_TO_DEVICE) if (direction != DMA_TO_DEVICE)
proto_tce |= TCE_PCI_WRITE; proto_tce |= TCE_PCI_WRITE;
...@@ -217,7 +216,7 @@ static int tce_buildmulti_pSeriesLP(struct iommu_table *tbl, long tcenum, ...@@ -217,7 +216,7 @@ static int tce_buildmulti_pSeriesLP(struct iommu_table *tbl, long tcenum,
__get_cpu_var(tce_page) = tcep; __get_cpu_var(tce_page) = tcep;
} }
rpn = (virt_to_abs(uaddr)) >> TCE_SHIFT; rpn = __pa(uaddr) >> TCE_SHIFT;
proto_tce = TCE_PCI_READ; proto_tce = TCE_PCI_READ;
if (direction != DMA_TO_DEVICE) if (direction != DMA_TO_DEVICE)
proto_tce |= TCE_PCI_WRITE; proto_tce |= TCE_PCI_WRITE;
...@@ -237,7 +236,7 @@ static int tce_buildmulti_pSeriesLP(struct iommu_table *tbl, long tcenum, ...@@ -237,7 +236,7 @@ static int tce_buildmulti_pSeriesLP(struct iommu_table *tbl, long tcenum,
rc = plpar_tce_put_indirect((u64)tbl->it_index, rc = plpar_tce_put_indirect((u64)tbl->it_index,
(u64)tcenum << 12, (u64)tcenum << 12,
(u64)virt_to_abs(tcep), (u64)__pa(tcep),
limit); limit);
npages -= limit; npages -= limit;
...@@ -441,7 +440,7 @@ static int tce_setrange_multi_pSeriesLP(unsigned long start_pfn, ...@@ -441,7 +440,7 @@ static int tce_setrange_multi_pSeriesLP(unsigned long start_pfn,
rc = plpar_tce_put_indirect(liobn, rc = plpar_tce_put_indirect(liobn,
dma_offset, dma_offset,
(u64)virt_to_abs(tcep), (u64)__pa(tcep),
limit); limit);
num_tce -= limit; num_tce -= limit;
......
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