mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-12-16 22:16:46 +07:00
d9c3d6ff22
The Intel Volume Management Device (VMD) is a PCIe endpoint that acts as a host bridge to another PCI domain. When devices below the VMD perform DMA, the VMD replaces their DMA source IDs with its own source ID. Therefore, those devices require special DMA ops. Add interfaces to allow the VMD driver to set up dma_ops for the devices below it. [bhelgaas: remove "extern", add "static", changelog] Signed-off-by: Keith Busch <keith.busch@intel.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
27 lines
590 B
C
27 lines
590 B
C
#ifndef _ASM_X86_DEVICE_H
|
|
#define _ASM_X86_DEVICE_H
|
|
|
|
struct dev_archdata {
|
|
#ifdef CONFIG_X86_DEV_DMA_OPS
|
|
struct dma_map_ops *dma_ops;
|
|
#endif
|
|
#if defined(CONFIG_INTEL_IOMMU) || defined(CONFIG_AMD_IOMMU)
|
|
void *iommu; /* hook for IOMMU specific extension */
|
|
#endif
|
|
};
|
|
|
|
#if defined(CONFIG_X86_DEV_DMA_OPS) && defined(CONFIG_PCI_DOMAINS)
|
|
struct dma_domain {
|
|
struct list_head node;
|
|
struct dma_map_ops *dma_ops;
|
|
int domain_nr;
|
|
};
|
|
void add_dma_domain(struct dma_domain *domain);
|
|
void del_dma_domain(struct dma_domain *domain);
|
|
#endif
|
|
|
|
struct pdev_archdata {
|
|
};
|
|
|
|
#endif /* _ASM_X86_DEVICE_H */
|