CS452 - Real-Time Programming - Spring 2010

Public Interest Announcements

Lecture 12 - Hardware Interrupts

What is an Interrupt?

In the CPU

  1. Test interrupt signal
  2. Change mode to IRQ
  3. Disable interrupt signal
  4. Execute instruction at 0x18

In the Interrupt Control Unit (ICU)

In the Peripheral Hardware

Context Switches for Interrupts

Difference from Software Interrupts

Assymmetry between User Task and Kernel

Scratch Registers

Two Link Registers

Helpful Features

  1. Trigger hardware interrupt from software

Kernel Provision for Interrupts

  1. Initialize the kernel with interrupts disabled
  2. Turn on interrupts by having user PSW with interrupts enabled
  3. Find source of interrupt
  4. Turn off source of interrupt
  5. Handle interrupt
  6. Reschedule and activate

Three Free Choices

  1. Rescheduling
  2. Volatile Data
  3. Re-enabling interrupts

Return to: