ARCH_DMA_ADDR_T_64BIT is always true for 64-bit architectures now, so we
can skip the clause requiring it. 'n' is the default default, so no need
to explicitly state it.
Signed-off-by: Christoph Hellwig
---
lib/Kconfig | 6 ++
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/li
Hi all,
this series continues consolidating the dma-mapping code, with a focus
on architectures that do not (always) provide cache coherence for DMA.
Three architectures (arm, mips and powerpc) are still left to be
converted later due to complexity of their dma ops selection.
The dma-noncoherent
Add a new dma_map_ops implementation that uses dma-direct for the
address mapping of streaming mappings, and which requires arch-specific
implemenations of coherent allocate/free.
Architectures have to provide flushing helpers to ownership trasnfers
to the device and/or CPU, and can provide option
Switch to the generic noncoherent direct mapping implementation.
Signed-off-by: Christoph Hellwig
---
arch/arc/Kconfig | 4 +
arch/arc/include/asm/Kbuild| 1 +
arch/arc/include/asm/dma-mapping.h | 21 -
arch/arc/mm/dma.c | 141 +++--
Switch to the generic noncoherent direct mapping implementation.
Signed-off-by: Christoph Hellwig
---
arch/c6x/Kconfig | 3 +
arch/c6x/include/asm/Kbuild| 1 +
arch/c6x/include/asm/dma-mapping.h | 28 --
arch/c6x/include/asm/setup.h | 2 +
arch/c6x/kern
Switch to the generic noncoherent direct mapping implementation for
the nommu dma map implementation.
Signed-off-by: Christoph Hellwig
---
arch/arc/Kconfig| 1 +
arch/arm/Kconfig| 4 +
arch/arm/mm/dma-mapping-nommu.c | 139 +---
3 f
Switch to the generic noncoherent direct mapping implementation.
This removes the previous sync_single_for_cpu implementation, which looks
bogus given that no syncing is happening in the similar but more
important unmap_single case.
This adds the previously missing sync_sg_for_device implementati
Switch to the generic noncoherent direct mapping implementation.
Signed-off-by: Christoph Hellwig
---
arch/m68k/Kconfig | 2 +
arch/m68k/include/asm/Kbuild| 1 +
arch/m68k/include/asm/dma-mapping.h | 12 -
arch/m68k/kernel/dma.c | 68 -
Both unused.
Signed-off-by: Christoph Hellwig
---
arch/microblaze/include/asm/pgtable.h | 3 --
arch/microblaze/mm/consistent.c | 45 ---
2 files changed, 48 deletions(-)
diff --git a/arch/microblaze/include/asm/pgtable.h
b/arch/microblaze/include/asm/pgtable.h
i
Switch to the generic noncoherent direct mapping implementation.
This removes the direction-based optimizations in
sync_{single,sg}_for_{cpu,device} which were marked untestested and
do not match the usually very well tested {un,}map_{single,sg}
implementations.
Signed-off-by: Christoph Hellwig
Switch to the generic noncoherent direct mapping implementation.
Signed-off-by: Christoph Hellwig
---
arch/nios2/Kconfig | 3 +
arch/nios2/include/asm/Kbuild| 1 +
arch/nios2/include/asm/dma-mapping.h | 20
arch/nios2/mm/dma-mapping.c | 139 +++---
Switch to the generic noncoherent direct mapping implementation.
This makes sure the cache_sync routines is called in the unmap_sg
case, to match the unmap_single and sync_{single,sg}_to_cpu cases.
Note that this now always uses page_address, as previously done
in the non-sg cache sync routines.
Switch to the generic noncoherent direct mapping implementation.
Fix sync_single_for_device to do the same cache coherency operations as
the more tested map_single path, as both should transfer ownership to
the device.
Remove the sync_single_for_cpu implementation as no cache coherency
operations
Remove the indirection through the dma_ops variable, and just return
nommu_dma_ops directly from get_arch_dma_ops.
Signed-off-by: Christoph Hellwig
---
arch/sh/include/asm/dma-mapping.h | 5 ++---
arch/sh/kernel/dma-nommu.c| 8 +---
arch/sh/mm/consistent.c | 3 ---
arch/
And use it in the maple bus code to avoid a dma API dependency.
Signed-off-by: Christoph Hellwig
---
arch/sh/include/asm/cacheflush.h | 7 +++
arch/sh/mm/consistent.c | 5 +
drivers/sh/maple/maple.c | 7 ---
3 files changed, 12 insertions(+), 7 deletions(-)
diff --g
This is a slight change in behavior as we avoid the detour through the
virtual mapping for the coherent allocator, but if this CPU really is
coherent that should be the right thing to do.
Signed-off-by: Christoph Hellwig
---
arch/sh/Kconfig | 1 +
arch/sh/include/asm/dma-mappin
Half of the file just contains platform device memory setup code which
is required for all builds, and half contains helpers for dma coherent
allocation, which is only needed if CONFIG_DMA_NONCOHERENT is enabled.
Signed-off-by: Christoph Hellwig
---
arch/sh/kernel/Makefile | 2 +-
arch/sh
Switch to the generic noncoherent direct mapping implementation.
Signed-off-by: Christoph Hellwig
---
arch/sh/Kconfig | 3 +-
arch/sh/include/asm/Kbuild| 1 +
arch/sh/include/asm/dma-mapping.h | 26 ---
arch/sh/kernel/Makefile | 2 +-
arch/sh/kernel
Switch to the generic noncoherent direct mapping implementation.
Signed-off-by: Christoph Hellwig
---
arch/xtensa/Kconfig | 3 +
arch/xtensa/include/asm/Kbuild| 1 +
arch/xtensa/include/asm/dma-mapping.h | 26 --
arch/xtensa/kernel/pci-dma.c | 130 +++-
Switch to the generic noncoherent direct mapping implementation.
Parisc previously had two different non-coherent dma ops implementation
that just different in the way coherent allocations were handled or not
handled. The different behavior is not selected at runtime in the
arch_dma_alloc and arc
Switch to the generic noncoherent direct mapping implementation.
This removes the previous sync_single_for_device implementation, which
looks bogus given that no syncing is happening in the similar but more
important map_single case.
Signed-off-by: Christoph Hellwig
---
arch/sparc/Kconfig
On Fri, May 11, 2018 at 09:59:29AM +0200, Christoph Hellwig wrote:
> Switch to the generic noncoherent direct mapping implementation for
> the nommu dma map implementation.
>
> Signed-off-by: Christoph Hellwig
> ---
> arch/arc/Kconfig| 1 +
> arch/arm/Kconfig|
Hi Christoph,
On Fri, 2018-05-11 at 09:59 +0200, Christoph Hellwig wrote:
> Switch to the generic noncoherent direct mapping implementation.
>
> Signed-off-by: Christoph Hellwig
> ---
> arch/arc/Kconfig | 4 +
> arch/arc/include/asm/Kbuild| 1 +
> arch/arc/include/
On 11/05/2018 08:59, Christoph Hellwig wrote:
Switch to the generic noncoherent direct mapping implementation for
the nommu dma map implementation.
Signed-off-by: Christoph Hellwig
---
arch/arc/Kconfig| 1 +
arch/arm/Kconfig| 4 +
arch/arm/mm/dma-mapping-nom
24 matches
Mail list logo