The bootloader for my OS is setting up paging, but when I want to write to a page that isn't writeable bochs crashes with this message:
"exception(): 3rd (14) exception with no resolution, shutdown status is 00h, resetting".
Shouldn't I, as the kernel, be able to overwrite memory everywhere?
Can't write memory
Re:Can't write memory
Well yeah, you can overwrite nearly all *physical* memory you want. But if you have paging enabled, you need to map the corresponding virtual memory in before your kernel has something to write to at that address.xalator wrote:Shouldn't I, as the kernel, be able to overwrite memory everywhere?
- Pype.Clicker
- Member
- Posts: 5964
- Joined: Wed Oct 18, 2006 2:31 am
- Location: In a galaxy, far, far away
- Contact:
Re:Can't write memory
it basically depends on whether you have turned on the "WP" bit or not (i thing it's in CR0 aswell ...)xalator wrote: Shouldn't I, as the kernel, be able to overwrite memory everywhere?
However, if the page is not present, you cannot access it, regardless of whether you're in supervisor or user mode ...