cpu-feature-overrides.h 950 B

123456789101112131415161718192021222324252627282930313233343536
  1. /*
  2. * This file is subject to the terms and conditions of the GNU General Public
  3. * License. See the file "COPYING" in the main directory of this archive
  4. * for more details.
  5. *
  6. * Copyright (C) 2013 Cavium, Inc.
  7. */
  8. #ifndef __ASM_MACH_PARAVIRT_CPU_FEATURE_OVERRIDES_H
  9. #define __ASM_MACH_PARAVIRT_CPU_FEATURE_OVERRIDES_H
  10. #define cpu_has_4kex 1
  11. #define cpu_has_3k_cache 0
  12. #define cpu_has_tx39_cache 0
  13. #define cpu_has_counter 1
  14. #define cpu_has_llsc 1
  15. /*
  16. * We Disable LL/SC on non SMP systems as it is faster to disable
  17. * interrupts for atomic access than a LL/SC.
  18. */
  19. #ifdef CONFIG_SMP
  20. # define kernel_uses_llsc 1
  21. #else
  22. # define kernel_uses_llsc 0
  23. #endif
  24. #ifdef CONFIG_CPU_CAVIUM_OCTEON
  25. #define cpu_dcache_line_size() 128
  26. #define cpu_icache_line_size() 128
  27. #define cpu_has_octeon_cache 1
  28. #define cpu_has_4k_cache 0
  29. #else
  30. #define cpu_has_octeon_cache 0
  31. #define cpu_has_4k_cache 1
  32. #endif
  33. #endif /* __ASM_MACH_PARAVIRT_CPU_FEATURE_OVERRIDES_H */