sdk-core
v2026.11.05
PS2 SDK - core tier (build-critical EE/IOP modules)
Toggle main menu visibility
Loading...
Searching...
No Matches
api.c
1
#include <
stdio.h
>
2
#include <errno.h>
3
4
#ifdef WIN32
5
#include <memory.h>
6
#include <
string.h
>
7
#include <
stdlib.h
>
8
#else
9
#include <
cdvdman.h
>
10
#include <
sysclib.h
>
11
#endif
12
13
#include <
usbhdfsd.h
>
14
#include "
usbhd_common.h
"
15
#include "
scache.h
"
16
#include "
mass_stor.h
"
17
18
// #define DEBUG //comment out this line when not debugging
19
20
#include "
mass_debug.h
"
21
22
#define READ_SECTOR(d, a, b) scache_readSector((d)->cache, (a), (b))
23
#define WRITE_SECTOR(d, a) scache_writeSector((d)->cache, (a))
24
#define FLUSH_SECTORS(d) scache_flushSectors((d)->cache)
25
26
int
UsbMassReadSector(fat_driver *fatd,
void
**buffer, u32 sector)
27
{
28
return
READ_SECTOR(fatd->dev, sector, buffer);
29
}
30
31
int
UsbMassWriteSector(fat_driver *fatd, u32 sector)
32
{
33
return
WRITE_SECTOR(fatd->dev, sector);
34
}
35
36
void
UsbMassFlushCache(fat_driver *fatd)
37
{
38
FLUSH_SECTORS(fatd->dev);
39
}
cdvdman.h
mass_debug.h
mass_stor.h
scache.h
stdio.h
stdlib.h
string.h
sysclib.h
usbhd_common.h
usbhdfsd.h
core
usbhdfsd
src
api.c
Generated by
1.18.0