aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Makefile3
-rw-r--r--README.md1
-rw-r--r--src/kernel/api/io.h2
-rw-r--r--src/kernel/io.c2
-rw-r--r--src/kernel/main.c19
5 files changed, 10 insertions, 17 deletions
diff --git a/Makefile b/Makefile
index 9184028..92e5e8e 100644
--- a/Makefile
+++ b/Makefile
@@ -53,7 +53,8 @@ iso: $(KERNEL)
limine bios-install $(ISO_IMAGE)
run: iso
- qemu-system-x86_64 -cdrom $(ISO_IMAGE) #-vga std -device VGA,edid=on,xres=640,yres=320
+ qemu-system-x86_64 -cdrom $(ISO_IMAGE) -vga virtio
+ # -device VGA,edid=on,xres=640,yres=320
clean:
rm -vrf $(BUILD_DIR)
diff --git a/README.md b/README.md
index e40896b..b205949 100644
--- a/README.md
+++ b/README.md
@@ -3,7 +3,6 @@
a minimal and experimental x86_64 heapless unix-like OS von czjstmax. \
the name is based off the german word for trash. haha.
- 
> you can test müllos by running `make run` in the cloned repo.
---
diff --git a/src/kernel/api/io.h b/src/kernel/api/io.h
index 7a9fc38..4c11eac 100644
--- a/src/kernel/api/io.h
+++ b/src/kernel/api/io.h
@@ -7,4 +7,4 @@
// includes
#include <stdint.h>
-void RealPrint(const char* str);
+void VGA_RPrint(const char* str);
diff --git a/src/kernel/io.c b/src/kernel/io.c
index 10fcac1..22a5fa3 100644
--- a/src/kernel/io.c
+++ b/src/kernel/io.c
@@ -7,7 +7,7 @@
volatile uint16_t* VGA = (volatile uint16_t*)0xB8000;
uint16_t cursor = 0;
-void RealPrint(const char* str) {
+void VGA_RPrint(const char* str) {
while(*str) {
VGA[cursor++] = (uint8_t)(*str) | 0x0700; // white on black
str++;
diff --git a/src/kernel/main.c b/src/kernel/main.c
index e62740c..be6f1fd 100644
--- a/src/kernel/main.c
+++ b/src/kernel/main.c
@@ -27,19 +27,12 @@ static volatile uint64_t limine_requests_end_marker[] = LIMINE_REQUESTS_END_MARK
// API includes
#include "api/io.h"
-void kmain(void) __attribute__((noreturn));
-void _start(void) {
- if (!framebuffer_request.response) {
- for (;;) __asm__("hlt");
- }
-
- struct limine_framebuffer *fb =
- framebuffer_request.response->framebuffers[0];
-
- uint32_t *pix = fb->address;
- pix[0] = 0x00FFFFFF; // white pixel
+void kernel_main(void) __attribute__((noreturn));
- //return kernel_main();
- for (;;) __asm__("hlt");
+void _start(void) {
+ return kernel_main();
}
+void kernel_main(void) {
+ //
+}