x86: cache.h: Add default for CONFIG_SYS_CACHELINE_SIZE
PATCH 1/1 x86: cache.h: Add default for CONFIG_SYS_CACHELINE_SIZE
Don't just define ARCH_DMA_MINALIGN but also CONFIG_SYS_CACHELINE_SIZE if its undefined. This is needed for the xhci driver to compile.
Signed-off-by Stefan Roese <[email protected]>
Cc Simon Glass <[email protected]>
Cc Bin Meng <[email protected]>
--- arch/x86/include/asm/cache.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-)
arch/x86/include/asm/cache.h +4 -4
@@ -11,12 +11,12 @@* If CONFIG_SYS_CACHELINE_SIZE is defined use it for DMA alignment. Otherwise * use 64-bytes, a safe default for x86. */ -#ifdef CONFIG_SYS_CACHELINE_SIZE -#define ARCH_DMA_MINALIGN CONFIG_SYS_CACHELINE_SIZE -#else -#define ARCH_DMA_MINALIGN 64 +#ifndef CONFIG_SYS_CACHELINE_SIZE +#define CONFIG_SYS_CACHELINE_SIZE 64#endif +#define ARCH_DMA_MINALIGN CONFIG_SYS_CACHELINE_SIZE +static inline void wbinvd (void ) { asmvolatile ("wbinvd" : : :"memory" );
Signature · 1 line
2.9.2
PATCH 1/1 x86: cache.h: Add default for CONFIG_SYS_CACHELINE_SIZE
Quoted 2 lines · Stefan Roese
Don't just define
ARCH_DMA_MINALIGNbut alsoCONFIG_SYS_CACHELINE_SIZEif its undefined. This is needed for the xhci driver to compile.
nits: it's
I can fix this when applying.
Quoted 8 lines
Signed-off-by Stefan Roese <[email protected]>Cc Simon Glass <[email protected]>Cc Bin Meng <[email protected]>--- arch/x86/include/asm/cache.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-)
Reviewed-by Bin Meng <[email protected]>
PATCH 1/1 x86: cache.h: Add default for CONFIG_SYS_CACHELINE_SIZE
Quoted 7 lines · Bin Meng
Quoted 2 lines · Stefan Roese
Don't just define
ARCH_DMA_MINALIGNbut alsoCONFIG_SYS_CACHELINE_SIZEif its undefined. This is needed for the xhci driver to compile.nits: it's
I can fix this when applying.
Fixed this, and
Quoted 11 lines
Quoted 9 lines
Signed-off-by Stefan Roese <[email protected]>Cc Simon Glass <[email protected]>Cc Bin Meng <[email protected]>--- arch/x86/include/asm/cache.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-)Reviewed-by Bin Meng <[email protected]>
applied to u-boot-x86, thanks!