From 38a54bd3b1c083b0904555dacf641615370ba172 Mon Sep 17 00:00:00 2001 From: Michael Brown Date: Wed, 4 Nov 2020 15:23:14 +0000 Subject: [efi] Provide DMA operations for EFI PCI devices Signed-off-by: Michael Brown --- src/include/ipxe/dma.h | 2 ++ src/include/ipxe/pci.h | 3 +++ 2 files changed, 5 insertions(+) (limited to 'src/include/ipxe') diff --git a/src/include/ipxe/dma.h b/src/include/ipxe/dma.h index d3db061f7..878e03f11 100644 --- a/src/include/ipxe/dma.h +++ b/src/include/ipxe/dma.h @@ -32,6 +32,8 @@ FILE_LICENCE ( GPL2_OR_LATER_OR_UBDL ); struct dma_mapping { /** Device-side address */ physaddr_t addr; + /** Platform mapping token */ + void *token; }; /** A DMA-capable device */ diff --git a/src/include/ipxe/pci.h b/src/include/ipxe/pci.h index 272c4c06f..6632c574d 100644 --- a/src/include/ipxe/pci.h +++ b/src/include/ipxe/pci.h @@ -12,6 +12,7 @@ FILE_LICENCE ( GPL2_OR_LATER_OR_UBDL ); #include #include #include +#include #include /** PCI vendor ID */ @@ -187,6 +188,8 @@ struct pci_class_id { struct pci_device { /** Generic device */ struct device dev; + /** DMA device */ + struct dma_device dma; /** Memory base * * This is the physical address of the first valid memory BAR. -- cgit v1.2.3-55-g7522