2 * Code borrowed from powerpc/kernel/pci-common.c
4 * Copyright (C) 2003 Anton Blanchard <anton@au.ibm.com>, IBM
5 * Copyright (C) 2014 ARM Ltd.
7 * This program is free software; you can redistribute it and/or
8 * modify it under the terms of the GNU General Public License
9 * version 2 as published by the Free Software Foundation.
13 #include <linux/init.h>
15 #include <linux/kernel.h>
17 #include <linux/of_pci.h>
18 #include <linux/of_platform.h>
19 #include <linux/slab.h>
21 #include <asm/pci-bridge.h>
24 * Called after each bus is probed, but before its children are examined
26 void pcibios_fixup_bus(struct pci_bus *bus)
28 /* nothing to do, expected to be removed in the future */
32 * We don't have to worry about legacy ISA devices, so nothing to do here
34 resource_size_t pcibios_align_resource(void *data, const struct resource *res,
35 resource_size_t size, resource_size_t align)
41 * Try to assign the IRQ number from DT when adding a new device
43 int pcibios_add_device(struct pci_dev *dev)
45 dev->irq = of_irq_parse_and_map_pci(dev, 0, 0);