Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What is the difference between DMA and memory-mapped IO?

What is the difference between DMA and memory-mapped IO? They both look similar to me.

like image 918
brett Avatar asked Oct 03 '10 21:10

brett


People also ask

What is the difference between programmed IO and DMA?

What is the difference between the two modes? PIO stands for Programmed Input/Output, which is a protocol for data transfer. Since it involves the CPU, the use of PIO mode for data transfer can slow a computer down considerably. On the contrary, DMA (Direct Memory Access) does not involve the CPU.

What is difference between memory mapped IO and IO mapped IO?

The basic difference between memory mapped IO and IO mapped IO is that memory mapped IO uses the same address space for both memory and IO device while IO mapped IO uses two separate address spaces for memory and IO device.

What is difference between DMA and DMA controller?

DMA is an abbreviation of direct memory access. DMA is a method of data transfer between main memory and peripheral devices. The hardware unit that controls the DMA transfer is a DMA controller. DMA controller transfers the data to and from memory without the participation of the processor.

What is meant by memory mapped I O?

Memory-mapped I/O uses the same address space to address both memory and I/O devices. The memory and registers of the I/O devices are mapped to (associated with) address values. So when an address is accessed by the CPU, it may refer to a portion of physical RAM, or it can instead refer to memory of the I/O device.


1 Answers

Memory-mapped I/O allows the CPU to control hardware by reading and writing specific memory addresses. Usually, this would be used for low-bandwidth operations such as changing control bits.

DMA allows hardware to directly read and write memory without involving the CPU. Usually, this would be used for high-bandwidth operations such as disk I/O or camera video input.

Here is a paper has a thorough comparison between MMIO and DMA.

Design Guidelines for High Performance RDMA Systems

like image 151
Greg Hewgill Avatar answered Oct 18 '22 10:10

Greg Hewgill