summaryrefslogtreecommitdiff
path: root/src/shared/syscalls.h
diff options
context:
space:
mode:
authordzwdz2021-09-20 19:30:37 +0200
committerdzwdz2021-09-20 19:30:37 +0200
commit6371724809b057b25a4efd6c022e7d95068c42f1 (patch)
tree5cc6484ae767cd27f2ae4ccd24c0fb01e9beb163 /src/shared/syscalls.h
parent9a08099fb7148a69b0655f0e559661b1021b17b5 (diff)
add an offset parameter to read() and write()
Diffstat (limited to 'src/shared/syscalls.h')
-rw-r--r--src/shared/syscalls.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/shared/syscalls.h b/src/shared/syscalls.h
index f6ee44f..44a2f5d 100644
--- a/src/shared/syscalls.h
+++ b/src/shared/syscalls.h
@@ -43,8 +43,8 @@ int _syscall_fork(void);
handle_t _syscall_open(const char __user *path, int len);
int _syscall_mount(handle_t, const char __user *path, int len);
-int _syscall_read(handle_t, char __user *buf, int len);
-int _syscall_write(handle_t, const char __user *buf, int len);
+int _syscall_read(handle_t, char __user *buf, int len, int offset);
+int _syscall_write(handle_t, const char __user *buf, int len, int offset);
int _syscall_close(handle_t);
/** Creates a pair of front/back filesystem handles.
@@ -54,6 +54,7 @@ handle_t _syscall_fs_create(handle_t __user *back);
struct fs_wait_response {
int len; // how much was put in *buf
int id; // file id (returned by the open handler, passed to other calls)
+ int offset;
};
int _syscall_fs_wait(handle_t back, char __user *buf, int max_len,
struct fs_wait_response __user *res);