smp.h 1.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. /* smp.h: Sparc64 specific SMP stuff.
  2. *
  3. * Copyright (C) 1996 David S. Miller (davem@caip.rutgers.edu)
  4. */
  5. #ifndef _SPARC64_SMP_H
  6. #define _SPARC64_SMP_H
  7. #include <linux/config.h>
  8. #include <linux/threads.h>
  9. #include <asm/asi.h>
  10. #include <asm/starfire.h>
  11. #include <asm/spitfire.h>
  12. #ifndef __ASSEMBLY__
  13. #include <linux/cpumask.h>
  14. #include <linux/cache.h>
  15. #endif /* !(__ASSEMBLY__) */
  16. #ifdef CONFIG_SMP
  17. #ifndef __ASSEMBLY__
  18. /*
  19. * Private routines/data
  20. */
  21. #include <asm/bitops.h>
  22. #include <asm/atomic.h>
  23. extern cpumask_t phys_cpu_present_map;
  24. #define cpu_possible_map phys_cpu_present_map
  25. extern cpumask_t cpu_sibling_map[NR_CPUS];
  26. /*
  27. * General functions that each host system must provide.
  28. */
  29. extern int hard_smp_processor_id(void);
  30. #define raw_smp_processor_id() (current_thread_info()->cpu)
  31. extern void smp_setup_cpu_possible_map(void);
  32. #endif /* !(__ASSEMBLY__) */
  33. #else
  34. #define smp_setup_cpu_possible_map() do { } while (0)
  35. #endif /* !(CONFIG_SMP) */
  36. #define NO_PROC_ID 0xFF
  37. #endif /* !(_SPARC64_SMP_H) */