1 #ifndef _ASM_X86_SETUP_H
2 #define _ASM_X86_SETUP_H
4 #include <uapi/asm/setup.h>
7 #define COMMAND_LINE_SIZE 2048
11 #include <linux/pfn.h>
13 * Reserved space for vmalloc and iomap - defined in asm/page.h
15 #define MAXMEM_PFN PFN_DOWN(MAXMEM)
16 #define MAX_NONPAE_PFN (1 << 20)
20 #define PARAM_SIZE 4096 /* sizeof(struct boot_params) */
22 #define OLD_CL_MAGIC 0xA33F
23 #define OLD_CL_ADDRESS 0x020 /* Relative to real mode data */
24 #define NEW_CL_POINTER 0x228 /* Relative to real mode data */
27 #include <asm/bootparam.h>
28 #include <asm/x86_init.h>
30 /* Interrupt control for vSMPowered x86_64 systems */
34 static inline void vsmp_init(void) { }
37 void setup_bios_corruption_check(void);
39 #ifdef CONFIG_X86_VISWS
40 extern void visws_early_detect(void);
42 static inline void visws_early_detect(void) { }
45 extern unsigned long saved_video_mode
;
47 extern void reserve_standard_io_resources(void);
48 extern void i386_reserve_resources(void);
49 extern void setup_default_timer_irq(void);
51 #ifdef CONFIG_X86_INTEL_MID
52 extern void x86_mrst_early_setup(void);
54 static inline void x86_mrst_early_setup(void) { }
57 #ifdef CONFIG_X86_INTEL_CE
58 extern void x86_ce4100_early_setup(void);
60 static inline void x86_ce4100_early_setup(void) { }
66 * This is set up by the setup-routine at boot-time
68 extern struct boot_params boot_params
;
71 * Do NOT EVER look at the BIOS memory size location.
72 * It does not work on many machines.
74 #define LOWMEMSIZE() (0x9f000)
76 /* exceedingly early brk-like allocator */
77 extern unsigned long _brk_end
;
78 void *extend_brk(size_t size
, size_t align
);
81 * Reserve space in the brk section. The name must be unique within
82 * the file, and somewhat descriptive. The size is in bytes. Must be
85 * (This uses a temp function to wrap the asm so we can pass it the
86 * size parameter; otherwise we wouldn't be able to. We can't use a
87 * "section" attribute on a normal variable because it always ends up
88 * being @progbits, which ends up allocating space in the vmlinux
91 #define RESERVE_BRK(name,sz) \
92 static void __section(.discard.text) __used notrace \
93 __brk_reservation_fn_##name##__(void) { \
95 ".pushsection .brk_reservation,\"aw\",@nobits;" \
98 " .size .brk." #name ", . - 1b;" \
103 /* Helper for reserving space for arrays of things */
104 #define RESERVE_BRK_ARRAY(type, name, entries) \
106 RESERVE_BRK(name, sizeof(type) * entries)
108 extern void probe_roms(void);
111 void __init
i386_start_kernel(void);
114 void __init
x86_64_start_kernel(char *real_mode
);
115 void __init
x86_64_start_reservations(char *real_mode_data
);
117 #endif /* __i386__ */
120 #define RESERVE_BRK(name,sz) \
121 .pushsection .brk_reservation,"aw",@nobits; \
124 .size .brk.name,.-1b; \
126 #endif /* __ASSEMBLY__ */
127 #endif /* _ASM_X86_SETUP_H */