tenstorrent / tt-umd

User-Mode Driver for Tenstorrent hardware
Apache License 2.0
9 stars 6 forks source link

Add support for DMA mapping API #256

Open joelsmithTT opened 3 weeks ago

joelsmithTT commented 3 weeks ago

In UMD PCIDevice code, add an API for mapping memory for DMA through the IOMMU.

uint64_t map_for_dma(void *buffer, size_t size); // returns DMA addr

KMD supports this in 1.29, so a version check in UMD is a good idea. UMD can determine whether the card is behind IOMMU, so check that too.

pjanevskiTT commented 3 weeks ago

Related to #257 and #133