Hi, I've been following the Kernel tutorials by James Molloy (and have applied the fixes listed in the known issues wiki page), and have been testing out interrupts.
Interrupts work fine, and call the appropriate handler up to 0x2F (47), but any larger than that and I get a general protection fault. Interrupt 0x30 (48) for example gives a general protection fault with error code 386.
Is this a known issue with the tutorial, has anyone else experienced this issue?
General protection fault on interrupts > 0x2F
Re: General protection fault on interrupts > 0x2F
Have a look at the error Code: http://wiki.osdev.org/Exceptions#Genera ... tion_Fault
Is interrupt descriptor 48 and following properly set up?
Is interrupt descriptor 48 and following properly set up?
Re: General protection fault on interrupts > 0x2F
It should be, I've registered an interrupt handler from it and created the interrupt properly. The exact same code works for interrupts below that number after altering the handler/interrupt registering.
It's also still running in ring 0 where paging isn't yet set up, so it shouldn't be a permissions issue.
It's also still running in ring 0 where paging isn't yet set up, so it shouldn't be a permissions issue.
- BrightLight
- Member
- Posts: 901
- Joined: Sat Dec 27, 2014 9:11 am
- Location: Maadi, Cairo, Egypt
- Contact:
Re: General protection fault on interrupts > 0x2F
Permission issues cause Page Faults, not General Protection Faults. Check the error code and let us see it.Cl9 wrote:It should be, I've registered an interrupt handler from it and created the interrupt properly. The exact same code works for interrupts below that number after altering the handler/interrupt registering.
It's also still running in ring 0 where paging isn't yet set up, so it shouldn't be a permissions issue.
You know your OS is advanced when you stop using the Intel programming guide as a reference.
Re: General protection fault on interrupts > 0x2F
Erm, I might have forgotten to register it properly before hand with the descriptor tables....
That took me a few hours too long to figure out :'(
That took me a few hours too long to figure out :'(