void *(*fn)(struct device_node *, void *),
void *data);
extern void pci_devs_phb_init_dynamic(struct pci_controller *phb);
-extern void ppc_iommu_register_device(struct pci_controller *phb);
-extern void ppc_iommu_unregister_device(struct pci_controller *phb);
-
/* From rtas_pci.h */
extern void init_pci_config_tokens (void);
NULL,
};
-void ppc_iommu_register_device(struct pci_controller *phb)
-{
- iommu_device_sysfs_add(&phb->iommu, phb->parent,
- spapr_tce_iommu_groups, "iommu-phb%04x",
- phb->global_number);
- iommu_device_register(&phb->iommu, &spapr_tce_iommu_ops,
- phb->parent);
-}
-
-void ppc_iommu_unregister_device(struct pci_controller *phb)
-{
- iommu_device_unregister(&phb->iommu);
- iommu_device_sysfs_remove(&phb->iommu);
-}
-
/*
* This registers IOMMU devices of PHBs. This needs to happen
* after core_initcall(iommu_init) + postcore_initcall(pci_driver_init) and
struct pci_controller *hose;
list_for_each_entry(hose, &hose_list, list_node) {
- ppc_iommu_register_device(hose);
+ iommu_device_sysfs_add(&hose->iommu, hose->parent,
+ spapr_tce_iommu_groups, "iommu-phb%04x",
+ hose->global_number);
+ iommu_device_register(&hose->iommu, &spapr_tce_iommu_ops,
+ hose->parent);
}
return 0;
}
pseries_msi_allocate_domains(phb);
- ppc_iommu_register_device(phb);
-
/* Create EEH devices for the PHB */
eeh_phb_pe_create(phb);
}
}
- ppc_iommu_unregister_device(phb);
-
pseries_msi_free_domains(phb);
/* Keep a reference so phb isn't freed yet */