Lines Matching refs:zdev
34 struct zpci_dev *zdev;
90 struct zpci_dev *zdev = to_zpci_dev(dev);
95 if (!zdev)
102 if (zdev->dma_table)
103 zpci_dma_exit_device(zdev);
105 zdev->dma_table = s390_domain->dma_table;
106 rc = zpci_register_ioat(zdev, 0, zdev->start_dma, zdev->end_dma,
107 (u64) zdev->dma_table);
114 domain->geometry.aperture_start = zdev->start_dma;
115 domain->geometry.aperture_end = zdev->end_dma;
118 } else if (domain->geometry.aperture_start != zdev->start_dma ||
119 domain->geometry.aperture_end != zdev->end_dma) {
124 domain_device->zdev = zdev;
125 zdev->s390_domain = s390_domain;
132 zpci_dma_init_device(zdev);
142 struct zpci_dev *zdev = to_zpci_dev(dev);
147 if (!zdev)
153 if (domain_device->zdev == zdev) {
163 zdev->s390_domain = NULL;
164 zpci_unregister_ioat(zdev, 0);
165 zpci_dma_init_device(zdev);
171 struct zpci_dev *zdev = to_zpci_dev(dev);
173 return &zdev->iommu_dev;
178 struct zpci_dev *zdev = to_zpci_dev(dev);
192 if (zdev && zdev->s390_domain) {
232 rc = zpci_refresh_trans((u64) domain_device->zdev->fh << 32,
327 int zpci_init_iommu(struct zpci_dev *zdev)
331 rc = iommu_device_sysfs_add(&zdev->iommu_dev, NULL, NULL,
332 "s390-iommu.%08x", zdev->fid);
336 iommu_device_set_ops(&zdev->iommu_dev, &s390_iommu_ops);
338 rc = iommu_device_register(&zdev->iommu_dev);
345 iommu_device_sysfs_remove(&zdev->iommu_dev);
351 void zpci_destroy_iommu(struct zpci_dev *zdev)
353 iommu_device_unregister(&zdev->iommu_dev);
354 iommu_device_sysfs_remove(&zdev->iommu_dev);