summaryrefslogtreecommitdiff
path: root/Kernel/Syscall.h
diff options
context:
space:
mode:
authorAndreas Kling <awesomekling@gmail.com>2019-01-15 23:12:20 +0100
committerAndreas Kling <awesomekling@gmail.com>2019-01-16 00:09:58 +0100
commit10387beda760c11b99dbd8d10ffc3a35b597d137 (patch)
tree1f6b5f0c36172b710f9f5365b68ea8dc12dbe73e /Kernel/Syscall.h
parent46181cf023045ad346aabc760dafaecc93965d33 (diff)
downloadserenity-10387beda760c11b99dbd8d10ffc3a35b597d137.zip
Implement basic support for POSIX-style select().
Now we can block on both the PTY *and* the GUI event stream in Terminal.
Diffstat (limited to 'Kernel/Syscall.h')
-rw-r--r--Kernel/Syscall.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/Kernel/Syscall.h b/Kernel/Syscall.h
index f0e315ec47..2159d491f2 100644
--- a/Kernel/Syscall.h
+++ b/Kernel/Syscall.h
@@ -71,8 +71,11 @@
__ENUMERATE_SYSCALL(gui_destroy_window) \
__ENUMERATE_SYSCALL(gui_get_window_backing_store) \
__ENUMERATE_SYSCALL(gui_invalidate_window) \
+ __ENUMERATE_SYSCALL(select) \
+struct fd_set;
+
namespace Syscall {
enum Function {
@@ -102,6 +105,14 @@ struct SC_mmap_params {
int32_t offset; // FIXME: 64-bit off_t?
};
+struct SC_select_params {
+ int nfds;
+ fd_set* readfds;
+ fd_set* writefds;
+ fd_set* exceptfds;
+ struct timeval* timeout;
+};
+
void initialize();
int sync();