sdk-core
v2026.11.05
PS2 SDK - core tier (build-critical EE/IOP modules)
Toggle main menu visibility
Loading...
Searching...
No Matches
loadfile-common.h
Go to the documentation of this file.
1
/*
2
# _____ ___ ____ ___ ____
3
# ____| | ____| | | |____|
4
# | ___| |____ ___| ____| | \ PS2DEV Open Source Project.
5
#-----------------------------------------------------------------------
6
# Copyright 2001-2009, ps2dev - http://www.ps2dev.org
7
# Licenced under Academic Free License version 2.0
8
# Review ps2sdk README & LICENSE files for further details.
9
*/
10
12
16
17
#ifndef __LOADFILE_COMMON_H__
18
#define __LOADFILE_COMMON_H__
19
20
#include <
tamtypes.h
>
21
22
// loadfile common definitions
23
24
#define LF_PATH_MAX 252
25
#define LF_ARG_MAX 252
26
27
enum
_lf_val_types {
28
LF_VAL_BYTE = 0,
29
LF_VAL_SHORT,
30
LF_VAL_LONG
31
};
32
33
enum
_lf_functions {
34
LF_F_MOD_LOAD = 0,
35
LF_F_ELF_LOAD,
36
37
LF_F_SET_ADDR,
38
LF_F_GET_ADDR,
39
40
LF_F_MG_MOD_LOAD,
41
LF_F_MG_ELF_LOAD,
42
43
LF_F_MOD_BUF_LOAD,
44
45
LF_F_MOD_STOP,
46
LF_F_MOD_UNLOAD,
47
48
LF_F_SEARCH_MOD_BY_NAME,
49
LF_F_SEARCH_MOD_BY_ADDRESS,
50
51
LF_F_GET_VERSION = 0xFF,
52
};
53
54
typedef
struct
55
{
56
u32 epc;
57
u32 gp;
58
u32 sp;
59
u32 dummy;
60
}
t_ExecData
;
61
62
struct
_lf_iop_val_arg
63
{
64
union
65
{
66
u32 iop_addr;
67
int
result;
68
} p;
69
int
type;
70
union
71
{
72
u8 b;
73
u16 s;
74
u32 l;
75
} val;
76
}
__attribute__
((aligned(16)));
77
78
struct
_lf_module_load_arg
79
{
80
union
81
{
82
int
arg_len;
83
int
result;
84
} p;
85
int
modres;
86
char
path[LF_PATH_MAX];
87
char
args[LF_ARG_MAX];
88
}
__attribute__
((aligned(16)));
89
90
struct
_lf_module_stop_arg
91
{
92
union
93
{
94
int
id;
95
int
result;
96
} p;
97
union
98
{
99
int
arg_len;
100
int
modres;
101
} q;
102
char
dummy[LF_PATH_MAX];
103
char
args[LF_ARG_MAX];
104
}
__attribute__
((aligned(16)));
105
106
union
_lf_module_unload_arg
107
{
108
int
id;
109
int
result;
110
}
__attribute__
((aligned(16)));
111
112
struct
_lf_search_module_by_name_arg
113
{
114
int
id;
115
int
dummy1;
116
char
name[LF_PATH_MAX];
117
char
dummy2[LF_ARG_MAX];
118
}
__attribute__
((aligned(16)));
119
120
struct
_lf_search_module_by_address_arg
121
{
122
union
123
{
124
const
void
*ptr;
125
int
id;
126
} p;
127
}
__attribute__
((aligned(16)));
128
129
struct
_lf_elf_load_arg
130
{
131
u32 epc;
132
u32 gp;
133
char
path[LF_PATH_MAX];
134
char
secname[LF_ARG_MAX];
135
}
__attribute__
((aligned(16)));
136
137
struct
_lf_module_buffer_load_arg
138
{
139
union
140
{
141
void
*ptr;
142
int
result;
143
} p;
144
union
145
{
146
int
arg_len;
147
int
modres;
148
} q;
149
char
unused[LF_PATH_MAX];
150
char
args[LF_ARG_MAX];
151
}
__attribute__
((aligned(16)));
152
153
#endif
__attribute__
Definition
gif_registers.h:40
_lf_elf_load_arg
Definition
loadfile-common.h:130
_lf_iop_val_arg
Definition
loadfile-common.h:63
_lf_module_buffer_load_arg
Definition
loadfile-common.h:138
_lf_module_load_arg
Definition
loadfile-common.h:79
_lf_module_stop_arg
Definition
loadfile-common.h:91
_lf_search_module_by_address_arg
Definition
loadfile-common.h:121
_lf_search_module_by_name_arg
Definition
loadfile-common.h:113
t_ExecData
Definition
loadfile-common.h:55
tamtypes.h
_lf_module_unload_arg
Definition
loadfile-common.h:107
core
common
include
loadfile-common.h
Generated by
1.18.0