Hardware interrupt is a signal that indicates that an event caused by the hardware has occurred. Therefore, it deviates the normal flow of CPU operation so that the CPU can deal with the interrupting device. When a hardware interrupt occurs, the original program that is being executed by the CPU is suspended and its status saved. The control is then transferred to an interrupt handler which is a special routine that processes interrupts. The interrupt handler, performs the tasks or the processes that correspond to the interrupt. Once it is complete, the control is either returned back to the previous program that was executing or to a different process according to the triggers (Valvano and Yerraballi)
Devices that transfer large amount of data by use of disk controllers use Direct Memory Access (DMA) Controllers to handle disk read or write interrupts. In this case, the host executes a command to a Disk Memory Access (DMA) that clearly indicates the address location of the data, the address location to transfer the data, and the size of the data in bytes that needs to be transferred. With this information provided, the DMA controller performs the data transfer operation and interrupts the CPU when it is complete. The DMA Controllers handshaking is normally accomplished by use of Direct Memory Access-request and Direct Memory Access-acknowledgement wires (Marinov).
When the DMA transfer is executing, the CPU does not access the PCI bus that includes the main memory. This helps to avoid any interruptions that may affect the data transfer. The Direct Memory Access (DMA) can be done by use of physical addresses or by mapping virtual addresses into physical addresses. Another approach of data transfer is Direct Virtual Memory Access (DVMA). This allows data to be transferred from one memory to another without the use of the main memory (Marinov).
Works Cited
Marinov, Peter. Guide: Intercepting and Processing Hardware Interrupts. Delorie, Nov. 1998. Web. 02 July 2016. From http://www.delorie.com/djgpp/doc/ug/interrupts/hwirqs.html.
Valvano, Jonathan., and Yerraballi, Ramesh. Embedded Systems - Shape The World. UTexas, 2014. Web. 02 July 2016. From http://users.ece.utexas.edu/~valvano/Volume1/E-Book/C12_Interrupts.htm.