/drivers/dca/ |
D | dca-core.c | 60 struct dca_domain *domain; in dca_allocate_domain() local 62 domain = kzalloc(sizeof(*domain), GFP_NOWAIT); in dca_allocate_domain() 63 if (!domain) in dca_allocate_domain() 66 INIT_LIST_HEAD(&domain->dca_providers); in dca_allocate_domain() 67 domain->pci_rc = rc; in dca_allocate_domain() 69 return domain; in dca_allocate_domain() 72 static void dca_free_domain(struct dca_domain *domain) in dca_free_domain() argument 74 list_del(&domain->node); in dca_free_domain() 75 kfree(domain); in dca_free_domain() 97 struct dca_domain *domain; in unregister_dca_providers() local [all …]
|
/drivers/iommu/ |
D | amd_iommu.c | 98 struct protection_domain *domain; /* Domain the device is bound to */ member 120 static void update_domain(struct protection_domain *domain); 1165 static void __domain_flush_pages(struct protection_domain *domain, in __domain_flush_pages() argument 1172 build_inv_iommu_pages(&cmd, address, size, domain->id, pde); in __domain_flush_pages() 1175 if (!domain->dev_iommu[i]) in __domain_flush_pages() 1185 list_for_each_entry(dev_data, &domain->dev_list, list) { in __domain_flush_pages() 1196 static void domain_flush_pages(struct protection_domain *domain, in domain_flush_pages() argument 1199 __domain_flush_pages(domain, address, size, 0); in domain_flush_pages() 1203 static void domain_flush_tlb(struct protection_domain *domain) in domain_flush_tlb() argument 1205 __domain_flush_pages(domain, 0, CMD_INV_IOMMU_ALL_PAGES_ADDRESS, 0); in domain_flush_tlb() [all …]
|
D | ipmmu-vmsa.c | 234 static u32 ipmmu_ctx_read(struct ipmmu_vmsa_domain *domain, unsigned int reg) in ipmmu_ctx_read() argument 236 return ipmmu_read(domain->mmu, domain->context_id * IM_CTX_SIZE + reg); in ipmmu_ctx_read() 239 static void ipmmu_ctx_write(struct ipmmu_vmsa_domain *domain, unsigned int reg, in ipmmu_ctx_write() argument 242 ipmmu_write(domain->mmu, domain->context_id * IM_CTX_SIZE + reg, data); in ipmmu_ctx_write() 250 static void ipmmu_tlb_sync(struct ipmmu_vmsa_domain *domain) in ipmmu_tlb_sync() argument 254 while (ipmmu_ctx_read(domain, IMCTR) & IMCTR_FLUSH) { in ipmmu_tlb_sync() 257 dev_err_ratelimited(domain->mmu->dev, in ipmmu_tlb_sync() 265 static void ipmmu_tlb_invalidate(struct ipmmu_vmsa_domain *domain) in ipmmu_tlb_invalidate() argument 269 reg = ipmmu_ctx_read(domain, IMCTR); in ipmmu_tlb_invalidate() 271 ipmmu_ctx_write(domain, IMCTR, reg); in ipmmu_tlb_invalidate() [all …]
|
D | intel-iommu.c | 374 struct dmar_domain *domain; /* pointer to domain */ member 408 struct dmar_domain *domain[HIGH_WATER_MARK]; member 423 static void domain_exit(struct dmar_domain *domain); 424 static void domain_remove_dev_info(struct dmar_domain *domain); 425 static void domain_remove_one_dev_info(struct dmar_domain *domain, 429 static int domain_detach_iommu(struct dmar_domain *domain, 542 static inline int domain_type_is_vm(struct dmar_domain *domain) in domain_type_is_vm() argument 544 return domain->flags & DOMAIN_FLAG_VIRTUAL_MACHINE; in domain_type_is_vm() 547 static inline int domain_type_is_vm_or_si(struct dmar_domain *domain) in domain_type_is_vm_or_si() argument 549 return domain->flags & (DOMAIN_FLAG_VIRTUAL_MACHINE | in domain_type_is_vm_or_si() [all …]
|
D | iommu.c | 876 void iommu_set_fault_handler(struct iommu_domain *domain, in iommu_set_fault_handler() argument 880 BUG_ON(!domain); in iommu_set_fault_handler() 882 domain->handler = handler; in iommu_set_fault_handler() 883 domain->handler_token = token; in iommu_set_fault_handler() 889 struct iommu_domain *domain; in iommu_domain_alloc() local 895 domain = kzalloc(sizeof(*domain), GFP_KERNEL); in iommu_domain_alloc() 896 if (!domain) in iommu_domain_alloc() 899 domain->ops = bus->iommu_ops; in iommu_domain_alloc() 901 ret = domain->ops->domain_init(domain); in iommu_domain_alloc() 905 return domain; in iommu_domain_alloc() [all …]
|
D | fsl_pamu_domain.c | 319 struct fsl_dma_domain *domain; in iommu_alloc_dma_domain() local 321 domain = kmem_cache_zalloc(fsl_pamu_domain_cache, GFP_KERNEL); in iommu_alloc_dma_domain() 322 if (!domain) in iommu_alloc_dma_domain() 325 domain->stash_id = ~(u32)0; in iommu_alloc_dma_domain() 326 domain->snoop_id = ~(u32)0; in iommu_alloc_dma_domain() 327 domain->win_cnt = pamu_get_max_subwin_cnt(); in iommu_alloc_dma_domain() 328 domain->geom_size = 0; in iommu_alloc_dma_domain() 330 INIT_LIST_HEAD(&domain->devices); in iommu_alloc_dma_domain() 332 spin_lock_init(&domain->domain_lock); in iommu_alloc_dma_domain() 334 return domain; in iommu_alloc_dma_domain() [all …]
|
D | tegra-gart.c | 156 static int gart_iommu_attach_dev(struct iommu_domain *domain, in gart_iommu_attach_dev() argument 166 domain->priv = gart; in gart_iommu_attach_dev() 168 domain->geometry.aperture_start = gart->iovmm_base; in gart_iommu_attach_dev() 169 domain->geometry.aperture_end = gart->iovmm_base + in gart_iommu_attach_dev() 171 domain->geometry.force_aperture = true; in gart_iommu_attach_dev() 198 static void gart_iommu_detach_dev(struct iommu_domain *domain, in gart_iommu_detach_dev() argument 201 struct gart_device *gart = domain->priv; in gart_iommu_detach_dev() 219 static int gart_iommu_domain_init(struct iommu_domain *domain) in gart_iommu_domain_init() argument 224 static void gart_iommu_domain_destroy(struct iommu_domain *domain) in gart_iommu_domain_destroy() argument 226 struct gart_device *gart = domain->priv; in gart_iommu_domain_destroy() [all …]
|
D | msm_iommu.c | 81 static int __flush_iotlb(struct iommu_domain *domain) in __flush_iotlb() argument 83 struct msm_priv *priv = domain->priv; in __flush_iotlb() 213 static int msm_iommu_domain_init(struct iommu_domain *domain) in msm_iommu_domain_init() argument 228 domain->priv = priv; in msm_iommu_domain_init() 230 domain->geometry.aperture_start = 0; in msm_iommu_domain_init() 231 domain->geometry.aperture_end = (1ULL << 32) - 1; in msm_iommu_domain_init() 232 domain->geometry.force_aperture = true; in msm_iommu_domain_init() 241 static void msm_iommu_domain_destroy(struct iommu_domain *domain) in msm_iommu_domain_destroy() argument 249 priv = domain->priv; in msm_iommu_domain_destroy() 250 domain->priv = NULL; in msm_iommu_domain_destroy() [all …]
|
D | shmobile-iommu.c | 85 static int shmobile_iommu_domain_init(struct iommu_domain *domain) in shmobile_iommu_domain_init() argument 103 domain->priv = sh_domain; in shmobile_iommu_domain_init() 107 static void shmobile_iommu_domain_destroy(struct iommu_domain *domain) in shmobile_iommu_domain_destroy() argument 109 struct shmobile_iommu_domain *sh_domain = domain->priv; in shmobile_iommu_domain_destroy() 118 domain->priv = NULL; in shmobile_iommu_domain_destroy() 121 static int shmobile_iommu_attach_device(struct iommu_domain *domain, in shmobile_iommu_attach_device() argument 125 struct shmobile_iommu_domain *sh_domain = domain->priv; in shmobile_iommu_attach_device() 150 static void shmobile_iommu_detach_device(struct iommu_domain *domain, in shmobile_iommu_detach_device() argument 154 struct shmobile_iommu_domain *sh_domain = domain->priv; in shmobile_iommu_detach_device() 213 static int shmobile_iommu_map(struct iommu_domain *domain, unsigned long iova, in shmobile_iommu_map() argument [all …]
|
/drivers/vfio/ |
D | vfio_iommu_type1.c | 65 struct iommu_domain *domain; member 334 struct vfio_domain *domain, *d; in vfio_unmap_unpin() local 346 domain = d = list_first_entry(&iommu->domain_list, in vfio_unmap_unpin() 350 iommu_unmap(d->domain, dma->iova, dma->size); in vfio_unmap_unpin() 356 phys = iommu_iova_to_phys(domain->domain, iova); in vfio_unmap_unpin() 362 unmapped = iommu_unmap(domain->domain, iova, PAGE_SIZE); in vfio_unmap_unpin() 384 struct vfio_domain *domain; in vfio_pgsize_bitmap() local 388 list_for_each_entry(domain, &iommu->domain_list, next) in vfio_pgsize_bitmap() 389 bitmap &= domain->domain->ops->pgsize_bitmap; in vfio_pgsize_bitmap() 480 static int map_try_harder(struct vfio_domain *domain, dma_addr_t iova, in map_try_harder() argument [all …]
|
/drivers/irqchip/ |
D | irq-atmel-aic5.c | 89 struct irq_domain *domain = d->domain; in aic5_mask() local 90 struct irq_domain_chip_generic *dgc = domain->gc; in aic5_mask() 103 struct irq_domain *domain = d->domain; in aic5_unmask() local 104 struct irq_domain_chip_generic *dgc = domain->gc; in aic5_unmask() 117 struct irq_domain *domain = d->domain; in aic5_retrigger() local 118 struct irq_domain_chip_generic *dgc = domain->gc; in aic5_retrigger() 132 struct irq_domain *domain = d->domain; in aic5_set_type() local 133 struct irq_domain_chip_generic *dgc = domain->gc; in aic5_set_type() 152 struct irq_domain *domain = d->domain; in aic5_suspend() local 153 struct irq_domain_chip_generic *dgc = domain->gc; in aic5_suspend() [all …]
|
D | irq-mmp.c | 49 struct irq_domain *domain; member 66 struct irq_domain *domain = d->domain; in icu_mask_ack_irq() local 67 struct icu_chip_data *data = (struct icu_chip_data *)domain->host_data; in icu_mask_ack_irq() 90 struct irq_domain *domain = d->domain; in icu_mask_irq() local 91 struct icu_chip_data *data = (struct icu_chip_data *)domain->host_data; in icu_mask_irq() 109 struct irq_domain *domain = d->domain; in icu_unmask_irq() local 110 struct icu_chip_data *data = (struct icu_chip_data *)domain->host_data; in icu_unmask_irq() 135 struct irq_domain *domain; in icu_mux_irq_demux() local 142 domain = icu_data[i].domain; in icu_mux_irq_demux() 143 data = (struct icu_chip_data *)domain->host_data; in icu_mux_irq_demux() [all …]
|
D | irq-atmel-aic-common.c | 115 static void __init aic_common_ext_irq_of_init(struct irq_domain *domain) in aic_common_ext_irq_of_init() argument 117 struct device_node *node = domain->of_node; in aic_common_ext_irq_of_init() 124 gc = irq_get_domain_generic_chip(domain, 0); in aic_common_ext_irq_of_init() 130 gc = irq_get_domain_generic_chip(domain, hwirq); in aic_common_ext_irq_of_init() 133 hwirq, domain->revmap_size); in aic_common_ext_irq_of_init() 193 struct irq_domain *domain; in aic_common_of_init() local 212 domain = irq_domain_add_linear(node, nchips * 32, ops, aic); in aic_common_of_init() 213 if (!domain) { in aic_common_of_init() 218 ret = irq_alloc_domain_generic_chips(domain, 32, 1, name, in aic_common_of_init() 226 gc = irq_get_domain_generic_chip(domain, i * 32); in aic_common_of_init() [all …]
|
D | irq-moxart.c | 41 struct irq_domain *domain; member 56 handle_IRQ(irq_linear_revmap(intc.domain, hwirq), regs); in handle_irq() 75 intc.domain = irq_domain_add_linear(node, 32, &irq_generic_chip_ops, in moxart_of_intc_init() 77 if (!intc.domain) { in moxart_of_intc_init() 82 ret = irq_alloc_domain_generic_chips(intc.domain, 32, 1, in moxart_of_intc_init() 88 irq_domain_remove(intc.domain); in moxart_of_intc_init() 98 gc = irq_get_domain_generic_chip(intc.domain, 0); in moxart_of_intc_init()
|
D | irq-tb10x.c | 102 struct irq_domain *domain = irq_desc_get_handler_data(desc); in tb10x_irq_cascade() local 104 generic_handle_irq(irq_find_mapping(domain, irq)); in tb10x_irq_cascade() 113 struct irq_domain *domain; in of_tb10x_init_irq() local 135 domain = irq_domain_add_linear(ictl, AB_IRQCTL_MAXIRQ, in of_tb10x_init_irq() 137 if (!domain) { in of_tb10x_init_irq() 144 ret = irq_alloc_domain_generic_chips(domain, AB_IRQCTL_MAXIRQ, in of_tb10x_init_irq() 154 gc = domain->gc->gc[0]; in of_tb10x_init_irq() 176 irq_set_handler_data(irq, domain); in of_tb10x_init_irq() 188 irq_domain_remove(domain); in of_tb10x_init_irq()
|
/drivers/gpu/drm/msm/ |
D | msm_iommu.c | 23 struct iommu_domain *domain; member 37 return iommu_attach_device(iommu->domain, mmu->dev); in msm_iommu_attach() 43 iommu_detach_device(iommu->domain, mmu->dev); in msm_iommu_detach() 50 struct iommu_domain *domain = iommu->domain; in msm_iommu_map() local 56 if (!domain || !sgt) in msm_iommu_map() 65 ret = iommu_map(domain, da, pa, bytes, prot); in msm_iommu_map() 79 iommu_unmap(domain, da, bytes); in msm_iommu_map() 89 struct iommu_domain *domain = iommu->domain; in msm_iommu_unmap() local 98 unmapped = iommu_unmap(domain, da, bytes); in msm_iommu_unmap() 115 iommu_domain_free(iommu->domain); in msm_iommu_destroy() [all …]
|
/drivers/gpu/drm/nouveau/core/engine/device/ |
D | ctrl.c | 77 struct nouveau_clocks *domain; in nouveau_control_mthd_pstate_attr() local 97 domain = clk->domains; in nouveau_control_mthd_pstate_attr() 99 while (domain->name != nv_clk_src_max) { in nouveau_control_mthd_pstate_attr() 100 if (domain->mname && ++j == args->v0.index) in nouveau_control_mthd_pstate_attr() 102 domain++; in nouveau_control_mthd_pstate_attr() 105 if (domain->name == nv_clk_src_max) in nouveau_control_mthd_pstate_attr() 114 lo = pstate->base.domain[domain->name]; in nouveau_control_mthd_pstate_attr() 117 lo = min(lo, cstate->domain[domain->name]); in nouveau_control_mthd_pstate_attr() 118 hi = max(hi, cstate->domain[domain->name]); in nouveau_control_mthd_pstate_attr() 123 lo = max(clk->read(clk, domain->name), 0); in nouveau_control_mthd_pstate_attr() [all …]
|
/drivers/base/ |
D | map.c | 32 int kobj_map(struct kobj_map *domain, dev_t dev, unsigned long range, in kobj_map() argument 57 mutex_lock(domain->lock); in kobj_map() 59 struct probe **s = &domain->probes[index % 255]; in kobj_map() 65 mutex_unlock(domain->lock); in kobj_map() 69 void kobj_unmap(struct kobj_map *domain, dev_t dev, unsigned long range) in kobj_unmap() argument 79 mutex_lock(domain->lock); in kobj_unmap() 82 for (s = &domain->probes[index % 255]; *s; s = &(*s)->next) { in kobj_unmap() 92 mutex_unlock(domain->lock); in kobj_unmap() 96 struct kobject *kobj_lookup(struct kobj_map *domain, dev_t dev, int *index) in kobj_lookup() argument 103 mutex_lock(domain->lock); in kobj_lookup() [all …]
|
/drivers/xen/xen-pciback/ |
D | pci_stub.c | 38 int domain; member 152 static struct pcistub_device *pcistub_device_find(int domain, int bus, in pcistub_device_find() argument 162 && domain == pci_domain_nr(psdev->dev->bus) in pcistub_device_find() 201 int domain, int bus, in pcistub_get_pci_dev_by_slot() argument 212 && domain == pci_domain_nr(psdev->dev->bus) in pcistub_get_pci_dev_by_slot() 310 if (pci_domain_nr(dev->bus) == pdev_id->domain in pcistub_match_one() 641 &aer_op->domain, &aer_op->bus, &aer_op->devfn); in common_process() 651 aer_cmd, aer_op->domain, aer_op->bus, aer_op->devfn); in common_process() 939 static inline int str_to_slot(const char *buf, int *domain, int *bus, in str_to_slot() argument 944 switch (sscanf(buf, " %x:%x:%x.%x %n", domain, bus, slot, func, in str_to_slot() [all …]
|
D | passthrough.c | 20 unsigned int domain, in __xen_pcibk_get_pci_dev() argument 31 if (domain == (unsigned int)pci_domain_nr(dev_entry->dev->bus) in __xen_pcibk_get_pci_dev() 50 unsigned int domain, bus, devfn; in __xen_pcibk_add_pci_dev() local 63 domain = (unsigned int)pci_domain_nr(dev->bus); in __xen_pcibk_add_pci_dev() 66 err = publish_cb(pdev, domain, bus, devfn, devid); in __xen_pcibk_add_pci_dev() 119 unsigned int domain, bus; in __xen_pcibk_publish_pci_roots() local 138 domain = (unsigned int)pci_domain_nr(dev_entry->dev->bus); in __xen_pcibk_publish_pci_roots() 142 err = publish_root_cb(pdev, domain, bus); in __xen_pcibk_publish_pci_roots() 170 unsigned int *domain, unsigned int *bus, in __xen_pcibk_get_pcifront_dev() argument 173 *domain = pci_domain_nr(pcidev->bus); in __xen_pcibk_get_pcifront_dev()
|
D | xenbus.c | 202 unsigned int domain, unsigned int bus, in xen_pcibk_publish_pci_dev() argument 217 "%04x:%02x:%02x.%02x", domain, bus, in xen_pcibk_publish_pci_dev() 225 int domain, int bus, int slot, int func, in xen_pcibk_export_device() argument 232 domain, bus, slot, func); in xen_pcibk_export_device() 234 dev = pcistub_get_pci_dev_by_slot(pdev, domain, bus, slot, func); in xen_pcibk_export_device() 241 domain, bus, slot, func); in xen_pcibk_export_device() 272 int domain, int bus, int slot, int func) in xen_pcibk_remove_device() argument 278 domain, bus, slot, func); in xen_pcibk_remove_device() 280 dev = xen_pcibk_get_pci_dev(pdev, domain, bus, PCI_DEVFN(slot, func)); in xen_pcibk_remove_device() 285 domain, bus, slot, func); in xen_pcibk_remove_device() [all …]
|
D | pciback.h | 64 int domain, int bus, 86 unsigned int domain, unsigned int bus, 89 unsigned int domain, unsigned int bus); 100 unsigned int *domain, unsigned int *bus, 107 unsigned int domain, unsigned int bus, 133 xen_pcibk_get_pci_dev(struct xen_pcibk_device *pdev, unsigned int domain, in xen_pcibk_get_pci_dev() argument 137 return xen_pcibk_backend->get(pdev, domain, bus, devfn); in xen_pcibk_get_pci_dev() 149 unsigned int *domain, in xen_pcibk_get_pcifront_dev() argument 154 return xen_pcibk_backend->find(pcidev, pdev, domain, bus, in xen_pcibk_get_pcifront_dev()
|
/drivers/gpu/drm/nouveau/core/subdev/clock/ |
D | base.c | 42 u8 pstate, u8 domain, u32 input) in nouveau_clock_adjust() argument 62 if (subd && boostS.domain == domain) { in nouveau_clock_adjust() 142 struct nouveau_clocks *domain = clk->domains; in nouveau_cstate_new() local 159 while (domain && domain->name != nv_clk_src_max) { in nouveau_cstate_new() 160 if (domain->flags & NVKM_CLK_DOM_FLAG_CORE) { in nouveau_cstate_new() 163 domain->bios, in nouveau_cstate_new() 165 cstate->domain[domain->name] = freq; in nouveau_cstate_new() 167 domain++; in nouveau_cstate_new() 193 int khz = pstate->base.domain[nv_clk_src_mem]; in nouveau_pstate_prog() 264 u32 lo = pstate->base.domain[clock->name]; in nouveau_pstate_info() [all …]
|
/drivers/pci/pcie/aer/ |
D | aer_inject.c | 44 u16 domain; member 49 u16 domain; member 77 static void aer_error_init(struct aer_error *err, u16 domain, in aer_error_init() argument 82 err->domain = domain; in aer_error_init() 89 static struct aer_error *__find_aer_error(u16 domain, unsigned int bus, in __find_aer_error() argument 95 if (domain == err->domain && in __find_aer_error() 106 int domain = pci_domain_nr(dev->bus); in __find_aer_error_by_dev() local 107 if (domain < 0) in __find_aer_error_by_dev() 109 return __find_aer_error((u16)domain, dev->bus->number, dev->devfn); in __find_aer_error_by_dev() 191 int domain; in pci_read_aer() local [all …]
|
/drivers/pci/ |
D | xen-pcifront.c | 66 unsigned int domain, unsigned int bus, in pcifront_init_sd() argument 71 sd->sd.domain = domain; in pcifront_init_sd() 185 .domain = pci_domain_nr(bus), in pcifront_bus_read() 223 .domain = pci_domain_nr(bus), in pcifront_bus_write() 256 .domain = pci_domain_nr(dev->bus), in pci_frontend_enable_msix() 310 .domain = pci_domain_nr(dev->bus), in pci_frontend_disable_msix() 329 .domain = pci_domain_nr(dev->bus), in pci_frontend_enable_msi() 358 .domain = pci_domain_nr(dev->bus), in pci_frontend_disable_msi() 419 unsigned int domain, unsigned int bus, in pcifront_scan_bus() argument 440 "%04x:%02x:%02x.%d found.\n", domain, bus, in pcifront_scan_bus() [all …]
|