cache.h 723 B

12345678910111213141516171819202122232425
  1. /*
  2. * (C) Copyright 2004, Psyent Corporation <www.psyent.com>
  3. * Scott McNutt <smcnutt@psyent.com>
  4. *
  5. * SPDX-License-Identifier: GPL-2.0+
  6. */
  7. #ifndef __ASM_NIOS2_CACHE_H_
  8. #define __ASM_NIOS2_CACHE_H_
  9. extern void flush_dcache (unsigned long start, unsigned long size);
  10. extern void flush_icache (unsigned long start, unsigned long size);
  11. /*
  12. * Valid L1 data cache line sizes for the NIOS2 architecture are 4, 16, and 32
  13. * bytes. If the board configuration has not specified one we default to the
  14. * largest of these values for alignment of DMA buffers.
  15. */
  16. #ifdef CONFIG_SYS_CACHELINE_SIZE
  17. #define ARCH_DMA_MINALIGN CONFIG_SYS_CACHELINE_SIZE
  18. #else
  19. #define ARCH_DMA_MINALIGN 32
  20. #endif
  21. #endif /* __ASM_NIOS2_CACHE_H_ */