On Thu, 29 Oct 2020 at 14:59, Shaked Matzner <shake...@neuroblade.ai> wrote:
> however the value I get is still 255(0xff) and not 18(0x12) probably I've 
> missed something but when the interrupt is called the transfer to the RAM 
> address should be completed, however it seems like the dma_write_buffer 
> function from the device does not perform any transfer. What Am I missing?

The usual mistake is forgetting in the guest code to program the
PCI device to enable bus mastering by setting the Bus Master bit
in the Command register in the PCI config space registers for
the device. Unless you do that then all DMA attempts will fail
(same as on real h/w). In the Linux kernel the function for this
is pci_set_master(), I think.

thanks
-- PMM

Reply via email to