Embedded Systems Question:
DMA deals with which address (physical/virtual addresses)?
Answer:
DMA deals with Physical addresses.
Only when CPU accesses addresses it refers to MMU(Memory
Management Unit) and MMU converts the Physical address to
Virtual address.
But, DMA controller is a device which directly drives the
data and address bus during data transfer. So, it is purely
Physical address. (It never needs to go through MMU &
Virtual addresses).
That is why when writing the device drivers, the physical
address of the data buffer has to be assigned to the DMA.
Only when CPU accesses addresses it refers to MMU(Memory
Management Unit) and MMU converts the Physical address to
Virtual address.
But, DMA controller is a device which directly drives the
data and address bus during data transfer. So, it is purely
Physical address. (It never needs to go through MMU &
Virtual addresses).
That is why when writing the device drivers, the physical
address of the data buffer has to be assigned to the DMA.
Previous Question | Next Question |
Can we use semaphore or mutex or spin lock in interrupt context in linux kernel? | What is dirac delta function and its fourier transform and its importance? |