Home
last modified time | relevance | path

Searched refs:table_group (Results 1 – 9 of 9) sorted by relevance

/Linux-v6.1/drivers/vfio/
Dvfio_iommu_spapr_tce.c241 struct iommu_table_group *table_group; in tce_iommu_enable() local
281 table_group = iommu_group_get_iommudata(tcegrp->grp); in tce_iommu_enable()
282 if (!table_group) in tce_iommu_enable()
285 if (!table_group->tce32_size) in tce_iommu_enable()
292 locked = table_group->tce32_size >> PAGE_SHIFT; in tce_iommu_enable()
607 struct iommu_table_group *table_group, in tce_iommu_create_table() argument
616 table_size = table_group->ops->get_table_size(page_shift, window_size, in tce_iommu_create_table()
625 ret = table_group->ops->create_table(table_group, num, in tce_iommu_create_table()
648 struct iommu_table_group *table_group; in tce_iommu_create_window() local
659 table_group = iommu_group_get_iommudata(tcegrp->grp); in tce_iommu_create_window()
[all …]
/Linux-v6.1/arch/powerpc/platforms/pseries/
Diommu.c71 struct iommu_table_group *table_group; in iommu_pseries_alloc_group() local
73 table_group = kzalloc_node(sizeof(*table_group), GFP_KERNEL, node); in iommu_pseries_alloc_group()
74 if (!table_group) in iommu_pseries_alloc_group()
77 table_group->tables[0] = iommu_pseries_alloc_table(node); in iommu_pseries_alloc_group()
78 if (table_group->tables[0]) in iommu_pseries_alloc_group()
79 return table_group; in iommu_pseries_alloc_group()
81 kfree(table_group); in iommu_pseries_alloc_group()
85 static void iommu_pseries_free_group(struct iommu_table_group *table_group, in iommu_pseries_free_group() argument
90 if (!table_group) in iommu_pseries_free_group()
93 tbl = table_group->tables[0]; in iommu_pseries_free_group()
[all …]
/Linux-v6.1/arch/powerpc/include/asm/
Diommu.h166 long (*create_table)(struct iommu_table_group *table_group,
172 long (*set_window)(struct iommu_table_group *table_group,
175 long (*unset_window)(struct iommu_table_group *table_group,
178 void (*take_ownership)(struct iommu_table_group *table_group);
180 void (*release_ownership)(struct iommu_table_group *table_group);
186 struct iommu_table_group *table_group; member
204 extern void iommu_register_group(struct iommu_table_group *table_group,
206 extern int iommu_add_device(struct iommu_table_group *table_group,
219 static inline void iommu_register_group(struct iommu_table_group *table_group, in iommu_register_group() argument
225 static inline int iommu_add_device(struct iommu_table_group *table_group, in iommu_add_device() argument
Dpci-bridge.h204 struct iommu_table_group *table_group; /* for phb's or bridges */ member
/Linux-v6.1/arch/powerpc/platforms/powernv/
Dpci-ioda-tce.c371 struct iommu_table_group *table_group) in pnv_pci_unlink_table_and_group() argument
377 if (!tbl || !table_group) in pnv_pci_unlink_table_and_group()
385 if (tgl->table_group == table_group) { in pnv_pci_unlink_table_and_group()
400 if (table_group->tables[i] == tbl) { in pnv_pci_unlink_table_and_group()
402 table_group->tables[i] = NULL; in pnv_pci_unlink_table_and_group()
412 struct iommu_table_group *table_group) in pnv_pci_link_table_and_group() argument
416 if (WARN_ON(!tbl || !table_group)) in pnv_pci_link_table_and_group()
424 tgl->table_group = table_group; in pnv_pci_link_table_and_group()
427 table_group->tables[num] = iommu_tce_table_get(tbl); in pnv_pci_link_table_and_group()
Dpci-ioda.c1155 set_iommu_table_base(&pdev->dev, pe->table_group.tables[0]); in pnv_pci_ioda_dma_dev_setup()
1158 if (pe->table_group.group) in pnv_pci_ioda_dma_dev_setup()
1159 iommu_add_device(&pe->table_group, &pdev->dev); in pnv_pci_ioda_dma_dev_setup()
1282 struct pnv_ioda_pe *pe = container_of(tgl->table_group, in pnv_pci_p7ioc_tce_invalidate()
1283 struct pnv_ioda_pe, table_group); in pnv_pci_p7ioc_tce_invalidate()
1406 struct pnv_ioda_pe *pe = container_of(tgl->table_group, in pnv_pci_ioda2_tce_invalidate()
1407 struct pnv_ioda_pe, table_group); in pnv_pci_ioda2_tce_invalidate()
1557 iommu_register_group(&pe->table_group, phb->hose->global_number, in pnv_pci_ioda1_setup_dma_pe()
1559 pnv_pci_link_table_and_group(phb->hose->node, 0, tbl, &pe->table_group); in pnv_pci_ioda1_setup_dma_pe()
1610 pe->table_group.tce32_start = tbl->it_offset << tbl->it_page_shift; in pnv_pci_ioda1_setup_dma_pe()
[all …]
Dpci.h80 struct iommu_table_group table_group; member
326 struct iommu_table_group *table_group);
328 struct iommu_table_group *table_group);
/Linux-v6.1/arch/powerpc/kvm/
Dbook3s_64_vio.c86 struct iommu_table_group *table_group = NULL; in kvm_spapr_tce_release_iommu_group() local
91 table_group = iommu_group_get_iommudata(grp); in kvm_spapr_tce_release_iommu_group()
92 if (WARN_ON(!table_group)) in kvm_spapr_tce_release_iommu_group()
97 if (table_group->tables[i] != stit->tbl) in kvm_spapr_tce_release_iommu_group()
114 struct iommu_table_group *table_group; in kvm_spapr_tce_attach_iommu_group() local
137 table_group = iommu_group_get_iommudata(grp); in kvm_spapr_tce_attach_iommu_group()
138 if (WARN_ON(!table_group)) in kvm_spapr_tce_attach_iommu_group()
142 struct iommu_table *tbltmp = table_group->tables[i]; in kvm_spapr_tce_attach_iommu_group()
/Linux-v6.1/arch/powerpc/kernel/
Diommu.c982 struct iommu_table_group *table_group = iommu_data; in group_release() local
984 table_group->group = NULL; in group_release()
987 void iommu_register_group(struct iommu_table_group *table_group, in iommu_register_group() argument
999 table_group->group = grp; in iommu_register_group()
1000 iommu_group_set_iommudata(grp, table_group, group_release); in iommu_register_group()
1144 int iommu_add_device(struct iommu_table_group *table_group, struct device *dev) in iommu_add_device() argument
1162 __func__, dev_name(dev), iommu_group_id(table_group->group)); in iommu_add_device()
1164 return iommu_group_add_device(table_group->group, dev); in iommu_add_device()