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 BIOSLinker *bios_linker_loader_init(void); 11 12 void bios_linker_loader_alloc(BIOSLinker *linker, 13 const char *file_name, 14 GArray *file_blob, 15 uint32_t alloc_align, 16 bool alloc_fseg); 17 18 void bios_linker_loader_add_checksum(BIOSLinker *linker, const char *file, 19 unsigned start_offset, unsigned size, 20 unsigned checksum_offset); 21 22 void bios_linker_loader_add_pointer(BIOSLinker *linker, 23 const char *dest_file, 24 uint32_t dst_patched_offset, 25 uint8_t dst_patched_size, 26 const char *src_file, 27 uint32_t src_offset); 28 29 void bios_linker_loader_write_pointer(BIOSLinker *linker, 30 const char *dest_file, 31 uint32_t dst_patched_offset, 32 uint8_t dst_patched_size, 33 const char *src_file, 34 uint32_t src_offset); 35 36 void bios_linker_loader_cleanup(BIOSLinker *linker); 37 #endif 38