Hi Siddharth, There is an existing CopyEngine in gem5 (src/dev/pci/copy_engine.cc) which might be similar (and helpful) to what you are trying to do.
-Ayaz On Thu, Feb 2, 2023 at 2:37 AM Siddharth Sahay via gem5-users < gem5-users@gem5.org> wrote: > Hi! > What would be the best strategy for creating a DMA engine for SE mode? > Does something like this already exist? I'd like to be able to write > something like this in the code being simulated (with dma_copy() > implemented in a library that I'd also write) > > dma_copy(src_addr, target_addr, size); > > and have the DMA device "eventually" copy over the required data without > the CPU doing anything else about it. It is fine for our uses for the CPU > to poll a memory location to check for DMA completion. > > I was considering developing a custom dcache that would interpret a > certain address range as controlling DMA operations, so it would flush the > dcache and send memory requests for DMA operation when the CPU issues a > store with the source, target, and size to pre-configured locations in the > special address range. I don't really need it to resemble how real DMA > devices work with OS integration, interrupts, iommu etc. However, if there > is a guide somewhere on how to use the existing DmaDevice with FS mode, > that would also be of great help (I wasn't able to find one). > > Thanks! > Siddharth > _______________________________________________ > gem5-users mailing list -- gem5-users@gem5.org > To unsubscribe send an email to gem5-users-le...@gem5.org >
_______________________________________________ gem5-users mailing list -- gem5-users@gem5.org To unsubscribe send an email to gem5-users-le...@gem5.org