Michael Shaw
4ec7ff5aaa
ipc: add fifo
2025-02-12 20:01:48 -05:00
Michael Shaw
15c0de6de8
lock: add mutex
...
Signed-off-by: Michael Shaw <spencershawiscool@gmail.com>
2025-02-11 21:34:08 -05:00
Michael Shaw
b9ffc10ace
atomic: replace operand size with 32-bit %eax
2024-11-26 21:10:35 -05:00
Michael Shaw
eae487678c
stdio: add line feed on new line
2024-08-21 01:39:38 -04:00
Michael Shaw
9c5d722f72
atomic: replace movq $0 with xorq
2024-07-05 05:51:11 -04:00
Michael Shaw
52ba70f4b7
dev: remove console driver, merge into serial
...
Signed-off-by: Michael Shaw <spencershawiscool@gmail.com>
2024-06-17 20:32:44 -04:00
Michael Shaw
cb288f547e
syscall: fix page fault on non-existent syscall
...
Signed-off-by: Michael Shaw <spencershawiscool@gmail.com>
2024-06-13 22:59:38 -04:00
Michael Shaw
e4116bd3e8
lib: move lock/atomic into lib folder
2024-03-19 00:19:42 -04:00
Michael Shaw
b5d8e0a2f7
rbtree: edit ifs to conform to kernel style
2024-02-28 03:16:53 -05:00
Michael Shaw
1b39d3f863
sem: implement semaphore
2024-02-22 03:35:02 -05:00
Michael Shaw
c487c4c9dd
devfs: add vnodes to devfs tree
2024-02-12 21:11:56 -05:00
Michael Shaw
c296cb9cf1
sort: add qsort
2024-02-07 22:59:20 -05:00
Michael Shaw
a6b7d9b42d
lib: add basic stack type
...
I can't believe I've made it this far without needing one
2024-01-30 22:08:36 -05:00
Michael Shaw
a10509f1e5
lib: move lib headers into lib directory
2024-01-30 22:00:20 -05:00
Michael Shaw
874e63e41c
tty: add stubs for console_write and console_read
2023-11-29 19:37:04 -05:00
Michael Shaw
e2d9609bf7
console: rename console_write to console_putchar
2023-11-29 19:33:56 -05:00
Michael Shaw
146e9b775e
rbtree: fix bug in delete fixup causing page fault
2023-11-27 14:27:56 -05:00
Michael Shaw
3dda839cdd
syscall: implement write syscall
2023-11-22 23:27:39 -05:00
Michael Shaw
aac47e60f3
proc: free pages and fds after proc termination
2023-11-22 21:55:52 -05:00
Michael Shaw
823f811954
mmap: generalize mmap
...
also add a range search function to ensure that memory allocations do
not overlap in virtual space
2023-11-15 16:56:29 -05:00
Michael Shaw
a85be6eb62
elf: add basic elf parsing
2023-11-15 12:50:46 -05:00
Michael Shaw
2fe0b0068b
sched: begin scheduling module
2023-11-13 22:23:06 -05:00
Michael Shaw
06b02fc9a6
kmalloc: add fallback for failed DMA allocations
2023-11-03 14:43:53 -04:00
Michael Shaw
d813fabae9
boot: start APs after BSP init
2023-11-01 15:29:45 -04:00
Michael Shaw
4dc4f07dc6
mem: improve device memory mapping
...
MMIO ports will no longer directly map to HHDM addresses and will need
to be searched for in the memory mapping tree
2023-10-24 22:16:33 -04:00
Michael Shaw
d42cd7b090
stdio: fix some page faults
2023-10-23 21:54:14 -04:00
Michael Shaw
19f32aef3f
ext2: add ability to create files
2023-10-23 17:03:20 -04:00
Michael Shaw
f8d84c7780
ext2: implement file writing
...
there is much room for improvement in the traversal of indirectly linked
blocks
2023-10-21 12:54:35 -04:00
Michael Shaw
ad2de927e2
ext2/vfs: implement read fs call
...
also implement the cat command!
2023-10-21 00:46:42 -04:00
Michael Shaw
0029621ada
cmd: add initial commands ls and help
2023-10-20 23:56:01 -04:00
Michael Shaw
cd8d016f34
ext2: fix memory leak
2023-10-20 01:11:10 -04:00
Michael Shaw
0eb461410c
fs: implement readdir function
...
this also fixes flawed file parsing in ext2_open_file
2023-10-20 00:51:28 -04:00
Michael Shaw
9aea93214a
errno: add strerror function
2023-10-19 22:13:09 -04:00
Michael Shaw
9476b3f810
string.c: rework strtok again
2023-10-19 14:20:22 -04:00
Michael Shaw
08b54c22f5
string: reword strtok
2023-10-19 14:18:33 -04:00
Michael Shaw
25a828437a
fs: move fs init into kernel cmdline
...
Previously, any partition with an ext2 filesystem would be mounted by
the gpt header parser. With this patch, the kernel cmdline `root=val` is
responsible for mounting the root filesystem.
2023-10-19 11:08:54 -04:00
Michael Shaw
746c907a43
string: add strncpy
2023-10-18 20:58:03 -04:00
Michael Shaw
a6ffef77b9
string: remove incorrect lock on strtok
2023-10-18 20:56:24 -04:00
Michael Shaw
3806d53237
string: add lock to strtok
2023-10-18 20:51:49 -04:00
Michael Shaw
5ab34eb11b
string: add strtok
2023-10-18 20:46:41 -04:00
Michael Shaw
db5990cc97
mem: add locks to kernel memory management structures
2023-05-27 02:11:27 -04:00
Michael Shaw
29a0435cf6
slab: replace struct slab with slab_t
...
This type should never be modified by the user, and only passed into the
functions in slab.c. Using a typedef to notifies the user semantically
of this fact
2023-05-19 16:49:34 -04:00
Michael Shaw
0395b65ad8
stdio: add vsnprintf and change printf to kprintf
2023-05-14 01:23:21 -04:00
Michael Shaw
82c32011b4
rbtree: fix previously flawed implementation
...
got book'd up
Signed-off-by: Michael Shaw <spencershawiscool@gmail.com>
2023-05-11 12:51:14 -04:00
Michael Shaw
408f00bb05
rbtree: add rbt_destroy
...
This function will free all the nodes inside the red-black tree. It is still
on the caller to free the struct rbtree that they passed into the function
if it was dynamically allocated
2023-05-10 23:23:24 -04:00
Michael Shaw
ea1c1b337d
rbt: remove verify function
2023-05-10 21:57:40 -04:00
Michael Shaw
5121e78470
rbtree: cleanup functions
2023-05-10 21:55:17 -04:00
Michael Shaw
796ce36831
rbt: improve verification function
2023-05-10 21:53:27 -04:00
Michael Shaw
4e36cfd90b
lib: add rbtree data structure
...
This also switches the kmalloc allocator over to the new rbtree
structure. As a balanced binary search tree, it is much more efficient
than the previous method
2023-05-10 21:24:19 -04:00
Michael Shaw
14a681c53e
string: add strsplit
2023-05-09 23:00:07 -04:00