bios-linker-loader.h (1500B)
1#ifndef BIOS_LINKER_LOADER_H 2#define BIOS_LINKER_LOADER_H 3 4 5typedef struct BIOSLinker { 6 GArray *cmd_blob; 7 GArray *file_list; 8} BIOSLinker; 9 10bool bios_linker_loader_can_write_pointer(void); 11 12BIOSLinker *bios_linker_loader_init(void); 13 14void 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 20void bios_linker_loader_add_checksum(BIOSLinker *linker, const char *file, 21 unsigned start_offset, unsigned size, 22 unsigned checksum_offset); 23 24void 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 31void 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 38void bios_linker_loader_cleanup(BIOSLinker *linker); 39#endif