--- zzzz-none-000/linux-4.9.276/drivers/of/address.c 2021-07-20 14:21:16.000000000 +0000 +++ falcon-5530-750/linux-4.9.276/drivers/of/address.c 2023-04-05 08:19:01.000000000 +0000 @@ -313,6 +313,7 @@ * To guard against that we try to register the IO range first. * If that fails we know that pci_address_to_pio() will do too. */ +#ifndef CONFIG_MIPS int of_pci_range_to_resource(struct of_pci_range *range, struct device_node *np, struct resource *res) { @@ -349,6 +350,19 @@ res->end = (resource_size_t)OF_BAD_ADDR; return err; } +#else +int of_pci_range_to_resource(struct of_pci_range *range, + struct device_node *np, + struct resource *res) +{ + res->flags = range->flags; + res->start = range->cpu_addr; + res->end = range->cpu_addr + range->size - 1; + res->parent = res->child = res->sibling = NULL; + res->name = np->full_name; + return 0; +} +#endif /* CONFIG_MIPS */ #endif /* CONFIG_PCI */ /*