2018-07-19 11:11:28 +00:00
|
|
|
/* SPDX-License-Identifier: GPL-2.0 */
|
|
|
|
#ifndef BOOT_BOOT_H
|
|
|
|
#define BOOT_BOOT_H
|
|
|
|
|
2021-06-30 15:17:53 +00:00
|
|
|
#include <linux/types.h>
|
2020-11-10 16:05:26 +00:00
|
|
|
|
2022-04-27 02:14:34 +00:00
|
|
|
#define IPL_START 0x200
|
|
|
|
|
|
|
|
#ifndef __ASSEMBLY__
|
|
|
|
|
2022-12-04 20:15:41 +00:00
|
|
|
struct machine_info {
|
|
|
|
unsigned char has_edat1 : 1;
|
|
|
|
unsigned char has_edat2 : 1;
|
|
|
|
unsigned char has_nx : 1;
|
|
|
|
};
|
|
|
|
|
2022-05-05 14:54:54 +00:00
|
|
|
struct vmlinux_info {
|
|
|
|
unsigned long default_lma;
|
|
|
|
void (*entry)(void);
|
|
|
|
unsigned long image_size; /* does not include .bss */
|
|
|
|
unsigned long bss_size; /* uncompressed image .bss size */
|
|
|
|
unsigned long bootdata_off;
|
|
|
|
unsigned long bootdata_size;
|
|
|
|
unsigned long bootdata_preserved_off;
|
|
|
|
unsigned long bootdata_preserved_size;
|
|
|
|
unsigned long dynsym_start;
|
|
|
|
unsigned long rela_dyn_start;
|
|
|
|
unsigned long rela_dyn_end;
|
|
|
|
unsigned long amode31_size;
|
|
|
|
};
|
|
|
|
|
2018-07-19 11:11:28 +00:00
|
|
|
void startup_kernel(void);
|
2020-10-19 09:01:33 +00:00
|
|
|
unsigned long detect_memory(void);
|
|
|
|
bool is_ipl_block_dump(void);
|
2018-05-15 11:28:53 +00:00
|
|
|
void store_ipl_parmblock(void);
|
2022-05-05 14:54:54 +00:00
|
|
|
unsigned long read_ipl_report(unsigned long safe_offset);
|
2018-05-15 11:28:53 +00:00
|
|
|
void setup_boot_command_line(void);
|
2019-02-27 15:52:42 +00:00
|
|
|
void parse_boot_command_line(void);
|
2019-07-17 17:38:42 +00:00
|
|
|
void verify_facilities(void);
|
2019-02-27 16:36:35 +00:00
|
|
|
void print_missing_facilities(void);
|
2020-11-05 12:09:06 +00:00
|
|
|
void sclp_early_setup_buffer(void);
|
2019-08-08 18:09:08 +00:00
|
|
|
void print_pgm_check_info(void);
|
2019-02-03 20:37:20 +00:00
|
|
|
unsigned long get_random_base(unsigned long safe_addr);
|
2020-11-10 16:05:26 +00:00
|
|
|
void __printf(1, 2) decompressor_printk(const char *fmt, ...);
|
2022-05-05 14:54:54 +00:00
|
|
|
void error(char *m);
|
2019-02-03 20:37:20 +00:00
|
|
|
|
2022-12-04 20:15:41 +00:00
|
|
|
extern struct machine_info machine;
|
|
|
|
|
2021-06-30 15:12:25 +00:00
|
|
|
/* Symbols defined by linker scripts */
|
2019-07-15 13:30:33 +00:00
|
|
|
extern const char kernel_version[];
|
2020-10-19 09:01:33 +00:00
|
|
|
extern unsigned long memory_limit;
|
2020-10-06 20:12:39 +00:00
|
|
|
extern unsigned long vmalloc_size;
|
2020-10-19 09:01:33 +00:00
|
|
|
extern int vmalloc_size_set;
|
|
|
|
extern int kaslr_enabled;
|
2021-06-30 15:12:25 +00:00
|
|
|
extern char __boot_data_start[], __boot_data_end[];
|
|
|
|
extern char __boot_data_preserved_start[], __boot_data_preserved_end[];
|
|
|
|
extern char _decompressor_syms_start[], _decompressor_syms_end[];
|
2021-06-30 15:17:53 +00:00
|
|
|
extern char _stack_start[], _stack_end[];
|
2022-05-05 14:54:54 +00:00
|
|
|
extern char _end[];
|
|
|
|
extern unsigned char _compressed_start[];
|
|
|
|
extern unsigned char _compressed_end[];
|
|
|
|
extern struct vmlinux_info _vmlinux_info;
|
|
|
|
#define vmlinux _vmlinux_info
|
2019-02-21 13:23:04 +00:00
|
|
|
|
2022-04-27 02:14:34 +00:00
|
|
|
#endif /* __ASSEMBLY__ */
|
2018-07-19 11:11:28 +00:00
|
|
|
#endif /* BOOT_BOOT_H */
|