When a device interrupt occurs, how does the processor determine which device issued the interrupt? How an interrupt mechanism works- explain briefly?
Answers
Answer:
When there is only a single interrupt vector supported by the CPU, each interrupt handler has to chain from the one previously installed, and make its own determination whether “its own” device was the one that triggered the interrupt, or pass control on to the previous interrupt handler if it wasn't.
Answer:
An interrupt is like a shopkeeper. If one needs a service or product, he goes to him and apprises him of his needs.
Explanation:
- An interrupt is indicated by a signal sent by the device interface to the CPU via an interrupt request line. This signal notifies the CPU that there is an interrupt
- Four general categories of techniques are in common use: multiple interrupt lines; software poll; daisy chain (hardware poll, vectored); bus arbitration (vectored).
Interrupt mechanism work as follow:
An interrupt is a signal to the processor emitted by hardware or software indicating an event that needs immediate attention. Whenever an interrupt occurs, the controller completes the execution of the current instruction and starts the execution of an Interrupt Service Routine (ISR) or Interrupt Handler