PeachOS
PeachOS copied to clipboard
Simple kernel designed for a online course
https://github.com/nibblebits/PeachOS/blob/master/src/fs/fat/fat16.c#L411: `if (entry == 0xFF8 || entry == 0xFFF)` This line is checking if the cluster entry is the last cluster in a file. However, the value it is checking...
Hey Dan, It seems that the current symbol file is giving incorrect memory addresses in GDB. My assumption and correct me if I am wrong is that `i686-elf-ld -g -relocatable...
Tried running in bochs emulator, and it seems to be a bit more strict than qemu, so it caught some issues. Here are issues that I spotted after trying bochs:...
On file idt.h INTERRUPT_CALLBACK_FUNCTION should be `typedef void (*INTERRUPT_CALLBACK_FUNCTION)(struct interrupt_frame *frame);`
Hey Dan! I found a memory leak in the fopen() function. In case of an error, we do not free root_path or descriptor_private_data. this would create a memory leak, especially...
Hey! There are a few problems with the code to switch to pmode: 1. we should turn on a20 line before switching to pmode 2. we set the segment registers...
When we call `task_return` function we for some reason push FLAGS which are from kernel code but not from the userspace code. This causes userspace code to have wrong FLAGS...
Hi! In PeachOS Master, there is a possible memory leak in process_load_for_slot. Say we get an error on line 500: `res = process_load_data(filename, _process); if (res < 0) { goto...
Hey Dan! Correct me if i am wrong, but I believe there is an error in fat16_read. We never advance fat_desc->pos, thus in a situation such that we would read...
` elf_file->elf_memory = kzalloc(stat.filesize); res = fread(elf_file->elf_memory, stat.filesize, 1, fd); if (res < 0) { goto out; } res = elf_process_loaded(elf_file); if(res < 0) { goto out; } ` in...