Commit Graph

86 Commits

Author SHA1 Message Date
fffcc03460 Add EFI headers. 2019-09-11 23:44:47 +01:00
8a54815712 Add all of the functionality to allow the kernel to boot itself.
This is a trimmed down version of Syncboot integrated into the kernel.
The plan is, eventually, to allow the kernel to be booted by Syncboot, but that'll take a lot of research into QEMU.
This was just quicker to do.

This isn't tested, as I still need to figure out how to compile the EFI entry point separately.
They can be linked together, however. That's why the kernel is designed around a PE32+ format.
2019-09-11 23:44:11 +01:00
51af007cd5 Many small changes 2019-09-11 03:59:27 +01:00
ae6d4ecabd ? 2019-09-11 03:59:11 +01:00
2536c58607 Redo the utils file 2019-09-11 03:59:01 +01:00
b13f7e6755 Add debugging to the bootstrap, reformat some function names 2019-09-11 03:58:53 +01:00
c22bd248e3 Serial reformat, minor bug fixes 2019-09-11 03:58:20 +01:00
5dadfeb8fd Small workspace cleanup 2019-09-11 03:57:55 +01:00
f79f04361a Added a ClearScreen call to the graphics init.
This should erase everything on the screen before anything else.
2019-08-20 16:42:57 +01:00
6238fbf8fe Added serial functions to the kernel header, making them global.
Also moved the definition of IRQ_Functions out of the header, as this is changed.
2019-08-20 16:42:24 +01:00
d3c8dd45c7 Enable all serial debugging outputs in the interrupt handlers.
Serial should be working now, but i can never trust things to work first time.
2019-08-20 16:41:50 +01:00
4af4ad89a4 Updated the kernel.c comments.
Minor changes, but whatever.
2019-08-20 16:41:11 +01:00
c5178d56bd Semantics. 2019-08-20 16:40:48 +01:00
f33b63d1fb Removed beep on boot.
That stuff hurts, man.
Also moved all the ASM port wrappers into their own file.
2019-08-20 16:40:20 +01:00
d830acbbd4 Fix WritePort mistakes in the serial file. 2019-08-20 16:39:20 +01:00
927aeb0872 Fix an implicit function declaration 2019-08-19 23:51:15 +01:00
9308aaa300 Fix some small pointer issues. 2019-08-19 23:50:59 +01:00
f980acc136 Fix a small bug in the GDT sections that can cause a halt in the kernel.. 2019-08-19 23:02:48 +01:00
f0ca9de14b Added the current timer tick as a global variable. 2019-08-19 22:58:45 +01:00
2691c1e30e Seriously prioritise output.
Added a beep function to allow PC Speaker output.
This will require an edit to the current QEMU launchscript to get working.
2019-08-19 22:58:26 +01:00
437e10e86c Prioritise output before all else, just so we know when the kernel actually works. 2019-08-19 22:55:28 +01:00
24aad1e4a5 Fix a silly issue with the Interrupts using bits instead of bytes when reading and writing ports. 2019-08-19 22:54:08 +01:00
bec10bcee8 Gitignore weirdness. 2019-07-25 00:44:34 +01:00
a5ce202055 Update README for new build.
NOTE: for every new successful build, start incrementing the SYNC_VERSION constants in kernel.h :D
2019-07-24 21:53:01 +01:00
f9dcdf5cc9 Update compiler script.
It all works now.
\o/
2019-07-24 21:50:26 +01:00
d2d532c535 Add missing file to c_files.txt 2019-07-24 21:50:01 +01:00
7cafb959dd Add missing Reserved ISR Handler function. 2019-07-24 21:49:49 +01:00
5ed922bd20 Update serial functions for new WritePort system. 2019-07-24 21:49:35 +01:00
ebbe1d9346 Now that all the files we need are available..
Added the c_files.txt file required by the sneklang compiler script.
2019-07-24 20:25:21 +01:00
5760ed1dde Add some public-domain memory manipulation files as a stand-in for my AVX functions.
These are messy, but they let the kernel compile.
2019-07-24 20:24:38 +01:00
78dcb1a707 New compiler script!
Now with 100% more sneklang!
2019-07-24 20:19:49 +01:00
f92114539c It's interrupt time, baby.
This should bring the kernel to a working state.
Don't forget that the interrupts.c file absolutely must be compiled with -mgeneral-regs-only.
All the other files absolutely must be compiled with -mavx2.

:)
2019-07-24 19:47:44 +01:00
debd7ef91a Slight kernel.h cleanup. 2019-07-24 15:54:32 +01:00
f74809718a Slight cleanup of utils.c
Also added the missing memX functions needed for compilation.
Interrupts next, I do believe.
2019-07-24 15:54:14 +01:00
e4500c27e3 Finish basic memory management.
This won't compile, as it's missing the xAVX functions.
I have a sort-of implementation of them, but it's brutal.
5400 lines total.

For now, they can be substituted with the x functions (remove AVX) to compile the kernel.
2019-07-24 15:53:39 +01:00
633f6b925e Add bitmap font.
Half home-brand, adapted from font8x8 from the public domain.
2019-07-24 01:39:53 +01:00
f88524a9b9 Starting memory management. 2019-07-24 01:39:12 +01:00
874e7e9a05 The print file.
A whopper. Lots of printing functions, most of them internal.
No this doesn't mean actual physical printing, it's printf, etc.
2019-07-24 01:39:00 +01:00
cdd8b7933f Remove inb and outb, since they have counterparts in ReadPort and WritePort. 2019-07-24 01:38:00 +01:00
f524eee6ff More minor changes.
Header and graphics had some one-liners.
2019-07-24 01:37:39 +01:00
80154dbb51 Update main kernel file and Utils for the new functions.
Can't use term_x any more.
2019-07-23 23:01:12 +01:00
15293681ea Add AVX memory prototypes, rename ResetDefaultScreen features to something more sensible. 2019-07-23 23:00:13 +01:00
d14da0af89 Add Graphics file.
A few TODOs here, but nothing that can't be handled.
2019-07-23 22:59:33 +01:00
67cbaad539 Add the bootstrap file.
Provides all the functions necessary to get the kernel started, and to continue working in the future.
It is to be split up in the future.
2019-07-23 20:32:24 +01:00
c795a936ae Fix some oversights in the header. 2019-07-23 19:27:47 +01:00
c9bd659f5c Add bootstrap source.
Made to manage holdover from Syncboot, but is half-finished because of
an issue with the prior mentioned header file.
2019-07-22 22:34:02 +01:00
2bfe904014 Add main kernel header.
Defines all of the structs, functions and variables for the new kernel.

Currently has some issues with GCC.
2019-07-22 22:33:07 +01:00
04e70ab274 Commenting improvements
Even more preparing for UEFI.
2019-07-22 22:32:35 +01:00
272d98f42e Shuffle headers
More preparing for UEFI.
2019-07-22 22:31:49 +01:00
87acb5463b Remove Multiboot header in preparation for moving to UEFI 2019-07-22 22:31:16 +01:00