16 Commits (f8a85a154130b2c4007f11766d247fc44aafabbd)

Author SHA1 Message Date
anna f8a85a1541
happy new year 2022 uwu
May it be slightly less exhausting than 2021.
2 years ago
anna 5a5135f416
update license terms
As of now, everything except the code imported
from FreeBSD is proprietary.  Of course, it won't
be like this for long, only until we have decided
which license we like to use.  The rationale is
that releasing everything under a copyleft license
later is always easier than doing so immediately
and then changing it afterwards.
Naturally, any changes made before this commit are
still subject to the terms of the CNPL.
3 years ago
anna ec889c08b9
types: add BSD style typedefs for unsigned types 3 years ago
anna 03f31df67f
x86: better separation for i386 specific code
That's it, nothing major is gonna happen anymore
until i get amd64 support working and deprecate
the entire i386 branch.  32-bit just adds so many
extra complications to memory management that i
don't want to waste any more energy on this
platform which is obsolete anyway.
3 years ago
anna c36b03d97c
mutex: avoid wait queue lock if possible
This also tidies up the atomic operations a little
and adds a new atom_cmp_xchg() as well as the same
APIs for longs and pointers.
3 years ago
anna f59229ba39
types: fix typo in u64 typedef
This would have been a fun one to debug if i
hadn't caught it right now
3 years ago
anna ad422894f2
mtx: add basic synchronization primitives 3 years ago
anna b2fccf1ecd
sched: add base for scheduling and task switching 3 years ago
anna afbb3743d5
refactor type and cdefs headers 3 years ago
anna 0f9e9f91a6
libc: port FreeBSD string library routines
Oh my fucking god this was by far the most awful
and boring and tedious day in my entire life.

Also, dear FreeBSD people: please don't sue me.
I tried really hard to comply with all the
copyright stuff, but it is absolutely possible i
made a mistake.  Just DM me and i'll do everything
in my power to fix it, even if that means
releasing entire portions of GayBSD under the BSD
license.  I don't care, i just want stuff to work.

(i'm including this message to use it as possible
evidence in case i get sued to show my good will)
3 years ago
anna d475429639
kprintf: implement "full" format sequence support
So this was painful.  kprintf() supports most of
the format specifiers from BSD now, except for the
$ sequence.  It has gotten a general overhaul and
is significantly more sophisticated, bloated and
slower now.  There is also some minor stuff i
forgot about, like the 't' length modifier, but
that isn't so important right now and will be
fixed later(TM).
3 years ago
anna f1922723f0
types.h: fix uintptr_t sign 3 years ago
anna 3f73072153
types.h: use rust-style naming scheme, add bools 3 years ago
anna 8fb2f7987c
kprintf: fix vararg bug
Turns out you can't pass a va_list to subroutines
as per the C standard, even though it worked
perfectly fine on ARM.  Well then, the entire
kprintf thing needs to be refactored anyway at
some point in the future, so that more formatting
options are supported.
3 years ago
anna 2bcb3242da
add misc utility headers 3 years ago
anna c7eb58b930
boot: add basic multiboot support
Turns out writing your own bootloader from scratch
is something you probably don't wanna be bothered
with when your main goal is writing an entire
operating system.  Blessed be the souls of the
maniacs who gave us GRUB, and punched be their
faces for writing such inconsistent documentation.
3 years ago