PS2SDK
PS2 Homebrew Libraries
Loading...
Searching...
No Matches
erl.h File Reference
#include <tamtypes.h>
+ Include dependency graph for erl.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  erl_record_t
 
struct  symbol_t
 

Macros

#define ERL_FLAG_STICKY   1
 
#define ERL_FLAG_STATIC   2
 
#define ERL_FLAG_CLEAR   4
 
#define ERL_DYN_ADDR   0
 

Typedefs

typedef struct erl_record_t *(* erl_loader_t) (char *erl_id)
 

Functions

struct erl_record_tload_erl_from_mem (u8 *mem, int argc, char **argv)
 
struct erl_record_tload_erl_from_file (const char *fname, int argc, char **argv)
 
struct erl_record_t_init_load_erl_from_file (const char *fname, char *erl_id)
 
struct erl_record_tload_erl_from_mem_to_addr (u8 *mem, u32 addr, int argc, char **argv)
 
struct erl_record_tload_erl_from_file_to_addr (const char *fname, u32 addr, int argc, char **argv)
 
struct erl_record_t_init_load_erl_from_file_to_addr (const char *fname, u32 addr, char *erl_id)
 
int unload_erl (struct erl_record_t *erl)
 
int erl_add_global_symbol (const char *symbol, u32 address)
 
struct erl_record_tfind_erl (const char *name)
 
struct erl_record_terl_resolve (u32 address)
 
struct symbol_terl_find_local_symbol (const char *symbol, struct erl_record_t *erl)
 
struct symbol_terl_find_symbol (const char *symbol)
 
void erl_flush_symbols (struct erl_record_t *erl)
 

Variables

char _init_erl_prefix []
 
erl_loader_t _init_load_erl
 

Detailed Description

The relocatable elf loader/linker.

Definition in file erl.h.


Data Structure Documentation

◆ erl_record_t

struct erl_record_t

Definition at line 30 of file erl.h.

+ Collaboration diagram for erl_record_t:
Data Fields
u8 * bytes
u32 fullsize
char * name
char ** dependancies
u32 flags
struct htab * symbols
struct erl_record_t * next
struct erl_record_t * prev

◆ symbol_t

struct symbol_t

Definition at line 42 of file erl.h.

+ Collaboration diagram for symbol_t:
Data Fields
struct erl_record_t * provider
u32 address

Macro Definition Documentation

◆ ERL_FLAG_STICKY

#define ERL_FLAG_STICKY   1

ERL is sticky and cannot be unloaded

Definition at line 24 of file erl.h.

◆ ERL_FLAG_STATIC

#define ERL_FLAG_STATIC   2

ERL is relocated at a static memory address; set by *_to_addr functions

Definition at line 26 of file erl.h.

◆ ERL_FLAG_CLEAR

#define ERL_FLAG_CLEAR   4

Clear ERL bytes on unload

Definition at line 28 of file erl.h.

◆ ERL_DYN_ADDR

#define ERL_DYN_ADDR   0

Definition at line 66 of file erl.h.

Typedef Documentation

◆ erl_loader_t

typedef struct erl_record_t *(* erl_loader_t) (char *erl_id)

Definition at line 51 of file erl.h.

Function Documentation

◆ load_erl_from_mem()

struct erl_record_t * load_erl_from_mem ( u8 *  mem,
int  argc,
char **  argv 
)

Definition at line 1039 of file erl.c.

◆ load_erl_from_file()

struct erl_record_t * load_erl_from_file ( const char *  fname,
int  argc,
char **  argv 
)

Definition at line 1035 of file erl.c.

◆ _init_load_erl_from_file()

struct erl_record_t * _init_load_erl_from_file ( const char *  fname,
char *  erl_id 
)

Definition at line 1016 of file erl.c.

◆ load_erl_from_mem_to_addr()

struct erl_record_t * load_erl_from_mem_to_addr ( u8 *  mem,
u32  addr,
int  argc,
char **  argv 
)

Definition at line 1046 of file erl.c.

◆ load_erl_from_file_to_addr()

struct erl_record_t * load_erl_from_file_to_addr ( const char *  fname,
u32  addr,
int  argc,
char **  argv 
)

Definition at line 1053 of file erl.c.

◆ _init_load_erl_from_file_to_addr()

struct erl_record_t * _init_load_erl_from_file_to_addr ( const char *  fname,
u32  addr,
char *  erl_id 
)

Definition at line 1060 of file erl.c.

◆ unload_erl()

int unload_erl ( struct erl_record_t erl)

Definition at line 1090 of file erl.c.

◆ erl_add_global_symbol()

int erl_add_global_symbol ( const char *  symbol,
u32  address 
)

Definition at line 578 of file erl.c.

◆ find_erl()

struct erl_record_t * find_erl ( const char *  name)

Definition at line 1139 of file erl.c.

◆ erl_resolve()

struct erl_record_t * erl_resolve ( u32  address)

Definition at line 1127 of file erl.c.

◆ erl_find_local_symbol()

struct symbol_t * erl_find_local_symbol ( const char *  symbol,
struct erl_record_t erl 
)

Definition at line 431 of file erl.c.

◆ erl_find_symbol()

struct symbol_t * erl_find_symbol ( const char *  symbol)

Definition at line 447 of file erl.c.

◆ erl_flush_symbols()

void erl_flush_symbols ( struct erl_record_t erl)

Definition at line 1151 of file erl.c.

Variable Documentation

◆ _init_erl_prefix

char _init_erl_prefix[]
extern

Definition at line 285 of file erl.c.

◆ _init_load_erl

erl_loader_t _init_load_erl
extern

Definition at line 942 of file erl.c.