/* pci_hose_phys_to_bus(): Convert physical address to bus address @hose: PCI hose of the root PCI controller @phys_addr: physical address to convert @flags: flags of pci regions  */
pci_addr_t pci_hose_phys_to_bus(struct pci_controller *hose, phys_addr_t phys_addr, unsigned long flags)
/* pci_hose_phys_to_bus(): Convert physical address to bus address @hose: PCI hose of the root PCI controller @phys_addr: physical address to convert @flags: flags of pci regions  */
pci_addr_t pci_hose_phys_to_bus(struct pci_controller *hose, phys_addr_t phys_addr, unsigned long flags)
{
	pci_addr_t bus_addr = 0;
	int ret;
	if (!hose) {
		puts("pci_hose_phys_to_bus: invalid hose\n");
		return bus_addr;
	}
	if ((flags & PCI_REGION_TYPE) == PCI_REGION_MEM) {
		ret = __pci_hose_phys_to_bus(hose, phys_addr,
				flags, PCI_REGION_SYS_MEMORY, &bus_addr);
		if (!ret)
			return bus_addr;
	}
	ret = __pci_hose_phys_to_bus(hose, phys_addr, flags, 0, &bus_addr);
	if (ret)
		puts("pci_hose_phys_to_bus: invalid physical address\n");
	return bus_addr;
}