mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-11-19 02:04:19 +08:00
98d9f30c82
powerpc has two different ways of matching PCI devices to their corresponding OF node (if any) for historical reasons. The ppc64 one does a scan looking for matching bus/dev/fn, while the ppc32 one does a scan looking only for matching dev/fn on each level in order to be agnostic to busses being renumbered (which Linux does on some platforms). This removes both and instead moves the matching code to the PCI core itself. It's the most logical place to do it: when a pci_dev is created, we know the parent and thus can do a single level scan for the matching device_node (if any). The benefit is that all archs now get the matching for free. There's one hook the arch might want to provide to match a PHB bus to its device node. A default weak implementation is provided that looks for the parent device device node, but it's not entirely reliable on powerpc for various reasons so powerpc provides its own. Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org> Acked-by: Michal Simek <monstr@monstr.eu> Acked-by: Jesse Barnes <jbarnes@virtuousgeek.org>
85 lines
1.3 KiB
Plaintext
85 lines
1.3 KiB
Plaintext
config DTC
|
|
bool
|
|
|
|
config OF
|
|
bool
|
|
|
|
menu "Device Tree and Open Firmware support"
|
|
depends on OF
|
|
|
|
config PROC_DEVICETREE
|
|
bool "Support for device tree in /proc"
|
|
depends on PROC_FS && !SPARC
|
|
help
|
|
This option adds a device-tree directory under /proc which contains
|
|
an image of the device tree that the kernel copies from Open
|
|
Firmware or other boot firmware. If unsure, say Y here.
|
|
|
|
config OF_FLATTREE
|
|
bool
|
|
select DTC
|
|
|
|
config OF_EARLY_FLATTREE
|
|
bool
|
|
select OF_FLATTREE
|
|
|
|
config OF_PROMTREE
|
|
bool
|
|
|
|
config OF_DYNAMIC
|
|
def_bool y
|
|
depends on PPC_OF
|
|
|
|
config OF_ADDRESS
|
|
def_bool y
|
|
depends on !SPARC
|
|
|
|
config OF_IRQ
|
|
def_bool y
|
|
depends on !SPARC
|
|
|
|
config OF_DEVICE
|
|
def_bool y
|
|
|
|
config OF_GPIO
|
|
def_bool y
|
|
depends on GPIOLIB && !SPARC
|
|
help
|
|
OpenFirmware GPIO accessors
|
|
|
|
config OF_I2C
|
|
def_tristate I2C
|
|
depends on I2C && !SPARC
|
|
help
|
|
OpenFirmware I2C accessors
|
|
|
|
config OF_NET
|
|
depends on NETDEVICES
|
|
def_bool y
|
|
|
|
config OF_SPI
|
|
def_tristate SPI
|
|
depends on SPI && !SPARC
|
|
help
|
|
OpenFirmware SPI accessors
|
|
|
|
config OF_MDIO
|
|
def_tristate PHYLIB
|
|
depends on PHYLIB
|
|
help
|
|
OpenFirmware MDIO bus (Ethernet PHY) accessors
|
|
|
|
config OF_PCI
|
|
def_tristate PCI
|
|
depends on PCI
|
|
help
|
|
OpenFirmware PCI bus accessors
|
|
|
|
config OF_PCI_IRQ
|
|
def_tristate PCI
|
|
depends on OF_PCI && OF_IRQ
|
|
help
|
|
OpenFirmware PCI IRQ routing helpers
|
|
|
|
endmenu # OF
|