From: Catalin Marinas Date: Tue, 13 Jun 2023 15:52:45 +0000 (+0100) Subject: sh: move the ARCH_DMA_MINALIGN definition to asm/cache.h X-Git-Tag: v6.6.17~4568^2~89 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=e6926a4d1c9bfe12814c7c81acd57346285cd7ba;p=platform%2Fkernel%2Flinux-rpi.git sh: move the ARCH_DMA_MINALIGN definition to asm/cache.h The sh architecture defines ARCH_DMA_MINALIGN in asm/page.h. Move it to asm/cache.h to allow a generic ARCH_DMA_MINALIGN definition in linux/cache.h without redefine errors/warnings. Link: https://lkml.kernel.org/r/20230613155245.1228274-4-catalin.marinas@arm.com Signed-off-by: Catalin Marinas Cc: Yoshinori Sato Cc: Rich Felker Cc: John Paul Adrian Glaubitz Cc: Christophe Leroy Cc: kernel test robot Cc: Michael Ellerman Cc: Michal Simek Cc: Nicholas Piggin Cc: Vlastimil Babka Signed-off-by: Andrew Morton --- diff --git a/arch/sh/include/asm/cache.h b/arch/sh/include/asm/cache.h index 32dfa6b..b38dbc97 100644 --- a/arch/sh/include/asm/cache.h +++ b/arch/sh/include/asm/cache.h @@ -14,6 +14,12 @@ #define L1_CACHE_BYTES (1 << L1_CACHE_SHIFT) +/* + * Some drivers need to perform DMA into kmalloc'ed buffers + * and so we have to increase the kmalloc minalign for this. + */ +#define ARCH_DMA_MINALIGN L1_CACHE_BYTES + #define __read_mostly __section(".data..read_mostly") #ifndef __ASSEMBLY__ diff --git a/arch/sh/include/asm/page.h b/arch/sh/include/asm/page.h index 09ac6c7..62f4b9e 100644 --- a/arch/sh/include/asm/page.h +++ b/arch/sh/include/asm/page.h @@ -174,10 +174,4 @@ typedef struct page *pgtable_t; #include #include -/* - * Some drivers need to perform DMA into kmalloc'ed buffers - * and so we have to increase the kmalloc minalign for this. - */ -#define ARCH_DMA_MINALIGN L1_CACHE_BYTES - #endif /* __ASM_SH_PAGE_H */