Commit graph vbos/mem/reg.S
Author SHA1 Message Date
Michael Shaw
b753afd4fb sched: properly implement blocking for read
This is a milestone update, as userspace applications are now able to
properly read from TTY devices, be blocked while waiting, and write the
output back. Userspace development will move much faster now that these
kinks have been worked out.

This version will be tagged as vbos v0.01

Signed-off-by: Michael Shaw <spencershawiscool@gmail.com>
2024-06-17 22:19:25 -04:00
Michael Shaw
4a997cec35 trap: explicitly handle certain exceptions 2024-06-13 22:51:18 -04:00
Michael Shaw
37518aea81 usr: implement user process switching
This is a rather large commit, so the gist of it is this:

User context switching is now functional, after a change to the TSS, and
a few minor details in the scheduler and loader.

ELF parsing is rather primitive, but basically functional, as long as it
only loads code.

The interrupt 0x80 is for syscalls, and will switch from user mode to
kernel mode. It is currently the only interrupt that can be called from
user mode

This adds the syscall functionality, which currently uses a red-black
tree to store the function pointers, although when the table is more
flushed out, it will probably be replaced with an array

The pager now correctly marks the parent nodes with attributes as it
allocates them. Without doing this, the page table entries will never be
reached in lower privilege modes, causing page faults

Signed-off-by: Michael Shaw <spencershawiscool@gmail.com>
2023-11-20 22:07:35 -05:00
Michael Shaw
2c88b77edd init: correct TSS impl, generalize stack loading 2023-11-01 17:43:27 -04:00
Michael Shaw
158004fd88 asm: clean up reg.S with fancy macro 2023-10-20 13:33:39 -04:00
Michael Shaw
75d156c4e3 stack_init: fix bug 2023-04-30 01:11:07 -04:00
Michael Shaw
e1108b3493 mem: improve slabbing to include flags 2023-04-29 16:54:12 -04:00
Michael Shaw
7bddf838fd mem: initialize the stacks
the stacks will now no longer be overwritten by the buddy allocator and
have a fixed size macro `KSTACK_SIZE`
2023-04-21 17:56:06 -04:00
Michael Shaw
74a58d6641 mem: add basic slab allocator 2023-04-20 16:06:49 -04:00
Renamed from mem/cr3.S (Browse further)