Skip to content
This repository has been archived by the owner on Oct 22, 2022. It is now read-only.

Releases: DonaldKellett/marvelos

Spectacular Scheduler

15 Oct 04:23
Compare
Choose a tag to compare

Finally, we have some semblance of a userspace: a system call that does nothing other than print Test syscall, a template init_process for userspace processes hardcoded within the kernel that just invokes our test syscall in an infinite loop, and a round robin scheduler that just juggles around three copies of init_process forever.

Of course, no operating system should ever hardcode user processes in the kernel; instead, it should be able to read user programs from disk and launch them as processes. So that's what we're going to do next!

Invincible Interruptor

08 Oct 10:05
Compare
Choose a tag to compare

There's still no userspace yet, but hey, we can now handle all sorts of traps and interrupts:

  • Load page faults
  • Store/AMO page faults
  • Timer interrupts
  • External interrupts (UART)

In particular, with external interrupts enabled, we can finally listen to our UART and respond to keyboard input. At the moment, it doesn't do much beyond echoing the input back to the user and powering down the board when it receives a Ctrl-C, but it's a good start nonetheless. Hopefully, with process management next on the list, we can start to see some semblance of a userspace.

Super Sv39

01 Oct 15:29
Compare
Choose a tag to compare

Still a looooong way to go before I get to anything resembling a remotely usable operating system from an end user's perspective, but anyway, I'd like to take the time to celebrate the fact that I finally turned the MMU on and got it working!

The project codebase has also seen some notable improvements which should aid with maintenance and development going forward:

  • Implemented page-grained allocator
  • Implemented Sv39 routines
  • Implemented byte-grained allocator (kmalloc, kcalloc, kfree)
  • Turned on Sv39 paging in S-mode and confirmed that dynamic memory allocation works for basic use cases
  • Rewrote linker script from scratch to something I actually fully understand and have full control over
  • Extended the C runtime crt0.s to support switching from M-mode to S-mode
  • Added format target for make in order to enforce consistent formatting across the codebase

Meaty Skeleton

09 Sep 15:21
Compare
Choose a tag to compare

A meaty skeleton for fellow OSDev'ers to base their RISC-V operating system upon:

  • Hierarchial project structure with make build system for sustainable mid- to long-term development
  • Includes debug target for debugging with GDB (requires cross-debugger targeting riscv64-elf)
  • Basic console output through NS16550A UART
  • Convenience wrappers for powering off and rebooting the device
  • Working kprintf supporting base format specifiers (no floating point support; no sub-specifiers; no n specifier) to facilitate printf debugging
  • panic function for kernel panics