sdcardfs #109
sdcardfs #109
Changes from 47 commits
e3b04bb
2fd53f1
bf93e61
7441be5
00bf559
d910fd1
127e1f9
fd569cc
1d4dc46
8e04cc9
a53b339
24c26d0
b13df47
423334d
9098b2e
eae55f9
d6faf31
28ac600
05c62ab
d81b6a0
bb7970d
cc49ac8
b794010
e404638
7e00acb
8d5ef5e
9c35ae9
861deea
26a3d99
00d5801
2a92fca
e99fc65
e162ad5
355654b
1aa72f6
0dfce7e
e652a67
5534a96
00cec3d
4c9e9ce
15bce5a
8683b01
b46797b
473fbc9
48510e0
d24ac8a
002bae6
78b4542
f2c40ff
ce15f29
ed1e171
9bb4756
f9105c6
883a46d
23bf037
78a9072
f4eb772
e8abe9e
7b833d4
72d5c22
e0eacee
9a2001d
f72ac25
4df7ab7
b1cff89
0fb9b11
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,7 +6,70 @@ | |
#pragma once | ||
|
||
#define MAKE_RESULT(module, code) (((code) << 9) | (module)) | ||
#define LIBTRANSISTOR_RESULT(code) MAKE_RESULT(0xDD, code) | ||
|
||
enum modules { | ||
MODULE_KERNEL = 1, | ||
MODULE_FS = 2, | ||
MODULE_NVIDIA = 3, | ||
MODULE_NCM = 5, | ||
MODULE_DD = 6, | ||
MODULE_LR = 8, | ||
MODULE_LOADER = 9, | ||
MODULE_CMIF = 10, | ||
MODULE_HIPC = 11, | ||
MODULE_PM = 15, | ||
MODULE_NS = 16, | ||
MODULE_HTC = 18, | ||
MODULE_SM = 21, | ||
MODULE_RO = 22, | ||
MODULE_SDMMC = 24, | ||
MODULE_SPL = 26, | ||
MODULE_ETHC = 100, | ||
MODULE_I2C = 101, | ||
MODULE_SETTINGS = 105, | ||
MODULE_NIFM = 110, | ||
MODULE_HWOPUS = 111, | ||
MODULE_DISPLAY = 114, | ||
MODULE_NTC = 116, | ||
MODULE_FGM = 117, | ||
MODULE_PCIE = 120, | ||
MODULE_FRIENDS = 121, | ||
MODULE_SSL = 123, | ||
MODULE_ACCOUNT = 124, | ||
MODULE_MII = 126, | ||
MODULE_AM = 128, | ||
MODULE_PLAYREPORT = 129, | ||
MODULE_PCV = 133, | ||
MODULE_OMM = 134, | ||
MODULE_NIM = 137, | ||
MODULE_PSC = 138, | ||
MODULE_USB = 140, | ||
MODULE_NSD = 141, | ||
MODULE_BTM = 143, | ||
MODULE_ERPT = 147, | ||
MODULE_APM = 148, | ||
MODULE_AUDIO = 153, | ||
MODULE_NPNS = 154, | ||
MODULE_ARP = 157, | ||
MODULE_BOOT = 158, | ||
MODULE_NFC = 161, | ||
MODULE_USERLAND_ASSERT = 162, | ||
MODULE_USERLAND_CRASH = 168, | ||
MODULE_HID = 203, | ||
MODULE_CAPTURE = 206, | ||
MODULE_LIBTRANSISTOR = 221, | ||
MODULE_LIBNX = 345, | ||
MODULE_HOMEBREW_ABI = 346, | ||
MODULE_HOMEBREW_LOADER = 347, | ||
MODULE_LIBNX_NVIDIA = 348, | ||
MODULE_TC = 651, | ||
MODULE_WEBAPPLET = 800, | ||
MODULE_WEBAPPLET_WIFIAUTH = 809, | ||
MODULE_APPLET_WHITELISTED = 810, | ||
MODULE_SHOPN = 811, | ||
}; | ||
|
||
#define LIBTRANSISTOR_RESULT(code) MAKE_RESULT(MODULE_LIBTRANSISTOR, code) | ||
|
||
// Misc | ||
#define LIBTRANSISTOR_ERR_UNSPECIFIED LIBTRANSISTOR_RESULT(1) | ||
|
@@ -84,6 +147,7 @@ | |
#define LIBTRANSISTOR_ERR_FS_NOT_FOUND LIBTRANSISTOR_RESULT(8006) | ||
#define LIBTRANSISTOR_ERR_FS_INVALID_PATH LIBTRANSISTOR_RESULT(8007) | ||
#define LIBTRANSISTOR_ERR_FS_PATH_TOO_DEEP LIBTRANSISTOR_RESULT(8008) | ||
#define LIBTRANSISTOR_ERR_FS_PATH_EXISTS LIBTRANSISTOR_RESULT(8009) | ||
|
||
// AM | ||
#define LIBTRANSISTOR_ERR_AM_WORKAROUND_ACTIVE LIBTRANSISTOR_RESULT(9001) | ||
|
@@ -98,7 +162,13 @@ | |
#define LIBTRANSISTOR_ERR_IPCSERVER_NO_SUCH_COMMAND LIBTRANSISTOR_RESULT(10007) | ||
|
||
// Homebrew ABI | ||
#define HOMEBREW_ABI_RESULT(code) MAKE_RESULT(346, code) | ||
#define HOMEBREW_ABI_RESULT(code) MAKE_RESULT(MODULE_HOMEBREW_ABI, code) | ||
#define HOMEBREW_ABI_UNRECOGNIZED_KEY(key) HOMEBREW_ABI_RESULT(100 + key) | ||
#define HOMEBREW_ABI_KEY_NOT_PRESENT(key) HOMEBREW_ABI_RESULT(200 + key) | ||
#define HOMEBREW_ABI_KEY_INVALID(key) HOMEBREW_ABI_RESULT(300 + key) | ||
|
||
// FSP-SRV | ||
#define FSPSRV_RESULT(code) MAKE_RESULT(MODULE_FS, code) | ||
#define FSPSRV_ERR_NOT_FOUND FSPSRV_RESULT(1) | ||
#define FSPSRV_ERR_EXISTS FSPSRV_RESULT(2) | ||
#define FSPSRV_ERR_DIRECTORY_NOT_EMPTY FSPSRV_RESULT(8) | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. probably move to fs/err.h or ipc/fs/err.h or something |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,91 @@ | ||
/** | ||
* @file libtransistor/fs/fs.h | ||
* @brief Functions to setup filesystem | ||
* | ||
* Libtransistor sports a virtual filesystem allowing to mount multiple kinds of | ||
* filesystem (such as a squashfs, a networked filesystem, or an fsp-srv | ||
* filesystem). | ||
* | ||
* The filesystem root is purely virtual: you may not create | ||
* files or directories directly under `/`. Instead, filesystems are mounted as | ||
* direct descendants to it (through the `trn_fs_mount_fs` function). For | ||
* instance, the canonical place to mount the SD card is `/sd`, which is done | ||
* by calling `trn_fs_mount_fs("/sd", sdcardfs)`. | ||
* | ||
* Anyone can create his own filesystem: they simply needs to create a struct of | ||
* type `trn_inode_t`. Libtransistor sports various filesystem implementations, | ||
* mainly one backed by the FSP-SRV server of the switch, allowing mounting the | ||
* sdcard, among other things. | ||
* | ||
* Note that while functions like `trn_fs_open` are defined, those should | ||
* probably *not* be used. Users should prefer instead to use the POSIX | ||
* functions of the same name. This is because the error values, result_t, | ||
* are not guaranteed to stay the same across filesystems. | ||
*/ | ||
|
||
#pragma once | ||
|
||
#include<libtransistor/types.h> | ||
#include<libtransistor/fs/inode.h> | ||
|
||
#include<sys/stat.h> | ||
|
||
result_t trn_fs_set_root(trn_inode_t *root); | ||
/** | ||
* @brief Change filesystem root. | ||
* | ||
* In libtransistor, the default root filesystem is rootfs. That filesystem is | ||
* not very special: it's a filesystem containing only directories, each being | ||
* a mountpoint. However, this behavior might not fit what all application's | ||
* needs. For instance, when porting software, you might need to place some | ||
* files in certain locations, or just need more leeway in how the root fs | ||
* works. In these cases, you can use `trn_fs_set_root` to change what the root | ||
* filesystem implementation is. | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I think it's a little confusing that the concept of a "root filesystem" is not necessarily the same thing as "rootfs". I'd suggest either making that very clear in the documentation or renaming rootfs. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Yeah, I want to rename rootfs to mountfs. Will do. |
||
* | ||
* For instance, the following code will mount the sdcard at the root: | ||
* | ||
* @code{.c} | ||
* ifilesystem_t sdcard_ifs; | ||
* trn_inode_t sdcard_inode; | ||
* | ||
* fsp_srv_mount_sd_card(&sdcard_ifs); | ||
* trn_fspfs_create(&sdcard_inode, sdcard_ifs); | ||
* trn_fs_set_root(&sdcard_inode); | ||
* @endcode | ||
*/ | ||
result_t trn_fs_set_root(trn_inode_t *new_root); | ||
|
||
/** | ||
* @brief Mount a filesystem. | ||
* | ||
* Allows a user to mount a filesystem to the specified location. The location | ||
* should be a full path. | ||
* | ||
* Note that the current implementation is relatively simple: it forwards the | ||
* call to mount to the root filesystem - if it is a rootfs. If you have swapped | ||
* out the root filesystem with `trn_fs_set_root`, this will not work. | ||
* | ||
* You could mount the game card partition (assuming correct privilege) like so: | ||
* | ||
* @code{.c} | ||
* ifilesystem_t gamecard_ifs; | ||
* trn_inode_t gamecard_inode; | ||
* | ||
* fsp_srv_mount_game_card_partition(&gamecard_inode, 0, 0); | ||
* trn_fspfs_create(&gamecard_inode, gamecard_ifs); | ||
* trn_fs_mount("/gamecard", &gamecard_inode); | ||
* @endcode | ||
*/ | ||
result_t trn_fs_mount(const char *name, trn_inode_t *root); | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Since this will break if you There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The idea was that if we end up changing how mounts work (say, we end up wanting to do mounting in arbitrary location and getting rid of rootfs), we can do that without breaking userspace applications. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Ah, alright. |
||
|
||
// The rest of those functions should probably not be directly used. Instead, | ||
// use the standard posix calls of the same name... | ||
// Maybe we should still men | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Wow. That said |
||
result_t trn_fs_realpath(const char *path, char **resolved_path); | ||
result_t trn_fs_open(int *fd, const char *path, int flags); | ||
result_t trn_fs_opendir(trn_dir_t *dir, const char *path); | ||
result_t trn_fs_mkdir(const char *path); | ||
result_t trn_fs_rename(const char *oldpath, const char *newpath); | ||
result_t trn_fs_unlink(const char *path); | ||
result_t trn_fs_rmdir(const char *path); | ||
result_t trn_fs_chdir(const char *path); | ||
result_t trn_fs_stat(const char *path, struct stat *st); |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
/** | ||
* @file libtransistor/fs/fspfs.h | ||
* @brief FSP-SRV based filesystem | ||
* | ||
* The Nintendo Switch has a service called `fsp-srv` which is in charge of | ||
* providing apps with whatever filesystem they might need. For instance, you | ||
* might ask fsp-srv to give you a filesystem for the SD Card, or for the Game | ||
* Cartridge, etc... | ||
* | ||
* All those filesystem implement the same IPC interface: IFilesystem. FSPFS is | ||
* then responsible for wrapping this IPC Interface and providing a | ||
* libtransistor mountpoint to access it. This is the mechanism used by | ||
* libtransistor to mount the SDCard filesystem in /sd by default. | ||
*/ | ||
|
||
#pragma once | ||
|
||
#include<libtransistor/types.h> | ||
#include<libtransistor/fs/inode.h> | ||
#include<libtransistor/ipc/fs/ifilesystem.h> | ||
|
||
/** | ||
* @brief Create an FSPFS filesystem | ||
* | ||
* This takes an `ifilesystem_t` (that you'll need to have initialized | ||
* beforehand), and wraps it in a libtransistor filesystem. | ||
* | ||
* Note that the ownership of the ifilesystem_t is transfered to the fspfs! | ||
* When the filesystem is released, it will automatically close the | ||
* ifilesystem_t handle. | ||
*/ | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. add @param tags, make it clear that this initializes |
||
result_t trn_fspfs_create(trn_inode_t *out, ifilesystem_t fs); |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
/** | ||
* @file libtransistor/fs/rootfs.h | ||
* @brief Root Filesystem | ||
* | ||
* A RootFS is a pseudo-filesystem capable of mounting other filesystems in it. | ||
* In libtransistor, this is the default filesystem for the root directory. The | ||
* RootFS is organized as a single folder containing one subfolder for each | ||
* mounted filesystem. | ||
*/ | ||
#pragma once | ||
|
||
#include<libtransistor/fs/inode.h> | ||
|
||
// TODO: Rename mountfs I guess. | ||
|
||
/** | ||
* @brief Create a rootfs filesystem | ||
*/ | ||
result_t trn_rootfs_create(trn_inode_t *out); | ||
|
||
|
||
/** | ||
* @brief Mount a filesystem in the RootFS | ||
* | ||
* The given filesystem will then be made available in a folder of the given | ||
* name. Note that it is *not* possible to have hierarchies in the rootfs: all | ||
* filesystems have to be mounted directly at the root of the RootFS. | ||
* | ||
* This takes ownership of the passed trn_inode_t: it will call the close | ||
* release method automatically when the rootfs itself is released. | ||
*/ | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. What does the lifetime on |
||
result_t trn_rootfs_mount_fs(trn_inode_t *fs, const char *name, trn_inode_t *mountpoint); |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,76 @@ | ||
/** | ||
* @file libtransistor/ipc/fs.h | ||
* @brief File System | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. change this to "Auto-generated |
||
*/ | ||
|
||
#pragma once | ||
|
||
#include <libtransistor/types.h> | ||
#include <libtransistor/ipc/fs/ifilesystem.h> | ||
#include <libtransistor/ipc/fs/ifile.h> | ||
#include <libtransistor/ipc/fs/idirectory.h> | ||
|
||
// TODO: Codegen structs | ||
|
||
|
||
result_t fsp_srv_init(uint64_t in_unk0); | ||
void fsp_srv_finalize(); | ||
// result_t fsp_srv_mount_content(ifilesystem_t *out_contentFs, applicationid in_tid, uint32_t in_flag, const int8_t * in_path); | ||
result_t fsp_srv_open_data_file_system_by_current_process(ifilesystem_t *out_unk0); | ||
// result_t fsp_srv_mount_content7(ifilesystem_t *out_unk2, applicationid in_tid, uint32_t in_ncaType); | ||
// result_t fsp_srv_mount_content(ifilesystem_t *out_contentFs, applicationid in_tid, uint32_t in_flag, const uint8_t in_path[0x301]); | ||
// result_t fsp_srv_open_data_file_system_by_application_id(ifilesystem_t *out_dataFiles, applicationid in_tid); | ||
// result_t fsp_srv_mount_bis(ifilesystem_t *out_Bis, partition in_partitionID, const uint8_t in_path[0x301]); | ||
// result_t fsp_srv_open_bis_partition(ipc_object_t *out_BisPartition, partition in_partitionID); | ||
result_t fsp_srv_invalidate_bis_cache(); | ||
result_t fsp_srv_open_host_file_system_impl(ifilesystem_t *out_unk1, const uint8_t in_path[0x301]); | ||
result_t fsp_srv_mount_sd_card(ifilesystem_t *out_sdCard); | ||
result_t fsp_srv_format_sd_card(); | ||
// result_t fsp_srv_delete_save_data(applicationid in_tid); | ||
// result_t fsp_srv_create_save_data(savestruct in_saveStruct, savecreatestruct in_saveCreate, u128 in_input); | ||
// result_t fsp_srv_create_system_save_data(savestruct in_saveStruct, savecreatestruct in_saveCreate); | ||
// result_t fsp_srv_register_save_data_atomic_deletion(unknown in_unk0); | ||
result_t fsp_srv_delete_save_data_with_space_id(uint8_t in_unk0, uint64_t in_unk1); | ||
result_t fsp_srv_format_sd_card_dry_run(); | ||
result_t fsp_srv_is_ex_fat_supported(uint8_t *out_isSupported); | ||
// result_t fsp_srv_open_game_card_partition(ipc_object_t *out_gameCardFs, partition in_partitionID, uint32_t in_unk1); | ||
result_t fsp_srv_mount_game_card_partition(ifilesystem_t *out_gameCardPartitionFs, uint32_t in_unk0, uint32_t in_unk1); | ||
result_t fsp_srv_extend_save_data(uint8_t in_unk0, uint64_t in_unk1, uint64_t in_unk2, uint64_t in_unk3); | ||
// result_t fsp_srv_mount_save_data(ifilesystem_t *out_saveDataFs, uint8_t in_input, savestruct in_saveStruct); | ||
// result_t fsp_srv_mount_system_save_data(ifilesystem_t *out_systemSaveDataFs, uint8_t in_input, savestruct in_saveStruct); | ||
// result_t fsp_srv_mount_save_data_read_only(ifilesystem_t *out_saveDataFs, uint8_t in_input, savestruct in_saveStruct); | ||
// result_t fsp_srv_read_save_data_file_system_extra_data_with_space_id(unknown *out_unk2, uint8_t in_unk0, uint64_t in_unk1); | ||
// result_t fsp_srv_read_save_data_file_system_extra_data(unknown *out_unk1, uint64_t in_unk0); | ||
// result_t fsp_srv_write_save_data_file_system_extra_data(uint64_t in_unk0, uint8_t in_unk1, unknown in_unk2); | ||
// result_t fsp_srv_open_save_data_info_reader(ipc_object_t *out_unk0); | ||
// result_t fsp_srv_open_save_data_iterator(ipc_object_t *out_unk1, uint8_t in_unk0); | ||
result_t fsp_srv_open_save_data_thumbnail_file(ifile_t *out_thumbnail, uint8_t in_unk0, const uint8_t in_unk1[0x40], uint32_t in_unk2); | ||
result_t fsp_srv_mount_image_directory(ifilesystem_t *out_imageFs, uint32_t in_unk0); | ||
result_t fsp_srv_mount_content_storage(ifilesystem_t *out_contentFs, uint32_t in_contentStorageID); | ||
// result_t fsp_srv_open_data_storage_by_current_process(ipc_object_t *out_dataStorage); | ||
// result_t fsp_srv_open_data_storage_by_application_id(ipc_object_t *out_dataStorage, applicationid in_tid); | ||
// result_t fsp_srv_open_data_storage_by_data_id(ipc_object_t *out_dataStorage, applicationid in_tid, uint8_t in_storageId); | ||
// result_t fsp_srv_open_rom_storage(ipc_object_t *out_unk0); | ||
// result_t fsp_srv_open_device_operator(ipc_object_t *out_unk0); | ||
// result_t fsp_srv_open_sd_card_detection_event_notifier(ipc_object_t *out_SdEventNotify); | ||
// result_t fsp_srv_open_game_card_detection_event_notifier(ipc_object_t *out_GameCardEventNotify); | ||
result_t fsp_srv_set_current_posix_time(uint64_t in_time); | ||
result_t fsp_srv_query_save_data_total_size(uint64_t *out_saveDataSize, uint64_t in_unk0, uint64_t in_unk1); | ||
// result_t fsp_srv_verify_save_data(unknown *out_unk1, applicationid in_tid); | ||
// result_t fsp_srv_corrupt_save_data_for_debug(applicationid in_tid); | ||
result_t fsp_srv_create_padding_file(uint64_t in_size); | ||
result_t fsp_srv_delete_all_padding_files(); | ||
// result_t fsp_srv_get_rights_id(u128 *out_rights, uint64_t in_unk0, uint8_t in_unk1); | ||
// result_t fsp_srv_register_external_key(u128 in_unk0, u128 in_unk1); | ||
result_t fsp_srv_unregister_external_key(); | ||
// result_t fsp_srv_get_rights_id_by_path(u128 *out_rights, const uint8_t in_path[0x301]); | ||
// result_t fsp_srv_get_rights_id_by_path2(u128 *out_rights, uint8_t *out_unk2, const uint8_t in_path[0x301]); | ||
// result_t fsp_srv_set_sd_card_encryption_seed(u128 in_seedmaybe); | ||
result_t fsp_srv_get_and_clear_file_system_proxy_error_info(uint8_t out_errorInfo[0x80]); | ||
result_t fsp_srv_set_bis_root_for_host(uint32_t in_unk0, const uint8_t in_path[0x301]); | ||
result_t fsp_srv_set_save_data_size(uint64_t in_unk0, uint64_t in_unk1); | ||
result_t fsp_srv_set_save_data_root_path(const uint8_t in_path[0x301]); | ||
result_t fsp_srv_disable_auto_save_data_creation(); | ||
result_t fsp_srv_set_global_access_log_mode(uint32_t in_mode); | ||
result_t fsp_srv_get_global_access_log_mode(uint32_t *out_logMode); | ||
// result_t fsp_srv_output_access_log_to_sd_card(unknown in_logText); |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
/** | ||
* @file libtransistor/ipc/fs/idirectory.h | ||
* @brief Directory | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. "Auto-generated |
||
*/ | ||
|
||
#pragma once | ||
|
||
#include <libtransistor/types.h> | ||
#include <assert.h> | ||
|
||
typedef ipc_object_t idirectory_t; | ||
|
||
typedef struct idirectoryentry { | ||
char path[0x300]; | ||
uint32_t unk1; | ||
uint8_t entry_type; | ||
// TODO: Padding | ||
uint64_t size; | ||
} idirectoryentry_t; | ||
static_assert(sizeof(idirectoryentry_t) == 0x310, "Wrong idirectoryentry_t size"); | ||
|
||
result_t idirectory_read(idirectory_t obj, uint64_t *out_unk0, idirectoryentry_t * out_unk1, size_t out_unk1_size); | ||
result_t idirectory_get_entry_count(idirectory_t obj, uint64_t *out_unk0); | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. can these arguments have better names? |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
/** | ||
* @file libtransistor/ipc/fs/ifile.h | ||
* @brief File | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. "Auto-generated |
||
*/ | ||
|
||
#pragma once | ||
|
||
#include <libtransistor/types.h> | ||
#include <libtransistor/ipc.h> | ||
|
||
typedef ipc_object_t ifile_t; | ||
|
||
// TODO: Codegen structs | ||
|
||
result_t ifile_read(ifile_t obj, uint64_t *out_out_size, int8_t * out_out_buf, size_t out_out_buf_size, uint64_t in_unk0, uint64_t in_offset, uint64_t in_size); | ||
result_t ifile_write(ifile_t obj, uint32_t in_unk0, uint64_t in_offset, uint64_t in_size, const int8_t * in_buf, size_t in_buf_size); | ||
result_t ifile_flush(ifile_t obj); | ||
result_t ifile_set_size(ifile_t obj, uint64_t in_size); | ||
result_t ifile_get_size(ifile_t obj, uint64_t *out_fileSize); | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. argument names |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
takes up a lot of space,
err_modules.h
maybe?