Release 4.14 arch/mips/include/asm/mach-ip27/dma-coherence.h
/*
* This file is subject to the terms and conditions of the GNU General Public
* License. See the file "COPYING" in the main directory of this archive
* for more details.
*
* Copyright (C) 2006 Ralf Baechle <ralf@linux-mips.org>
*
*/
#ifndef __ASM_MACH_IP27_DMA_COHERENCE_H
#define __ASM_MACH_IP27_DMA_COHERENCE_H
#include <asm/pci/bridge.h>
#define pdev_to_baddr(pdev, addr) \
(BRIDGE_CONTROLLER(pdev->bus)->baddr + (addr))
#define dev_to_baddr(dev, addr) \
pdev_to_baddr(to_pci_dev(dev), (addr))
struct device;
static inline dma_addr_t plat_map_dma_mem(struct device *dev, void *addr,
size_t size)
{
dma_addr_t pa = dev_to_baddr(dev, virt_to_phys(addr));
return pa;
}
Contributors
Person | Tokens | Prop | Commits | CommitProp |
Ralf Bächle | 35 | 100.00% | 2 | 100.00% |
Total | 35 | 100.00% | 2 | 100.00% |
static inline dma_addr_t plat_map_dma_mem_page(struct device *dev,
struct page *page)
{
dma_addr_t pa = dev_to_baddr(dev, page_to_phys(page));
return pa;
}
Contributors
Person | Tokens | Prop | Commits | CommitProp |
Ralf Bächle | 32 | 96.97% | 1 | 50.00% |
David Daney | 1 | 3.03% | 1 | 50.00% |
Total | 33 | 100.00% | 2 | 100.00% |
static inline unsigned long plat_dma_addr_to_phys(struct device *dev,
dma_addr_t dma_addr)
{
return dma_addr & ~(0xffUL << 56);
}
Contributors
Person | Tokens | Prop | Commits | CommitProp |
Ralf Bächle | 20 | 76.92% | 2 | 50.00% |
Kevin Cernekee | 5 | 19.23% | 1 | 25.00% |
David Daney | 1 | 3.85% | 1 | 25.00% |
Total | 26 | 100.00% | 4 | 100.00% |
static inline void plat_unmap_dma_mem(struct device *dev, dma_addr_t dma_addr,
size_t size, enum dma_data_direction direction)
{
}
Contributors
Person | Tokens | Prop | Commits | CommitProp |
Ralf Bächle | 9 | 42.86% | 2 | 50.00% |
Kevin Cernekee | 7 | 33.33% | 1 | 25.00% |
David Daney | 5 | 23.81% | 1 | 25.00% |
Total | 21 | 100.00% | 4 | 100.00% |
static inline int plat_dma_supported(struct device *dev, u64 mask)
{
/*
* we fall back to GFP_DMA when the mask isn't all 1s,
* so we can't guarantee allocations that must be
* within a tighter range than GFP_DMA..
*/
if (mask < DMA_BIT_MASK(24))
return 0;
return 1;
}
Contributors
Person | Tokens | Prop | Commits | CommitProp |
David Daney | 31 | 100.00% | 1 | 100.00% |
Total | 31 | 100.00% | 1 | 100.00% |
static inline void plat_post_dma_flush(struct device *dev)
{
}
Contributors
Person | Tokens | Prop | Commits | CommitProp |
Ralf Bächle | 11 | 100.00% | 1 | 100.00% |
Total | 11 | 100.00% | 1 | 100.00% |
static inline int plat_device_is_coherent(struct device *dev)
{
return 1; /* IP27 non-coherent mode is unsupported */
}
Contributors
Person | Tokens | Prop | Commits | CommitProp |
Ralf Bächle | 15 | 93.75% | 1 | 50.00% |
Andrea Gelmini | 1 | 6.25% | 1 | 50.00% |
Total | 16 | 100.00% | 2 | 100.00% |
#endif /* __ASM_MACH_IP27_DMA_COHERENCE_H */
Overall Contributors
Person | Tokens | Prop | Commits | CommitProp |
Ralf Bächle | 158 | 75.60% | 4 | 44.44% |
David Daney | 38 | 18.18% | 2 | 22.22% |
Kevin Cernekee | 12 | 5.74% | 2 | 22.22% |
Andrea Gelmini | 1 | 0.48% | 1 | 11.11% |
Total | 209 | 100.00% | 9 | 100.00% |
Information contained on this website is for historical information purposes only and does not indicate or represent copyright ownership.