not sure what these changes were
This commit is contained in:
parent
cd3d8871df
commit
50f5723733
|
@ -41,6 +41,6 @@ add_custom_command(OUTPUT os.iso
|
||||||
)
|
)
|
||||||
|
|
||||||
# Run & Debug targets
|
# Run & Debug targets
|
||||||
add_custom_target(run COMMAND qemu-system-i386 -boot d -cdrom os.iso -m 512 -machine type=pc-i440fx-3.1 -monitor stdio DEPENDS os.iso)
|
add_custom_target(run COMMAND qemu-system-i386 -boot d -cdrom os.iso -m 512 -machine type=pc-i440fx-3.1 -monitor stdio -drive id=disk,file=/dev/null,if=none -device ahci,id=ahci -device ide-hd,drive=disk,bus=ahci.0 DEPENDS os.iso)
|
||||||
add_custom_target(debug COMMAND ./debug.sh DEPENDS os.iso)
|
add_custom_target(debug COMMAND ../debug.sh DEPENDS os.iso)
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
#include "./scheduler.c"
|
#include "./scheduler.c"
|
||||||
#include "./vga.c"
|
#include "./vga.c"
|
||||||
|
#include "./rsdp.c"
|
||||||
#include <stdint.h>
|
#include <stdint.h>
|
||||||
|
|
||||||
#include "./test_processes.c"
|
#include "./test_processes.c"
|
||||||
|
@ -14,6 +15,9 @@ int kernel_main() {
|
||||||
outb(0x3D4, 0x0A);
|
outb(0x3D4, 0x0A);
|
||||||
outb(0x3D5, 0x20);
|
outb(0x3D5, 0x20);
|
||||||
|
|
||||||
|
|
||||||
|
find_rsdp();
|
||||||
|
for(;;){}
|
||||||
clear_screen();
|
clear_screen();
|
||||||
|
|
||||||
interrupt_disable();
|
interrupt_disable();
|
||||||
|
|
|
@ -2,6 +2,31 @@
|
||||||
|
|
||||||
#include <stdint.h>
|
#include <stdint.h>
|
||||||
|
|
||||||
|
// Below doesn't work!
|
||||||
|
//uint8_t streq(char *ptr, char* ptr2) {
|
||||||
|
// while (1 == 1) {
|
||||||
|
// if (*ptr != *ptr2) {
|
||||||
|
// return 0;
|
||||||
|
// }
|
||||||
|
//
|
||||||
|
// if (*ptr == '\0') {
|
||||||
|
// return 1;
|
||||||
|
// }
|
||||||
|
//
|
||||||
|
// ptr++;
|
||||||
|
// ptr2++;
|
||||||
|
// }
|
||||||
|
//}
|
||||||
|
|
||||||
|
uint8_t memseq(char *ptr, char *ptr2, uint32_t len) {
|
||||||
|
for (uint32_t i = 0; i < len; i++) {
|
||||||
|
if (ptr[i] != ptr2[i]) {
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
|
||||||
void memset(char *ptr, char data, uint32_t len) {
|
void memset(char *ptr, char data, uint32_t len) {
|
||||||
for (uint32_t i = 0; i < len; i++) {
|
for (uint32_t i = 0; i < len; i++) {
|
||||||
ptr[i] = data;
|
ptr[i] = data;
|
||||||
|
|
Loading…
Reference in a new issue