PCIe bulk transaction without DMA

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

PCIe bulk transaction without DMA

1,742 Views
rainerboschung
Contributor II

Question regarding initiate burst PCI Express transaction from Host CPU (T1040).

As far as I understand CPU access to PCI memory will end-up in a 32bit PCIE transfer requests, and for transactions making use of the max payload size of 256B one has to use DMA.

Since the device I have to read from does not support DMA I would like to know whether it is possible to create a single read transaction making use of the full payload size of 256B without using DMA.

Regards

Rainer

Labels (1)
Tags (3)
4 Replies

411 Views
SaLaManDer99
Contributor I

so will this method work for write? and is it working for read?

0 Kudos

1,349 Views
lwn
Contributor II

well, you could just use your CPU's DMA engine to do a mem2mem transfer that copies a block of memory between the pcie device BAR0 and system memory. This way your pcie device doesn't need to support DMA by itself.

1,349 Views
rainerboschung
Contributor II

Thanks for your answer! Sounds promising.

Does this also work for other than BAR0?

Could you point me to some example code?

0 Kudos

1,349 Views
lwn
Contributor II

the pcie registers you want to DMA need to be "memory mapped", so any mapped BAR will do

example code depends on your OS -> google it, you are certainly not the first one to do that

0 Kudos