20 #include <linux/pci.h>
23 #define XPLB_PCI_ADDR 0x10c
24 #define XPLB_PCI_DATA 0x110
25 #define XPLB_PCI_BUS 0x114
27 #define PCI_HOST_ENABLE_CMD (PCI_COMMAND_SERR | PCI_COMMAND_PARITY | \
28 PCI_COMMAND_MASTER | PCI_COMMAND_MEMORY)
31 { .compatible =
"xlnx,plbv46-pci-1.03.a", },
38 static void xilinx_pci_fixup_bridge(
struct pci_dev *
dev)
46 hose = pci_bus_to_host(dev->
bus);
62 dev_info(&dev->
dev,
"Hiding Xilinx plb-pci host bridge resources %s\n",
91 for (dev = 0; dev < 2; dev++) {
93 for (func = 0; func < 1; func++) {
97 for (offset = 0; offset < 64; offset += 4) {
98 early_read_config_dword(hose, bus,
100 if (offset == 0 && val == 0xFFFFFFFF) {
104 if (!(offset % 0x10))
134 pr_err(
"xilinx-pci: cannot resolve base address\n");
140 pr_err(
"xilinx-pci: pcibios_alloc_controller() failed\n");
147 INDIRECT_TYPE_SET_CFG_TYPE);
165 INDIRECT_TYPE_SET_CFG_TYPE);
167 pr_info(
"xilinx-pci: Registered PCI host bridge\n");