summaryrefslogtreecommitdiff
path: root/src/shared
diff options
context:
space:
mode:
authordzwdz2022-07-08 14:40:44 +0200
committerdzwdz2022-07-08 14:40:44 +0200
commit1f7e7501660123ff8f26e8c65e75c2b282b933ef (patch)
tree5ba6cee10ac656b20dcabc9c9f7b079dcd952a45 /src/shared
parente567ebeee5ea196128f15adcf30cec5dd1137f90 (diff)
syscall/fs_respond: get the file id from the buf argument
Previously, file ids could only be positive integers, so their range was 31 bits - not enough to represent the entire memory. Now, pointers can be safely used as file ids.
Diffstat (limited to 'src/shared')
-rw-r--r--src/shared/syscalls.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/shared/syscalls.h b/src/shared/syscalls.h
index b9be23d..c6d3c33 100644
--- a/src/shared/syscalls.h
+++ b/src/shared/syscalls.h
@@ -63,14 +63,14 @@ struct fs_wait_response {
enum vfs_operation op;
size_t len; // how much was put in *buf
size_t capacity; // how much output can be accepted by the caller
- int id; // file id (returned by the open handler, passed to other calls)
+ void __user *id; // file id (returned by the open handler, passed to other calls)
int offset;
int flags;
};
/** Blocks until an fs request is made.
* @return 0 if everything was successful */
int _syscall_fs_wait(char __user *buf, int max_len, struct fs_wait_response __user *res);
-int _syscall_fs_respond(char __user *buf, int ret, int flags);
+int _syscall_fs_respond(void __user *buf, int ret, int flags);
/** Modifies the virtual address space.
*