mirror of
https://github.com/RPCS3/rpcs3.git
synced 2025-01-30 21:32:50 +00:00
FS: add cellFsChmod & cellFsAioWrite
This commit is contained in:
parent
3d47c8ab9f
commit
ae96537b8d
@ -202,7 +202,11 @@ int cellFsAioRead(mem_ptr_t<CellFsAio> aio, mem32_t aio_id, mem_func_ptr_t<void
|
||||
|
||||
vfsFileBase* orig_file;
|
||||
u32 fd = aio->fd;
|
||||
if (!sys_fs->CheckId(fd, orig_file)) return CELL_EBADF;
|
||||
|
||||
if (!sys_fs->CheckId(fd, orig_file))
|
||||
{
|
||||
return CELL_EBADF;
|
||||
}
|
||||
|
||||
//get a unique id for the callback (may be used by cellFsAioCancel)
|
||||
const u32 xid = g_FsAioReadID++;
|
||||
@ -216,6 +220,15 @@ int cellFsAioRead(mem_ptr_t<CellFsAio> aio, mem32_t aio_id, mem_func_ptr_t<void
|
||||
return CELL_OK;
|
||||
}
|
||||
|
||||
int cellFsAioWrite(mem_ptr_t<CellFsAio> aio, mem32_t aio_id, mem_func_ptr_t<void(*)(mem_ptr_t<CellFsAio> xaio, int error, int xid, u64 size)> func)
|
||||
{
|
||||
sys_fs->Todo("cellFsAioWrite(aio_addr=0x%x, id_addr=0x%x, func_addr=0x%x)", aio.GetAddr(), aio_id.GetAddr(), func.GetAddr());
|
||||
|
||||
// TODO:
|
||||
|
||||
return CELL_OK;
|
||||
}
|
||||
|
||||
int cellFsAioInit(mem8_ptr_t mount_point)
|
||||
{
|
||||
std::string mp = Memory.ReadString(mount_point.GetAddr());
|
||||
@ -265,6 +278,7 @@ void sys_fs_init()
|
||||
sys_fs->AddFunc(0xef3efa34, cellFsFstat);
|
||||
sys_fs->AddFunc(0xba901fe6, cellFsMkdir);
|
||||
sys_fs->AddFunc(0xf12eecc8, cellFsRename);
|
||||
sys_fs->AddFunc(0x99406d0b, cellFsChmod);
|
||||
sys_fs->AddFunc(0x2796fdf3, cellFsRmdir);
|
||||
sys_fs->AddFunc(0x7f4677a8, cellFsUnlink);
|
||||
sys_fs->AddFunc(0xa397d042, cellFsLseek);
|
||||
@ -272,6 +286,7 @@ void sys_fs_init()
|
||||
sys_fs->AddFunc(0xc9dc3ac5, cellFsTruncate);
|
||||
sys_fs->AddFunc(0xcb588dba, cellFsFGetBlockSize);
|
||||
sys_fs->AddFunc(0xc1c507e7, cellFsAioRead);
|
||||
sys_fs->AddFunc(0x4cef342e, cellFsAioWrite);
|
||||
sys_fs->AddFunc(0xdb869f20, cellFsAioInit);
|
||||
sys_fs->AddFunc(0x9f951810, cellFsAioFinish);
|
||||
sys_fs->AddFunc(0x1a108ab7, cellFsGetBlockSize);
|
||||
|
@ -333,6 +333,15 @@ s32 cellFsRename(u32 from_addr, u32 to_addr)
|
||||
|
||||
return CELL_ENOENT;
|
||||
}
|
||||
s32 cellFsChmod(u32 path_addr, u32 mode)
|
||||
{
|
||||
const std::string& ps3_path = Memory.ReadString(path_addr);
|
||||
sys_fs->Todo("cellFsChmod(path=\"%s\", mode=0x%x)", ps3_path.c_str(), mode);
|
||||
|
||||
// TODO:
|
||||
|
||||
return CELL_OK;
|
||||
}
|
||||
|
||||
s32 cellFsRmdir(u32 path_addr)
|
||||
{
|
||||
|
@ -135,6 +135,7 @@ s32 cellFsStat(u32 path_addr, mem_ptr_t<CellFsStat> sb);
|
||||
s32 cellFsFstat(u32 fd, mem_ptr_t<CellFsStat> sb);
|
||||
s32 cellFsMkdir(u32 path_addr, u32 mode);
|
||||
s32 cellFsRename(u32 from_addr, u32 to_addr);
|
||||
s32 cellFsChmod(u32 path_addr, u32 mode);
|
||||
s32 cellFsRmdir(u32 path_addr);
|
||||
s32 cellFsUnlink(u32 path_addr);
|
||||
s32 cellFsLseek(u32 fd, s64 offset, u32 whence, mem64_t pos);
|
||||
|
Loading…
x
Reference in New Issue
Block a user