Commit cb6f6392 authored by Christoph Hellwig's avatar Christoph Hellwig

powerpc: remove support for NULL dev in __phys_to_dma / __dma_to_phys

Support for calling the DMA API functions without a valid device pointer
was removed a while ago, so remove the stale support for that from the
powerpc __phys_to_dma / __dma_to_phys helpers.
Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
Acked-by: default avatarMichael Ellerman <mpe@ellerman.id.au>
Reviewed-by: default avatarNicolas Saenz Julienne <nsaenzjulienne@suse.de>
parent c7345159
......@@ -4,15 +4,11 @@
static inline dma_addr_t __phys_to_dma(struct device *dev, phys_addr_t paddr)
{
if (!dev)
return paddr + PCI_DRAM_OFFSET;
return paddr + dev->archdata.dma_offset;
}
static inline phys_addr_t __dma_to_phys(struct device *dev, dma_addr_t daddr)
{
if (!dev)
return daddr - PCI_DRAM_OFFSET;
return daddr - dev->archdata.dma_offset;
}
#endif /* ASM_POWERPC_DMA_DIRECT_H */
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