diff options
author | Christoph Hellwig <hch@lst.de> | 2020-02-21 15:55:43 -0800 |
---|---|---|
committer | Christoph Hellwig <hch@lst.de> | 2020-03-16 10:48:09 +0100 |
commit | fa7e2247c5729f990c7456fe09f3af99c8f2571b (patch) | |
tree | 65aa46af4ff51a93301caca46b509c34267bfe40 /arch/microblaze | |
parent | 3d0fc341c4bb66b2c41c0d1ec954a6d300e100b7 (diff) | |
download | linux-fa7e2247c5729f990c7456fe09f3af99c8f2571b.tar.gz linux-fa7e2247c5729f990c7456fe09f3af99c8f2571b.tar.bz2 linux-fa7e2247c5729f990c7456fe09f3af99c8f2571b.zip |
dma-direct: make uncached_kernel_address more general
Rename the symbol to arch_dma_set_uncached, and pass a size to it as
well as allow an error return. That will allow reusing this hook for
in-place pagetable remapping.
As the in-place remap doesn't always require an explicit cache flush,
also detangle ARCH_HAS_DMA_PREP_COHERENT from ARCH_HAS_DMA_SET_UNCACHED.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Robin Murphy <robin.murphy@arm.com>
Diffstat (limited to 'arch/microblaze')
-rw-r--r-- | arch/microblaze/Kconfig | 2 | ||||
-rw-r--r-- | arch/microblaze/mm/consistent.c | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/arch/microblaze/Kconfig b/arch/microblaze/Kconfig index 6a331bd57ea8..9606c244b5b8 100644 --- a/arch/microblaze/Kconfig +++ b/arch/microblaze/Kconfig @@ -8,7 +8,7 @@ config MICROBLAZE select ARCH_HAS_GCOV_PROFILE_ALL select ARCH_HAS_SYNC_DMA_FOR_CPU select ARCH_HAS_SYNC_DMA_FOR_DEVICE - select ARCH_HAS_UNCACHED_SEGMENT if !MMU + select ARCH_HAS_DMA_SET_UNCACHED if !MMU select ARCH_MIGHT_HAVE_PC_PARPORT select ARCH_WANT_IPC_PARSE_VERSION select BUILDTIME_TABLE_SORT diff --git a/arch/microblaze/mm/consistent.c b/arch/microblaze/mm/consistent.c index cede7c5e8135..e09b66e43cb6 100644 --- a/arch/microblaze/mm/consistent.c +++ b/arch/microblaze/mm/consistent.c @@ -40,7 +40,7 @@ void arch_dma_prep_coherent(struct page *page, size_t size) #define UNCACHED_SHADOW_MASK 0 #endif /* CONFIG_XILINX_UNCACHED_SHADOW */ -void *uncached_kernel_address(void *ptr) +void *arch_dma_set_uncached(void *ptr, size_t size) { unsigned long addr = (unsigned long)ptr; |