23#define IOS_MODE_READ 1
24#define IOS_MODE_WRITE 2
26#define IOS_MAX_PATH 64
57extern int ios_open(
const char* path,
int mode);
79extern int ios_read(
int file_handle,
void* buffer,
int size);
91extern int ios_write(
int file_handle,
void* buffer,
int size);
103extern int ios_seek(
int file_handle,
int where,
int whence);
117extern int ios_ioctl(
int file_handle,
int ioctl,
void* buffer_in,
int in_size,
void* buffer_io,
int io_size);
185extern int ios_read_async(
int file_handle,
void* buffer,
int size,
ipc_message* message, ipc_async_handler_t handler,
void* params);
202extern int ios_write_async(
int file_handle,
void* buffer,
int size,
ipc_message* message, ipc_async_handler_t handler,
void* params);
219extern int ios_seek_async(
int file_handle,
int where,
int whence,
ipc_message* message, ipc_async_handler_t handler,
void* params);
238extern int ios_ioctl_async(
int file_handle,
int ioctl,
void* buffer_in,
int in_size,
void* buffer_io,
int io_size,
ipc_message* message, ipc_async_handler_t handler,
void* params);
int ios_write(int file_handle, void *buffer, int size)
Write to a file.
Definition ios.c:95
int ios_read(int file_handle, void *buffer, int size)
Read from a file.
Definition ios.c:82
int ios_open(const char *path, int mode)
Opens a file on IOS.
Definition ios.c:56
int ios_seek(int file_handle, int where, int whence)
Seek to a position in a file.
Definition ios.c:108
int ios_ioctl_async(int file_handle, int ioctl, void *buffer_in, int in_size, void *buffer_io, int io_size, ipc_message *message, ipc_async_handler_t handler, void *params)
Send control commands to a device with async.
Definition ios.c:205
int ios_ioctlv(int file_handle, int ioctl, int in_size, int io_size, ios_ioctlv_t *argv)
Send multiple IO ctrl buffers.
Definition ios.c:134
int ios_open_async(const char *path, int mode, ipc_message *message, ipc_async_handler_t handler, void *params)
Opens a file on IOS with callback with async.
Definition ios.c:149
int ios_close_async(int file_handle, ipc_message *message, ipc_async_handler_t handler, void *params)
Closes a file on IOS with async.
Definition ios.c:164
int ios_ioctl(int file_handle, int ioctl, void *buffer_in, int in_size, void *buffer_io, int io_size)
Send control commands to a device.
Definition ios.c:121
int ios_close(int file_handle)
Closes a file on IOS.
Definition ios.c:69
int ios_write_async(int file_handle, void *buffer, int size, ipc_message *message, ipc_async_handler_t handler, void *params)
Write to a file with async.
Definition ios.c:184
void ios_initialize()
TODO: Explore and properly document what needs alignment and what does not.
Definition ios.c:51
int ios_read_async(int file_handle, void *buffer, int size, ipc_message *message, ipc_async_handler_t handler, void *params)
Read from a file with async.
Definition ios.c:171
int ios_ioctlv_async(int file_handle, int ioctl, int in_size, int io_size, ios_ioctlv_t *args, ipc_message *message, ios_ioctlv_t *args_buffer, ipc_async_handler_t handler, void *params)
Send multiple IO ctrl buffers with async.
Definition ios.c:221
int ios_seek_async(int file_handle, int where, int whence, ipc_message *message, ipc_async_handler_t handler, void *params)
Seek to a position in a file with async.
Definition ios.c:196
Inter Processor Communications.
Used with ios_ioctlv for sending multiple IO ctrl structures.
Definition ios.h:34