Page 1 of 1

A question about double faults

Posted: Wed Mar 13, 2024 7:31 pm
by TheNNX
Both the OSDev Wiki and the Intel Software Developer’s Manual state that if an exception occurs when inside another exception handler, under certain condition, the details of which are not really important to the question, a double fault occurs. How does the CPU know if it is executing a handler already? Does IRET clear some internal register which is set when an interrupt occurs?

Thanks

Re: A question about double faults

Posted: Tue Jun 11, 2024 10:48 pm
by Octocontrabass
TheNNX wrote:when inside another exception handler
It's not when inside another exception handler, it's when calling another exception handler. As in, after the CPU has detected an exception, but before it can start executing the first instruction of the handler for that exception.