Skip to main content
Engineering LibreTexts

20.4: Suspension Interrupt Processing Summary

  • Page ID
    19991
  • \( \newcommand{\vecs}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \) \( \newcommand{\vecd}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash {#1}}} \)\(\newcommand{\id}{\mathrm{id}}\) \( \newcommand{\Span}{\mathrm{span}}\) \( \newcommand{\kernel}{\mathrm{null}\,}\) \( \newcommand{\range}{\mathrm{range}\,}\) \( \newcommand{\RealPart}{\mathrm{Re}}\) \( \newcommand{\ImaginaryPart}{\mathrm{Im}}\) \( \newcommand{\Argument}{\mathrm{Arg}}\) \( \newcommand{\norm}[1]{\| #1 \|}\) \( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\) \( \newcommand{\Span}{\mathrm{span}}\) \(\newcommand{\id}{\mathrm{id}}\) \( \newcommand{\Span}{\mathrm{span}}\) \( \newcommand{\kernel}{\mathrm{null}\,}\) \( \newcommand{\range}{\mathrm{range}\,}\) \( \newcommand{\RealPart}{\mathrm{Re}}\) \( \newcommand{\ImaginaryPart}{\mathrm{Im}}\) \( \newcommand{\Argument}{\mathrm{Arg}}\) \( \newcommand{\norm}[1]{\| #1 \|}\) \( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\) \( \newcommand{\Span}{\mathrm{span}}\)\(\newcommand{\AA}{\unicode[.8,0]{x212B}}\)

    The following diagram presents an overview of the general flow used for processing interrupts by the system.

    截屏2021-08-01 下午10.53.04.png

    1. Execution of current program is suspended

    - save rip and rFlags registers to stack

    2. Obtain starting address of Interrupt Service Routine (ISR)

    - interrupt number multiplied by 16
    - used as offset into Interrupt Descriptor Table (IDT)
    - obtains ISR address (for that interrupt) from IDT

    3. Jump to Interrupt Service Routine - set rip to address from IDT

    4. Interrupt Service Routine Executes

    - save context (i.e., any additional registers altered)
    - process interrupt (specific to interrupt generated)
    - schedule any later data processing activities

    5. Interrupted Process Resumption

    - resume scheduling based on OS scheduler
    - restore context
    - perform iret (to pop rFlags and rip registers)

    This interrupt processing mechanism allows a dynamic, run-time lookup for the ISR address.


    This page titled 20.4: Suspension Interrupt Processing Summary is shared under a CC BY-NC-SA license and was authored, remixed, and/or curated by Ed Jorgensen.

    • Was this article helpful?