Since some people disapprove of white space cleanups mixed in regular commits
[coreboot.git] / src / northbridge / intel / e7520 / pciexp_portb.c
1 #include <console/console.h>
2 #include <device/device.h>
3 #include <device/pci.h>
4 #include <device/pci_ids.h>
5 #include <device/pci_ops.h>
6 #include <device/pciexp.h>
7 #include <device/pciexp.h>
8 #include <arch/io.h>
9 #include "chip.h"
10
11 typedef struct northbridge_intel_e7520_config config_t;
12
13 static void pcie_init(struct device *dev)
14 {
15         config_t *config;
16
17         /* Get the chip configuration */
18         config = dev->chip_info;
19
20         if(config->intrline) {
21                 pci_write_config32(dev, 0x3c, config->intrline);
22         }
23
24 }
25
26 static struct device_operations pcie_ops  = {
27         .read_resources   = pci_bus_read_resources,
28         .set_resources    = pci_dev_set_resources,
29         .enable_resources = pci_bus_enable_resources,
30         .init             = pcie_init,
31         .scan_bus         = pciexp_scan_bridge,
32         .reset_bus        = pci_bus_reset,
33         .ops_pci          = 0,
34 };
35
36 static const struct pci_driver pci_driver __pci_driver = {
37         .ops    = &pcie_ops,
38         .vendor = PCI_VENDOR_ID_INTEL,
39         .device = PCI_DEVICE_ID_INTEL_PCIE_PB,
40 };
41
42