For an operating systems project, I need to change the behaviour of the timer interrupt handler. To my understanding so far, there are basically two ways:
- Change the descriptor in the Interrupt Descriptor Table to my own interrupt handler.
- Modify the existing timer interrupt handler to include my functionality.
Option 2 seems less intrusive and since performance is not a main concern of the project, I currently prefer to follow this path. The architecture I am working with is x86, but it would be very good if there would be a generic solution to manipulate the behaviour of the timer interrupts.
The problem for me is, that if I try to grep myself through the source code, I get lost in this jungle of files and directories. So after some amount of time, I basically just were able to run around in circles with little to show for it, so my question is:
How would I go about changing the default behaviour of the timer interrupt handler of the linux kernel?