diff options
author | Cyrille Bagard <nocbos@gmail.com> | 2018-01-29 22:49:43 (GMT) |
---|---|---|
committer | Cyrille Bagard <nocbos@gmail.com> | 2018-01-29 22:49:43 (GMT) |
commit | 896b31fbbef2fba442566a422fa4d409771b61dd (patch) | |
tree | b75725f043d54e5a454216a11d89018956ee9c26 /plugins/elf/elf-int.h | |
parent | 6c51b9eed427fd55ce1457834853386cc8d543cd (diff) |
Introduced specific operations for ELF architectures.
Diffstat (limited to 'plugins/elf/elf-int.h')
-rw-r--r-- | plugins/elf/elf-int.h | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/plugins/elf/elf-int.h b/plugins/elf/elf-int.h index 3b4b67c..291000d 100644 --- a/plugins/elf/elf-int.h +++ b/plugins/elf/elf-int.h @@ -34,6 +34,27 @@ +/* Fournit la description humaine d'un type de segment ELF. */ +typedef const char * (* get_elf_prgm_type_desc_cb) (uint32_t); + +/* Fournit une adresse virtuelle prête à emploi. */ +typedef virt_t (* fix_elf_virt_addr_cb) (virt_t); + +/* Retrouve le décalage appliqué lors d'une résolution. */ +typedef bool (* get_elf_linkage_offset_cb) (GElfFormat *, const mrange_t *, uint64_t *); + + + +/* Particularités propre aux architectures */ +typedef struct _elf_arch_ops +{ + get_elf_prgm_type_desc_cb get_type_desc;/* Description de type */ + fix_elf_virt_addr_cb fix_virt; /* Retire toute forme d'infos */ + get_elf_linkage_offset_cb get_linkage_offset; /* Décalage de relocation*/ + +} elf_arch_ops; + + /* Format d'exécutable générique (instance) */ struct _GElfFormat { @@ -43,6 +64,8 @@ struct _GElfFormat bool is_32b; /* Format du binaire */ SourceEndian endian; /* Boutisme du format */ + elf_arch_ops ops; /* Opérations spécifiques */ + }; /* Format d'exécutable générique (classe) */ |