mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-12-17 10:59:01 +07:00
5657933dbb
Some but not all architectures provide set_dma_ops(). Move dma_ops from struct dev_archdata into struct device such that it becomes possible on all architectures to configure dma_ops per device. Signed-off-by: Bart Van Assche <bart.vanassche@sandisk.com> Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: Boris Ostrovsky <boris.ostrovsky@oracle.com> Cc: David Woodhouse <dwmw2@infradead.org> Cc: Juergen Gross <jgross@suse.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Ingo Molnar <mingo@redhat.com> Cc: linux-arch@vger.kernel.org Cc: linux-kernel@vger.kernel.org Cc: Russell King <linux@armlinux.org.uk> Cc: x86@kernel.org Signed-off-by: Doug Ledford <dledford@redhat.com>
37 lines
665 B
C
37 lines
665 B
C
/*
|
|
* Arch specific extensions to struct device
|
|
*
|
|
* This file is released under the GPLv2
|
|
*/
|
|
#ifndef ASMARM_DEVICE_H
|
|
#define ASMARM_DEVICE_H
|
|
|
|
struct dev_archdata {
|
|
#ifdef CONFIG_DMABOUNCE
|
|
struct dmabounce_device_info *dmabounce;
|
|
#endif
|
|
#ifdef CONFIG_IOMMU_API
|
|
void *iommu; /* private IOMMU data */
|
|
#endif
|
|
#ifdef CONFIG_ARM_DMA_USE_IOMMU
|
|
struct dma_iommu_mapping *mapping;
|
|
#endif
|
|
bool dma_coherent;
|
|
};
|
|
|
|
struct omap_device;
|
|
|
|
struct pdev_archdata {
|
|
#ifdef CONFIG_ARCH_OMAP
|
|
struct omap_device *od;
|
|
#endif
|
|
};
|
|
|
|
#ifdef CONFIG_ARM_DMA_USE_IOMMU
|
|
#define to_dma_iommu_mapping(dev) ((dev)->archdata.mapping)
|
|
#else
|
|
#define to_dma_iommu_mapping(dev) NULL
|
|
#endif
|
|
|
|
#endif
|