| /kernel/linux/linux-6.6/drivers/xen/ |
| D | grant-dma-ops.c | 1 // SPDX-License-Identifier: GPL-2.0-only 3 * Xen grant DMA-mapping layer - contains special DMA-mapping routines 4 * for providing grant references as DMA addresses to be used by frontends 11 #include <linux/dma-map-ops.h> 19 #include <xen/xen-ops.h> 33 static inline dma_addr_t grant_to_dma(grant_ref_t grant) in grant_to_dma() argument 35 return XEN_GRANT_DMA_ADDR_OFF | ((dma_addr_t)grant << XEN_PAGE_SHIFT); in grant_to_dma() 38 static inline grant_ref_t dma_to_grant(dma_addr_t dma) in dma_to_grant() argument 40 return (grant_ref_t)((dma & ~XEN_GRANT_DMA_ADDR_OFF) >> XEN_PAGE_SHIFT); in dma_to_grant() 70 * DMA ops for Xen frontends (e.g. virtio). [all …]
|
| D | Kconfig | 1 # SPDX-License-Identifier: GPL-2.0-only 32 2) control domain: xl mem-max <target-domain> <maxmem> 35 3) control domain: xl mem-set <target-domain> <memory> 51 …SUBSYSTEM=="memory", ACTION=="add", RUN+="/bin/sh -c '[ -f /sys$devpath/state ] && echo online > /… 137 tristate "userspace grant access device driver" 145 bool "Add support for dma-buf grant access device driver extension" 150 dma-buf implementation. With this extension grant references to 151 the pages of an imported dma-buf can be exported for other domain 152 use and grant references coming from a foreign domain can be 153 converted into a local dma-buf for local export. [all …]
|
| D | grant-dma-iommu.c | 1 // SPDX-License-Identifier: GPL-2.0 5 * bindings by Xen grant DMA-mapping layer. 21 return ERR_PTR(-ENODEV); in grant_dma_iommu_probe_device() 30 { .compatible = "xen,grant-dma" }, 39 mmu = devm_kzalloc(&pdev->dev, sizeof(*mmu), GFP_KERNEL); in grant_dma_iommu_probe() 41 return -ENOMEM; in grant_dma_iommu_probe() 43 mmu->dev = &pdev->dev; in grant_dma_iommu_probe() 45 ret = iommu_device_register(&mmu->iommu, &grant_dma_iommu_ops, &pdev->dev); in grant_dma_iommu_probe() 59 iommu_device_unregister(&mmu->iommu); in grant_dma_iommu_remove() 66 .name = "grant-dma-iommu",
|
| D | Makefile | 1 # SPDX-License-Identifier: GPL-2.0 2 obj-$(CONFIG_HOTPLUG_CPU) += cpu_hotplug.o 3 obj-y += grant-table.o features.o balloon.o manage.o time.o 4 obj-y += mem-reservation.o 5 obj-y += events/ 6 obj-y += xenbus/ 8 CFLAGS_features.o := -fno-stack-protector 10 dom0-$(CONFIG_ARM64) += arm-device.o 11 dom0-$(CONFIG_PCI) += pci.o 12 dom0-$(CONFIG_USB_SUPPORT) += dbgp.o [all …]
|
| D | grant-table.c | 6 * Copyright (c) 2005-2006, Christopher Clark 7 * Copyright (c) 2004-2005, K A Fraser 50 #include <linux/dma-mapping.h> 58 #include <xen/hvc-console.h> 59 #include <xen/swiotlb-xen.h> 64 #include <xen/mem-reservation.h> 79 * linked by grant ref, the last element contains GNTTAB_LIST_END. The number 110 /*This is a structure of function pointers for grant table*/ 113 * Version of the grant interface. 117 * Grant refs per grant frame. [all …]
|
| D | gntdev-common.h | 1 /* SPDX-License-Identifier: GPL-2.0 */ 4 * Common functionality of grant device. 6 * Copyright (c) 2006-2007, D G Murray. 30 /* Device for which DMA memory is allocated. */ 67 * If dmabuf_vaddr is not NULL then this mapping is backed by DMA 72 /* Flags used to create this DMA buffer: GNTDEV_DMA_FLAG_XXX. */
|
| D | gntdev-dmabuf.c | 1 // SPDX-License-Identifier: GPL-2.0 4 * Xen dma-buf functionality for gntdev. 6 * DMA buffer implementation is based on drivers/gpu/drm/drm_prime.c. 13 #include <linux/dma-buf.h> 14 #include <linux/dma-direct.h> 23 #include "gntdev-common.h" 24 #include "gntdev-dmabuf.h" 45 /* Scatter-gather table of the imported buffer. */ 47 /* dma-buf attachment of the imported buffer. */ 54 /* Pages of this buffer (only for dma-buf export). */ [all …]
|
| /kernel/linux/linux-5.10/include/uapi/xen/ |
| D | gntdev.h | 1 /* SPDX-License-Identifier: ((GPL-2.0 WITH Linux-syscall-note) OR MIT) */ 41 /* The domain ID of the grant to be mapped. */ 43 /* The grant reference of the grant to be mapped. */ 48 * Inserts the grant references into the mapping table of an instance 63 /* Array of grant references, of size @count. */ 68 * Removes the grant references from the mapping table of an instance of 93 * contiguously-allocated range at once, and not any subrange thereof. 125 * cleanup if this side crashes. Required to implement cross-domain robust 165 * Copy between grant references and local buffers. 168 * to/from one grant reference. [all …]
|
| /kernel/linux/linux-6.6/include/uapi/xen/ |
| D | gntdev.h | 1 /* SPDX-License-Identifier: ((GPL-2.0 WITH Linux-syscall-note) OR MIT) */ 41 /* The domain ID of the grant to be mapped. */ 43 /* The grant reference of the grant to be mapped. */ 48 * Inserts the grant references into the mapping table of an instance 51 * considered opaque to userspace, with one exception: if no grant 69 /* Array of grant references, of size @count. */ 74 * Removes the grant references from the mapping table of an instance of 99 * contiguously-allocated range at once, and not any subrange thereof. 131 * cleanup if this side crashes. Required to implement cross-domain robust 171 * Copy between grant references and local buffers. [all …]
|
| /kernel/linux/linux-6.6/Documentation/devicetree/bindings/iommu/ |
| D | xen,grant-dma.yaml | 1 # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) 3 --- 4 $id: http://devicetree.org/schemas/iommu/xen,grant-dma.yaml# 5 $schema: http://devicetree.org/meta-schemas/core.yaml# 10 - Stefano Stabellini <sstabellini@kernel.org> 13 The Xen IOMMU represents the Xen grant table interface. Grant mappings 16 The binding is required to restrict memory access using Xen grant mappings. 20 const: xen,grant-dma 22 '#iommu-cells': 29 - compatible [all …]
|
| /kernel/linux/linux-5.10/drivers/xen/ |
| D | Kconfig | 1 # SPDX-License-Identifier: GPL-2.0-only 32 2) control domain: xl mem-max <target-domain> <maxmem> 35 3) control domain: xl mem-set <target-domain> <memory> 51 …SUBSYSTEM=="memory", ACTION=="add", RUN+="/bin/sh -c '[ -f /sys$devpath/state ] && echo online > /… 137 tristate "userspace grant access device driver" 145 bool "Add support for dma-buf grant access device driver extension" 150 dma-buf implementation. With this extension grant references to 151 the pages of an imported dma-buf can be exported for other domain 152 use and grant references coming from a foreign domain can be 153 converted into a local dma-buf for local export. [all …]
|
| D | grant-table.c | 6 * Copyright (c) 2005-2006, Christopher Clark 7 * Copyright (c) 2004-2005, K A Fraser 49 #include <linux/dma-mapping.h> 57 #include <xen/hvc-console.h> 58 #include <xen/swiotlb-xen.h> 63 #include <xen/mem-reservation.h> 69 /* External tools reserve first few grant table entries. */ 88 /*This is a structure of function pointers for grant table*/ 91 * Version of the grant interface. 95 * Grant refs per grant frame. [all …]
|
| D | gntdev-dmabuf.c | 1 // SPDX-License-Identifier: GPL-2.0 4 * Xen dma-buf functionality for gntdev. 6 * DMA buffer implementation is based on drivers/gpu/drm/drm_prime.c. 13 #include <linux/dma-buf.h> 21 #include "gntdev-common.h" 22 #include "gntdev-dmabuf.h" 26 * Note on usage of grant reference 0 as invalid grant reference: 27 * grant reference 0 is valid, but never exposed to a driver, 50 /* Scatter-gather table of the imported buffer. */ 52 /* dma-buf attachment of the imported buffer. */ [all …]
|
| D | gntdev-common.h | 1 /* SPDX-License-Identifier: GPL-2.0 */ 4 * Common functionality of grant device. 6 * Copyright (c) 2006-2007, D G Murray. 30 /* Device for which DMA memory is allocated. */ 67 * If dmabuf_vaddr is not NULL then this mapping is backed by DMA 72 /* Flags used to create this DMA buffer: GNTDEV_DMA_FLAG_XXX. */
|
| /kernel/linux/linux-6.6/include/xen/ |
| D | grant_table.h | 6 * 2. Accessing others' memory reservations via grant references. 7 * (i.e., mechanisms for both sender and recipient of grant references) 9 * Copyright (c) 2004-2005, K A Fraser 50 #include <linux/page-flags.h> 54 * Technically there's no reliably invalid grant reference or grant handle, 57 #define INVALID_GRANT_REF ((grant_ref_t)-1) 58 #define INVALID_GRANT_HANDLE ((grant_handle_t)-1) 94 * End access through the given grant reference, iff the grant entry is no 95 * longer in use. Return 1 if the grant entry was freed, 0 if it is still in 101 * Eventually end access through the given grant reference, and once that [all …]
|
| /kernel/linux/linux-5.10/include/xen/ |
| D | grant_table.h | 6 * 2. Accessing others' memory reservations via grant references. 7 * (i.e., mechanisms for both sender and recipient of grant references) 9 * Copyright (c) 2004-2005, K A Fraser 50 #include <linux/page-flags.h> 89 * End access through the given grant reference, iff the grant entry is no 90 * longer in use. Return 1 if the grant entry was freed, 0 if it is still in 96 * Eventually end access through the given grant reference, and once that 98 * immediately iff the grant entry is not in use, otherwise it will happen 105 * the grant is no longer in use. 114 * End access through the given grant reference, iff the grant entry is [all …]
|
| /kernel/linux/linux-5.10/arch/powerpc/include/asm/ |
| D | dcr-regs.h | 1 /* SPDX-License-Identifier: GPL-2.0 */ 9 * Mostly lifted from asm-ppc/ibm4xx.h by 11 * Copyright (c) 1999 Grant Erickson <grant@lcse.umn.edu> 19 * Most DCRs used for controlling devices such as the MAL, DMA engine, 162 * DCR register offsets for 440SP/440SPe I2O/DMA controller. 167 #define I2O_REG_ENABLE 0x00000001 /* Enable I2O/DMA access */ 171 #define DCRN_SDR0_SRST_I2ODMA (0x80000000 >> 15) /* Reset I2O/DMA */
|
| /kernel/linux/linux-6.6/arch/powerpc/include/asm/ |
| D | dcr-regs.h | 1 /* SPDX-License-Identifier: GPL-2.0 */ 9 * Mostly lifted from asm-ppc/ibm4xx.h by 11 * Copyright (c) 1999 Grant Erickson <grant@lcse.umn.edu> 19 * Most DCRs used for controlling devices such as the MAL, DMA engine, 162 * DCR register offsets for 440SP/440SPe I2O/DMA controller. 167 #define I2O_REG_ENABLE 0x00000001 /* Enable I2O/DMA access */ 171 #define DCRN_SDR0_SRST_I2ODMA (0x80000000 >> 15) /* Reset I2O/DMA */
|
| /kernel/linux/linux-5.10/drivers/parport/ |
| D | parport_gsc.h | 1 /* SPDX-License-Identifier: GPL-2.0-or-later */ 3 * Low-level parallel-support for PC-style hardware integrated in the 4 * LASI-Controller (on GSC-Bus) for HP-PARISC Workstations 6 * (C) 1999-2001 by Helge Deller <deller@gmx.de> 9 * Grant Guenther <grant@torque.net> 43 /* --- register definitions ------------------------------- */ 45 #define EPPDATA(p) ((p)->base + 0x4) 46 #define EPPADDR(p) ((p)->base + 0x3) 47 #define CONTROL(p) ((p)->base + 0x2) 48 #define STATUS(p) ((p)->base + 0x1) [all …]
|
| D | parport_gsc.c | 1 // SPDX-License-Identifier: GPL-2.0-or-later 3 * Low-level parallel-support for PC-style hardware integrated in the 4 * LASI-Controller (on GSC-Bus) for HP-PARISC Workstations 6 * (C) 1999-2001 by Helge Deller <deller@gmx.de> 9 * Grant Guenther <grant@torque.net> 31 #include <asm/dma.h> 37 #include <asm/parisc-device.h> 43 MODULE_DESCRIPTION("HP-PARISC PC-style parallel port driver"); 44 MODULE_SUPPORTED_DEVICE("integrated PC-style parallel port"); 80 s->u.pc.ctr = 0xc | (dev->irq_func ? 0x10 : 0x0); in parport_gsc_init_state() [all …]
|
| D | parport_sunbpp.c | 1 // SPDX-License-Identifier: GPL-2.0-only 2 /* parport_sunbpp.c: Parallel-port routines for SBUS 11 * Grant Guenther <grant@torque.net> 40 #include <asm/dma.h> /* BPP uses LSI 64854 for DMA */ 53 struct bpp_regs __iomem *regs = (struct bpp_regs __iomem *)p->base; in parport_sunbpp_disable_irq() 56 tmp = sbus_readl(®s->p_csr); in parport_sunbpp_disable_irq() 58 sbus_writel(tmp, ®s->p_csr); in parport_sunbpp_disable_irq() 63 struct bpp_regs __iomem *regs = (struct bpp_regs __iomem *)p->base; in parport_sunbpp_enable_irq() 66 tmp = sbus_readl(®s->p_csr); in parport_sunbpp_enable_irq() 68 sbus_writel(tmp, ®s->p_csr); in parport_sunbpp_enable_irq() [all …]
|
| /kernel/linux/linux-6.6/arch/mips/pci/ |
| D | pci-ar2315.c | 1 // SPDX-License-Identifier: GPL-2.0-or-later 6 * Both AR2315 and AR2316 chips have PCI interface unit, which supports DMA 10 * Read/write operation in the region 0x80000000-0xBFFFFFFF causes 18 * Devices on the bus can perform DMA requests via chip BAR1. PCI host 23 * We know (and support) only one board that uses the PCI interface - 34 #include <linux/dma-direct.h> 54 #define AR2315_PCIMISC_GIG_MASK 0x0000000C /* bits 31-30 for pci req */ 59 #define AR2315_PCIGRANT_EN 0x00000000 /* 6:7=0 early grant en */ 60 #define AR2315_PCIGRANT_FRAME 0x00000040 /* 6:7=1 grant waits 4 frame */ 61 #define AR2315_PCIGRANT_IDLE 0x00000080 /* 6:7=2 grant waits 4 idle */ [all …]
|
| /kernel/linux/linux-5.10/arch/mips/pci/ |
| D | pci-ar2315.c | 1 // SPDX-License-Identifier: GPL-2.0-or-later 6 * Both AR2315 and AR2316 chips have PCI interface unit, which supports DMA 10 * Read/write operation in the region 0x80000000-0xBFFFFFFF causes 18 * Devices on the bus can perform DMA requests via chip BAR1. PCI host 23 * We know (and support) only one board that uses the PCI interface - 53 #define AR2315_PCIMISC_GIG_MASK 0x0000000C /* bits 31-30 for pci req */ 58 #define AR2315_PCIGRANT_EN 0x00000000 /* 6:7=0 early grant en */ 59 #define AR2315_PCIGRANT_FRAME 0x00000040 /* 6:7=1 grant waits 4 frame */ 60 #define AR2315_PCIGRANT_IDLE 0x00000080 /* 6:7=2 grant waits 4 idle */ 61 #define AR2315_PCIGRANT_GAP 0x00000000 /* 6:7=2 grant waits 4 idle */ [all …]
|
| /kernel/linux/linux-6.6/drivers/parport/ |
| D | parport_gsc.h | 1 /* SPDX-License-Identifier: GPL-2.0-or-later */ 3 * Low-level parallel-support for PC-style hardware integrated in the 4 * LASI-Controller (on GSC-Bus) for HP-PARISC Workstations 6 * (C) 1999-2001 by Helge Deller <deller@gmx.de> 9 * Grant Guenther <grant@torque.net> 43 /* --- register definitions ------------------------------- */ 45 #define EPPDATA(p) ((p)->base + 0x4) 46 #define EPPADDR(p) ((p)->base + 0x3) 47 #define CONTROL(p) ((p)->base + 0x2) 48 #define STATUS(p) ((p)->base + 0x1) [all …]
|
| D | parport_sunbpp.c | 1 // SPDX-License-Identifier: GPL-2.0-only 2 /* parport_sunbpp.c: Parallel-port routines for SBUS 11 * Grant Guenther <grant@torque.net> 40 #include <asm/dma.h> /* BPP uses LSI 64854 for DMA */ 53 struct bpp_regs __iomem *regs = (struct bpp_regs __iomem *)p->base; in parport_sunbpp_disable_irq() 56 tmp = sbus_readl(®s->p_csr); in parport_sunbpp_disable_irq() 58 sbus_writel(tmp, ®s->p_csr); in parport_sunbpp_disable_irq() 63 struct bpp_regs __iomem *regs = (struct bpp_regs __iomem *)p->base; in parport_sunbpp_enable_irq() 66 tmp = sbus_readl(®s->p_csr); in parport_sunbpp_enable_irq() 68 sbus_writel(tmp, ®s->p_csr); in parport_sunbpp_enable_irq() [all …]
|