[kernel] Add channel objects

Add the channel object for sending messages between threads. Currently
no good of passing channels to other threads, but global variables in a
single process work. Currently channels are slow and do double copies,
need to refine more.

Tags: ipc
This commit is contained in:
2020-07-26 17:29:11 -07:00
parent ae3290c53d
commit d3e9d92466
10 changed files with 264 additions and 3 deletions

View File

@@ -12,3 +12,7 @@ SYSCALL(0x1a, thread_exit, int64_t)
SYSCALL(0x1b, thread_pause, void)
SYSCALL(0x1c, thread_sleep, uint64_t)
SYSCALL(0x20, channel_create, j6_handle_t *)
SYSCALL(0x21, channel_close, j6_handle_t)
SYSCALL(0x22, channel_send, j6_handle_t, size_t, void *)
SYSCALL(0x23, channel_receive, j6_handle_t, size_t *, void *)