Double fault occurs after local APIC timer interrupt handler finishes.

Question about which tools to use, bugs, the best way to implement a function, etc should go here. Don't forget to see if your question is answered in the wiki first! When in doubt post here.
Post Reply
darrkenn
Posts: 2
Joined: Sun Mar 01, 2026 7:41 pm

Double fault occurs after local APIC timer interrupt handler finishes.

Post by darrkenn »

Hi,
I'm currently developing a hobby OS in Rust for x86_64.

The local APIC timer has been setup, and successfully sends an interrupt.
However the handler for this interrupt always results in a double fault once it completes.
The fault occurs even if there is no code in the handler.

Repo: https://github.com/darrkenn/os

Any help would be greatly appreciated :)
Octocontrabass
Member
Member
Posts: 6249
Joined: Mon Mar 25, 2013 7:01 pm

Re: Double fault occurs after local APIC timer interrupt handler finishes.

Post by Octocontrabass »

What does your virtual machine say about the double fault? (Since you're using QEMU, add "-d int" to the command line.)
darrkenn
Posts: 2
Joined: Sun Mar 01, 2026 7:41 pm

Re: Double fault occurs after local APIC timer interrupt handler finishes.

Post by darrkenn »

Thanks for the quick reply and pointing me in the correct direction.
The double fault is not occurring any more. Setting the DS, SS and ES GDT registers correctly after boot fixed the issue.
Post Reply