Handling Interrupts

Each device interacts with the computer by interrupting the processor so that it can send or retrieve data or carry out a function. A device must have a method for telling the computer's processor that it needs attention. A hardware device tells the processor that it needs attention through an interrupt request (IRQ) line. By using this method of interruption, the processor can function without the need to ask a device every few seconds whether it needs service.

interrupt request (IRQ)

The method used by a device to inform the microprocessor (CPU) that the device needs attention. Through this method of interruption, the microprocessor can function without needing to poll each device to see whether it needs service.

When a device interrupts the system processor, the processor stops what it is doing and handles the interrupt request. Because each device is assigned a number when the device is configured, the system knows which device needs attention. After the processor has attended to the device, it returns to the function it was performing before the interruption.

Each device must have a unique IRQ so that the processor knows what to attend to when a service request is called. There are exceptions to this rule; for instance, serial ports (also referred to as communication, or COM, ports) can share the same IRQ, but they must be assigned another unique identifier (I/O address). If any other devices share the same interrupt and need attention from the processor, the machine will hang or immediately reboot in the confusion of determining which device requested service. Plug-and-Play devices scan the system and determine an available interrupt request to assign to a new device during installation.

click to expand

Note 

The PCI bus standard enables devices connected to a PCI bus to communicate by using one common interrupt (IRQ10).

The following table shows the standard interrupts that most systems use, including Windows XP and Windows Server 2003.

  • System Device refers to the device that is configured to use the specified interrupt.

  • IRO refers to the interrupt request line that the hardware device uses to notify the processor that it needs attention.

  • IRQ numbers that are listed as available can be allocated to new devices that are installed in the computer.

    System Device

    IRQ

    System timer

    0

    Keyboard

    1

    Reserved

    2

    COMs 2, 4

    3

    COMs 1, 3

    4

    LPT2 (usually available for other devices)

    5

    Floppy disk controller

    6

    LPT1

    7

    Real-time clock

    8

    Redirected or cascaded to IRQ2

    9

    Available (also used for PCI common interrupt)

    10

    Available

    11

    PS/2 or bus mouse port (available if not used)

    12

    Math coprocessor

    13

    Hard disk controller

    14

    Available (also used for PCI secondary IDE controller)

    15




MCSA. MCSE 2003 JumpStart. Computer and Network Basics
MCSA/MCSE 2003 JumpStart
ISBN: 078214277X
EAN: 2147483647
Year: 2003
Pages: 203
Authors: Lisa Donald

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net