PS2SDK
PS2 Homebrew Libraries
Loading...
Searching...
No Matches
thfpool.h
Go to the documentation of this file.
1
/*
2
# _____ ___ ____ ___ ____
3
# ____| | ____| | | |____|
4
# | ___| |____ ___| ____| | \ PS2DEV Open Source Project.
5
#-----------------------------------------------------------------------
6
# Copyright 2001-2004, 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
16
#ifndef __THFPOOL_H__
17
#define __THFPOOL_H__
18
19
#include <types.h>
20
#include <
irx.h
>
21
22
#ifdef __cplusplus
23
extern
"C"
{
24
#endif
25
26
// Fixed-length pool attributes
27
#define FA_THFIFO 0x000
28
#define FA_THPRI 0x001
29
#define FA_MEMBTM 0x200
30
31
/*
32
* Fixed length memory pool
33
*/
34
35
typedef
struct
_iop_fpl_param
36
{
37
unsigned
int
attr;
38
unsigned
int
option;
39
int
block_size;
40
int
blocks;
41
}
iop_fpl_param
;
42
43
typedef
struct
_iop_fpl_info
44
{
45
unsigned
int
attr;
46
unsigned
int
option;
47
int
blockSize;
48
int
numBlocks;
49
int
freeBlocks;
50
int
numWaitThreads;
51
int
reserved[4];
52
}
iop_fpl_info_t
;
53
54
extern
int
CreateFpl(
iop_fpl_param
*param);
55
extern
int
DeleteFpl(
int
fplId);
56
extern
void
*AllocateFpl(
int
fplId);
57
extern
void
*pAllocateFpl(
int
fplId);
58
extern
void
*ipAllocateFpl(
int
fplId);
59
extern
int
FreeFpl(
int
fplId,
void
*memory);
60
extern
int
ReferFplStatus(
int
fplId,
iop_fpl_info_t
*
info
);
61
extern
int
iReferFplStatus(
int
fplId,
iop_fpl_info_t
*
info
);
62
63
#define thfpool_IMPORTS_start DECLARE_IMPORT_TABLE(thfpool, 1, 1)
64
#define thfpool_IMPORTS_end END_IMPORT_TABLE
65
66
#define I_CreateFpl DECLARE_IMPORT(4, CreateFpl)
67
#define I_DeleteFpl DECLARE_IMPORT(5, DeleteFpl)
68
#define I_AllocateFpl DECLARE_IMPORT(6, AllocateFpl)
69
#define I_pAllocateFpl DECLARE_IMPORT(7, pAllocateFpl)
70
#define I_ipAllocateFpl DECLARE_IMPORT(8, ipAllocateFpl)
71
#define I_FreeFpl DECLARE_IMPORT(9, FreeFpl)
72
#define I_ReferFplStatus DECLARE_IMPORT(11, ReferFplStatus)
73
#define I_iReferFplStatus DECLARE_IMPORT(12, iReferFplStatus)
74
75
#ifdef __cplusplus
76
}
77
#endif
78
79
#endif
/* __THFPOOL_H__ */
irx.h
s_info
Definition
xprintf.c:78
_iop_fpl_info
Definition
thfpool.h:44
_iop_fpl_param
Definition
thfpool.h:36
iop
system
threadman
include
thfpool.h
Generated on Mon Jan 20 2025 17:33:27 for PS2SDK by
1.9.8