setup.h 2.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091
  1. #ifndef _ASM_X86_SETUP_H
  2. #define _ASM_X86_SETUP_H
  3. #define COMMAND_LINE_SIZE 2048
  4. #ifndef __ASSEMBLY__
  5. /* Interrupt control for vSMPowered x86_64 systems */
  6. void vsmp_init(void);
  7. #ifdef CONFIG_X86_VISWS
  8. extern void visws_early_detect(void);
  9. extern int is_visws_box(void);
  10. #else
  11. static inline void visws_early_detect(void) { }
  12. static inline int is_visws_box(void) { return 0; }
  13. #endif
  14. /*
  15. * Any setup quirks to be performed?
  16. */
  17. struct x86_quirks {
  18. int (*arch_time_init)(void);
  19. int (*arch_pre_intr_init)(void);
  20. int (*arch_intr_init)(void);
  21. int (*arch_trap_init)(void);
  22. char * (*arch_memory_setup)(void);
  23. int (*mach_get_smp_config)(unsigned int early);
  24. int (*mach_find_smp_config)(unsigned int reserve);
  25. };
  26. extern struct x86_quirks *x86_quirks;
  27. #ifndef CONFIG_PARAVIRT
  28. #define paravirt_post_allocator_init() do {} while (0)
  29. #endif
  30. #endif /* __ASSEMBLY__ */
  31. #ifdef __KERNEL__
  32. #ifdef __i386__
  33. #include <linux/pfn.h>
  34. /*
  35. * Reserved space for vmalloc and iomap - defined in asm/page.h
  36. */
  37. #define MAXMEM_PFN PFN_DOWN(MAXMEM)
  38. #define MAX_NONPAE_PFN (1 << 20)
  39. #endif /* __i386__ */
  40. #define PARAM_SIZE 4096 /* sizeof(struct boot_params) */
  41. #define OLD_CL_MAGIC 0xA33F
  42. #define OLD_CL_ADDRESS 0x020 /* Relative to real mode data */
  43. #define NEW_CL_POINTER 0x228 /* Relative to real mode data */
  44. #ifndef __ASSEMBLY__
  45. #include <asm/bootparam.h>
  46. #ifndef _SETUP
  47. /*
  48. * This is set up by the setup-routine at boot-time
  49. */
  50. extern struct boot_params boot_params;
  51. /*
  52. * Do NOT EVER look at the BIOS memory size location.
  53. * It does not work on many machines.
  54. */
  55. #define LOWMEMSIZE() (0x9f000)
  56. #ifdef __i386__
  57. void __init i386_start_kernel(void);
  58. extern void probe_roms(void);
  59. extern unsigned long init_pg_tables_start;
  60. extern unsigned long init_pg_tables_end;
  61. #else
  62. void __init x86_64_start_kernel(char *real_mode);
  63. void __init x86_64_start_reservations(char *real_mode_data);
  64. #endif /* __i386__ */
  65. #endif /* _SETUP */
  66. #endif /* __ASSEMBLY__ */
  67. #endif /* __KERNEL__ */
  68. #endif /* _ASM_X86_SETUP_H */