numa_64.h 1.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. #ifndef _ASM_X86_NUMA_64_H
  2. #define _ASM_X86_NUMA_64_H
  3. #include <linux/nodemask.h>
  4. struct bootnode {
  5. u64 start;
  6. u64 end;
  7. };
  8. extern int compute_hash_shift(struct bootnode *nodes, int numblks,
  9. int *nodeids);
  10. #define ZONE_ALIGN (1UL << (MAX_ORDER+PAGE_SHIFT))
  11. extern int numa_off;
  12. extern unsigned long numa_free_all_bootmem(void);
  13. extern void setup_node_bootmem(int nodeid, unsigned long start,
  14. unsigned long end);
  15. #ifdef CONFIG_NUMA
  16. /*
  17. * Too small node sizes may confuse the VM badly. Usually they
  18. * result from BIOS bugs. So dont recognize nodes as standalone
  19. * NUMA entities that have less than this amount of RAM listed:
  20. */
  21. #define NODE_MIN_SIZE (4*1024*1024)
  22. extern int __cpuinit numa_cpu_node(int cpu);
  23. #ifdef CONFIG_NUMA_EMU
  24. #define FAKE_NODE_MIN_SIZE ((u64)32 << 20)
  25. #define FAKE_NODE_MIN_HASH_MASK (~(FAKE_NODE_MIN_SIZE - 1UL))
  26. void numa_emu_cmdline(char *);
  27. #endif /* CONFIG_NUMA_EMU */
  28. #else
  29. static inline int numa_cpu_node(int cpu) { return NUMA_NO_NODE; }
  30. #endif
  31. #endif /* _ASM_X86_NUMA_64_H */