diff options
| -rw-r--r-- | arch/i386/pci/mmconfig.c | 35 |
1 files changed, 0 insertions, 35 deletions
diff --git a/arch/i386/pci/mmconfig.c b/arch/i386/pci/mmconfig.c index d0c3da3aa2aa..c6b6d9bbc453 100644 --- a/arch/i386/pci/mmconfig.c +++ b/arch/i386/pci/mmconfig.c | |||
| @@ -154,38 +154,6 @@ static struct pci_raw_ops pci_mmcfg = { | |||
| 154 | .write = pci_mmcfg_write, | 154 | .write = pci_mmcfg_write, |
| 155 | }; | 155 | }; |
| 156 | 156 | ||
| 157 | |||
| 158 | static __init void pci_mmcfg_insert_resources(void) | ||
| 159 | { | ||
| 160 | #define PCI_MMCFG_RESOURCE_NAME_LEN 19 | ||
| 161 | int i; | ||
| 162 | struct resource *res; | ||
| 163 | char *names; | ||
| 164 | unsigned num_buses; | ||
| 165 | |||
| 166 | res = kcalloc(PCI_MMCFG_RESOURCE_NAME_LEN + sizeof(*res), | ||
| 167 | pci_mmcfg_config_num, GFP_KERNEL); | ||
| 168 | |||
| 169 | if (!res) { | ||
| 170 | printk(KERN_ERR "PCI: Unable to allocate MMCONFIG resources\n"); | ||
| 171 | return; | ||
| 172 | } | ||
| 173 | |||
| 174 | names = (void *)&res[pci_mmcfg_config_num]; | ||
| 175 | for (i = 0; i < pci_mmcfg_config_num; i++, res++) { | ||
| 176 | num_buses = pci_mmcfg_config[i].end_bus_number - | ||
| 177 | pci_mmcfg_config[i].start_bus_number + 1; | ||
| 178 | res->name = names; | ||
| 179 | snprintf(names, PCI_MMCFG_RESOURCE_NAME_LEN, "PCI MMCONFIG %u", | ||
| 180 | pci_mmcfg_config[i].pci_segment_group_number); | ||
| 181 | res->start = pci_mmcfg_config[i].base_address; | ||
| 182 | res->end = res->start + (num_buses << 20) - 1; | ||
| 183 | res->flags = IORESOURCE_MEM | IORESOURCE_BUSY; | ||
| 184 | insert_resource(&iomem_resource, res); | ||
| 185 | names += PCI_MMCFG_RESOURCE_NAME_LEN; | ||
| 186 | } | ||
| 187 | } | ||
| 188 | |||
| 189 | /* K8 systems have some devices (typically in the builtin northbridge) | 157 | /* K8 systems have some devices (typically in the builtin northbridge) |
| 190 | that are only accessible using type1 | 158 | that are only accessible using type1 |
| 191 | Normally this can be expressed in the MCFG by not listing them | 159 | Normally this can be expressed in the MCFG by not listing them |
| @@ -222,8 +190,6 @@ static __init void unreachable_devices(void) | |||
| 222 | } | 190 | } |
| 223 | } | 191 | } |
| 224 | 192 | ||
| 225 | |||
| 226 | |||
| 227 | void __init pci_mmcfg_init(int type) | 193 | void __init pci_mmcfg_init(int type) |
| 228 | { | 194 | { |
| 229 | if ((pci_probe & PCI_PROBE_MMCONF) == 0) | 195 | if ((pci_probe & PCI_PROBE_MMCONF) == 0) |
| @@ -251,5 +217,4 @@ void __init pci_mmcfg_init(int type) | |||
| 251 | pci_probe = (pci_probe & ~PCI_PROBE_MASK) | PCI_PROBE_MMCONF; | 217 | pci_probe = (pci_probe & ~PCI_PROBE_MASK) | PCI_PROBE_MMCONF; |
| 252 | 218 | ||
| 253 | unreachable_devices(); | 219 | unreachable_devices(); |
| 254 | pci_mmcfg_insert_resources(); | ||
| 255 | } | 220 | } |
