| Age | Commit message (Collapse) | Author |
|
+ Processes won't be able to read previous stack frames etc
|
|
|
|
|
|
|
|
+ Skip unwinding stack and just jump directly to userspace
|
|
+ Remove sys_kill() as we should be using a two-stage process where a
thread is first orphaned by sys_detach(), and then the thread itself
calls sys_exit() after it has done all necessary cleanup in init.
|
|
+ A bit easier to implement just ignoring the ipc_resp() arguments than
try to enforce that a notification is exited from by ipc_ghost(),
especially in cases where the root process has been killed.
|
|
|
|
|
|
+ Seems to improve code quality a little bit
|
|
+ ipc_kick() does a forward and a tail at the same time
The idea with ipc_tail() is to allow 'trusted' calls, so for example a
process is not allowed to willy-nilly open a file, as it has to go via
init(), making the eid 1. This way the receiver can know that the
request has gone through init() and can open up a new connection
(file, whatever) after which requests from that pid/tid are allowed
without init() intervention
|
|
+ Anything extern is right out as LLVM doesn't produce correct code for
them. Maybe if I added some extra attributes but I'm skeptical.
Replaced with static variables and getters/setters.
+ Inline ASM is apparently a bit buggy, so use an assembly stub when jumping to init.
+ Minimize work done in main() to minimize chance of LLVM doing something silly.
Still not 100% certain that I shouldn't just write the main() as an assembly stub
in arch/riscv64 to be absolutely sure everything works as intended.
+ Make .kernel.start section SHF_ALLOC, otherwise lld complains about
pc-relative addressing
Probably some other stuff as well that I'm forgetting right now. But at least with
LLVM14 LTO seems to work, which is pretty cool?
|
|
+ Effectively means that all executables can be called into, but if an
exe doesn't want to deal with anyone else it should just set a flag
like `not_really_a_server` or whatever
|
|
+ Start out using big kernel lock, apparently seL4 thinks its good
enough. I might have a go at using a more fair lock, and possibly
moving to more fine-grained locks if I really feel the need to get
scalability up.
|
|
+ Compiling for size emits memcpy() calls after they've already been
removed by LTO, so add __used attribute to counteract this.
Newer versions of GCC seem to prefer `-flto=auto` to just `-flto`, so
use that.
printf format %d -> %ld
|
|
|
|
+ Allow threads to make themselves become orphants
|
|
+ Should write this down somewhere but the idea is that when a process
gets killed, it frees all the memory it can, making all threads within
that process orphans. Orphaned threads are assigned to the init
process, which will generally call exit() on each one. Zombie threads
are threads that own some bit of shared data, and whose reference
count is above zero. They may not be swapped to or called, even though
they take up space in thread map and reserve their thread ID.
|
|
|
|
+ Still largely untested, should really try to come up with a proper
testsuite, at the moment it's mostly me trying things out in the (as
of yet unreleased) kmx repo
|
|
+ Terminology is still a bit poor, and will still have to write
documentation + implement ipis properly
|
|
|
|
+ I keep starting to type src and wondering why autocomplete won't work,
I guess src is just uncounciously a better name
|