- DEBUG("open(\"%s\", 0x%x)", Path, Flags);
+ SYSTRACE("open(\"%s\", 0x%x)", Path, Flags);
return _Syscall(SYS_OPEN, ">s >i", Path, Flags);
}
return _Syscall(SYS_OPEN, ">s >i", Path, Flags);
}
_Syscall(SYS_CLOSE, ">i", FD);
}
int acess__SysReopen(int FD, const char *Path, int Flags) {
_Syscall(SYS_CLOSE, ">i", FD);
}
int acess__SysReopen(int FD, const char *Path, int Flags) {
- DEBUG("reopen(0x%x, \"%s\", 0x%x)", FD, Path, Flags);
+ SYSTRACE("reopen(0x%x, \"%s\", 0x%x)", FD, Path, Flags);
return _Syscall(SYS_REOPEN, ">i >s >i", FD, Path, Flags);
}
int acess__SysCopyFD(int srcfd, int dstfd) {
return _Syscall(SYS_REOPEN, ">i >s >i", FD, Path, Flags);
}
int acess__SysCopyFD(int srcfd, int dstfd) {
return _Syscall(SYS_COPYFD, ">i >i", srcfd, dstfd);
}
return _Syscall(SYS_COPYFD, ">i >i", srcfd, dstfd);
}
size_t acess__SysRead(int FD, void *Dest, size_t Bytes) {
if(FD & NATIVE_FILE_MASK)
return native_read(FD & (NATIVE_FILE_MASK-1), Dest, Bytes);
size_t acess__SysRead(int FD, void *Dest, size_t Bytes) {
if(FD & NATIVE_FILE_MASK)
return native_read(FD & (NATIVE_FILE_MASK-1), Dest, Bytes);
-// if( FD > 2 )
- DEBUG("read(0x%x, 0x%x, *%p)", FD, Bytes, Dest);
+ SYSTRACE("_SysRead(0x%x, 0x%x, *%p)", FD, Bytes, Dest);
return _Syscall(SYS_READ, ">i >i <d", FD, Bytes, Bytes, Dest);
}
size_t acess__SysWrite(int FD, const void *Src, size_t Bytes) {
if(FD & NATIVE_FILE_MASK)
return native_write(FD & (NATIVE_FILE_MASK-1), Src, Bytes);
return _Syscall(SYS_READ, ">i >i <d", FD, Bytes, Bytes, Dest);
}
size_t acess__SysWrite(int FD, const void *Src, size_t Bytes) {
if(FD & NATIVE_FILE_MASK)
return native_write(FD & (NATIVE_FILE_MASK-1), Src, Bytes);
-// if( FD > 2 )
- DEBUG("write(0x%x, 0x%x, %p\"%.*s\")", FD, Bytes, Src, Bytes, (char*)Src);
+ SYSTRACE("_SysWrite(0x%x, 0x%x, %p\"%.*s\")", FD, Bytes, Src, Bytes, (char*)Src);
return _Syscall(SYS_WRITE, ">i >i >d", FD, Bytes, Bytes, Src);
}
return _Syscall(SYS_WRITE, ">i >i >d", FD, Bytes, Bytes, Src);
}
if(FD & NATIVE_FILE_MASK) {
return native_seek(FD & (NATIVE_FILE_MASK-1), Ofs, Dir);
}
if(FD & NATIVE_FILE_MASK) {
return native_seek(FD & (NATIVE_FILE_MASK-1), Ofs, Dir);
}
- DEBUG("seek(0x%x, 0x%llx, %i)", FD, Ofs, Dir);
+ SYSTRACE("_SysSeek(0x%x, 0x%llx, %i)", FD, Ofs, Dir);
return _Syscall(SYS_SEEK, ">i >I >i", FD, Ofs, Dir);
}
return _Syscall(SYS_SEEK, ">i >I >i", FD, Ofs, Dir);
}
return _Syscall(SYS_TELL, ">i", FD);
}
int acess__SysIOCtl(int fd, int id, void *data) {
int len;
return _Syscall(SYS_TELL, ">i", FD);
}
int acess__SysIOCtl(int fd, int id, void *data) {
int len;
- DEBUG("ioctl(%i, %i, %p)", fd, id, data);
+ SYSTRACE("_SysIOCtl(%i, %i, %p)", fd, id, data);
return _Syscall(SYS_IOCTL, ">i >i ?d", fd, id, len, data);
}
int acess__SysFInfo(int fd, t_sysFInfo *info, int maxacls) {
// DEBUG("offsetof(size, t_sysFInfo) = %i", offsetof(t_sysFInfo, size));
return _Syscall(SYS_IOCTL, ">i >i ?d", fd, id, len, data);
}
int acess__SysFInfo(int fd, t_sysFInfo *info, int maxacls) {
// DEBUG("offsetof(size, t_sysFInfo) = %i", offsetof(t_sysFInfo, size));
- DEBUG("finfo(%i, %p, %i)", fd, info, maxacls);
+ SYSTRACE("_SysFInfo(%i, %p, %i)", fd, info, maxacls);
return _Syscall(SYS_FINFO, ">i <d >i",
fd,
sizeof(t_sysFInfo)+maxacls*sizeof(t_sysACL), info,
return _Syscall(SYS_FINFO, ">i <d >i",
fd,
sizeof(t_sysFInfo)+maxacls*sizeof(t_sysACL), info,
- DEBUG("SysReadDir(%i, %p)", fd, dest);
+ SYSTRACE("_SysReadDir(%i, %p)", fd, dest);
return _Syscall(SYS_READDIR, ">i <d", fd, 256, dest);
}
int acess__SysSelect(int nfds, fd_set *read, fd_set *write, fd_set *error, int64_t *timeout, uint32_t events)
{
return _Syscall(SYS_READDIR, ">i <d", fd, 256, dest);
}
int acess__SysSelect(int nfds, fd_set *read, fd_set *write, fd_set *error, int64_t *timeout, uint32_t events)
{
- DEBUG("_SysSelect(%i, %p, %p, %p, %p, 0x%x)", nfds, read, write, error, timeout, events);
+ SYSTRACE("_SysSelect(%i, %p, %p, %p, %p, 0x%x)", nfds, read, write, error, timeout, events);
return _Syscall(SYS_SELECT, ">i ?d ?d ?d >d >i", nfds,
read ? (nfds+7)/8 : 0, read,
write ? (nfds+7)/8 : 0, write,
return _Syscall(SYS_SELECT, ">i ?d ?d ?d >d >i", nfds,
read ? (nfds+7)/8 : 0, read,
write ? (nfds+7)/8 : 0, write,
- DEBUG("_SysOpenChild(0x%x, '%s', 0x%x)", fd, name, flags);
+ SYSTRACE("_SysOpenChild(0x%x, '%s', 0x%x)", fd, name, flags);
return _Syscall(SYS_OPENCHILD, ">i >s >i", fd, name, flags);
}
int acess__SysGetACL(int fd, t_sysACL *dest) {
return _Syscall(SYS_OPENCHILD, ">i >s >i", fd, name, flags);
}
int acess__SysGetACL(int fd, t_sysACL *dest) {
- DEBUG("%s(0x%x, %p)", __func__, fd, dest);
+ SYSTRACE("%s(0x%x, %p)", __func__, fd, dest);
return _Syscall(SYS_GETACL, ">i <d", fd, sizeof(t_sysACL), dest);
}
int acess__SysMount(const char *Device, const char *Directory, const char *Type, const char *Options) {
return _Syscall(SYS_GETACL, ">i <d", fd, sizeof(t_sysACL), dest);
}
int acess__SysMount(const char *Device, const char *Directory, const char *Type, const char *Options) {
- DEBUG("%s('%s', '%s', '%s', '%s')", __func__, Device, Directory, Type, Options);
+ SYSTRACE("_SysMount('%s', '%s', '%s', '%s')", Device, Directory, Type, Options);
return _Syscall(SYS_MOUNT, ">s >s >s >s", Device, Directory, Type, Options);
}
return _Syscall(SYS_MOUNT, ">s >s >s >s", Device, Directory, Type, Options);
}