Merge tag 'seabios-20211203-pull-request' of git://git.kraxel.org/qemu into staging
[qemu.git] / include / hw / acpi / bios-linker-loader.h
1 #ifndef BIOS_LINKER_LOADER_H
2 #define BIOS_LINKER_LOADER_H
3
4
5 typedef struct BIOSLinker {
6 GArray *cmd_blob;
7 GArray *file_list;
8 } BIOSLinker;
9
10 bool bios_linker_loader_can_write_pointer(void);
11
12 BIOSLinker *bios_linker_loader_init(void);
13
14 void bios_linker_loader_alloc(BIOSLinker *linker,
15 const char *file_name,
16 GArray *file_blob,
17 uint32_t alloc_align,
18 bool alloc_fseg);
19
20 void bios_linker_loader_add_checksum(BIOSLinker *linker, const char *file,
21 unsigned start_offset, unsigned size,
22 unsigned checksum_offset);
23
24 void bios_linker_loader_add_pointer(BIOSLinker *linker,
25 const char *dest_file,
26 uint32_t dst_patched_offset,
27 uint8_t dst_patched_size,
28 const char *src_file,
29 uint32_t src_offset);
30
31 void bios_linker_loader_write_pointer(BIOSLinker *linker,
32 const char *dest_file,
33 uint32_t dst_patched_offset,
34 uint8_t dst_patched_size,
35 const char *src_file,
36 uint32_t src_offset);
37
38 void bios_linker_loader_cleanup(BIOSLinker *linker);
39 #endif