[coreboot] [commit] r5030 - trunk/src/devices

svn at coreboot.org svn at coreboot.org
Sun Jan 17 14:54:09 CET 2010


Author: stepan
Date: 2010-01-17 14:54:08 +0100 (Sun, 17 Jan 2010)
New Revision: 5030

Modified:
   trunk/src/devices/pciexp_device.c
Log:
Initial PCIe tuning: Enable Active State Power Management (ASPM)

Signed-off-by: Stefan Reinauer <stepan at coresystems.de>
Acked-by: Ronald G. Minnich <rminnich at gmail.com>
Acked-by: Peter Stuge <peter at stuge.se>



Modified: trunk/src/devices/pciexp_device.c
===================================================================
--- trunk/src/devices/pciexp_device.c	2010-01-17 13:52:50 UTC (rev 5029)
+++ trunk/src/devices/pciexp_device.c	2010-01-17 13:54:08 UTC (rev 5030)
@@ -34,8 +34,16 @@
 		/* error... */
 		return;
 	}
-	// printk_debug("PCIe: tuning %s\n", dev_path(dev));
-	/* TODO: Implement PCI Express tuning. */
+#ifdef CONFIG_PCIE_TUNING
+	printk_debug("PCIe: tuning %s\n", dev_path(dev));
+
+	// TODO make this depending on ASPM
+	/* Enable ASPM Role Based Error Reporting */
+	u32 reg32;
+	reg32 = pci_read_config32(dev, cap + PCI_EXP_DEVCAP);
+	reg32 |= PCI_EXP_DEVCAP_RBER;
+	pci_write_config32(dev, cap + PCI_EXP_DEVCAP, reg32);
+#endif
 }
 
 unsigned int pciexp_scan_bus(struct bus *bus, 





More information about the coreboot mailing list