Kyösti Mälkki (kyosti.malkki(a)gmail.com) just uploaded a new patch set to gerrit, which you can find at http://review.coreboot.org/8537
-gerrit
commit a1d57ae089d87ca844cec87d6590fdc1a3301ec1
Author: Kyösti Mälkki <kyosti.malkki(a)gmail.com>
Date: Mon Feb 23 06:58:26 2015 +0200
PCI subsystem: Use subordinate property to track bus enumeration
Parameter max is the cumulative number of PCI buses scanned on the
system so far. Use the property subordinate from the parent PCI bridge
device to keep track of the first available bus number instead of
passing that on the stack.
Change-Id: I1a884c98d50fa4f1eb2752e10b778aea8a7b090a
Signed-off-by: Kyösti Mälkki <kyosti.malkki(a)gmail.com>
---
src/device/pci_device.c | 29 +++++++++--------------------
1 file changed, 9 insertions(+), 20 deletions(-)
diff --git a/src/device/pci_device.c b/src/device/pci_device.c
index b76563c..6cb99bf 100644
--- a/src/device/pci_device.c
+++ b/src/device/pci_device.c
@@ -1174,11 +1174,16 @@ static void pci_bridge_route(struct bus *link, scan_state state)
struct bus *parent = dev->bus;
u32 reg, buses = 0;
+ if (state == PCI_ROUTE_SCAN) {
+ link->secondary = parent->subordinate + 1;
+ link->subordinate = link->secondary;
+ }
+
if (state == PCI_ROUTE_CLOSE) {
buses |= 0xfeff << 8;
} else if (state == PCI_ROUTE_SCAN) {
buses |= ((u32) link->secondary & 0xff) << 8;
- buses |= ((u32) link->subordinate & 0xff) << 16;
+ buses |= 0xff << 16; /* MAX PCI_BUS number here */
} else if (state == PCI_ROUTE_FINAL) {
buses |= parent->secondary & 0xff;
buses |= ((u32) link->secondary & 0xff) << 8;
@@ -1205,10 +1210,10 @@ static void pci_bridge_route(struct bus *link, scan_state state)
if (state == PCI_ROUTE_FINAL) {
pci_write_config16(dev, PCI_COMMAND, link->bridge_cmd);
+ parent->subordinate = link->subordinate;
}
}
-
/**
* Scan a PCI bridge and the buses behind the bridge.
*
@@ -1244,29 +1249,13 @@ unsigned int do_pci_scan_bridge(struct device *dev, unsigned int max,
bus = dev->link_list;
- /*
- * Set up the primary, secondary and subordinate bus numbers. We have
- * no idea how many buses are behind this bridge yet, so we set the
- * subordinate bus number to 0xff for the moment.
- */
- bus->secondary = ++max;
- bus->subordinate = 0xff;
-
pci_bridge_route(bus, PCI_ROUTE_SCAN);
- /* Now we can scan all subordinate buses (those behind the bridge). */
- max = do_scan_bus(bus, 0x00, 0xff, max);
-
- /*
- * We know the number of buses behind this bridge. Set the subordinate
- * bus number to its real value.
- */
- bus->subordinate = max;
+ bus->subordinate = do_scan_bus(bus, 0x00, 0xff, bus->secondary);
pci_bridge_route(bus, PCI_ROUTE_FINAL);
- printk(BIOS_SPEW, "%s returns max %d\n", __func__, max);
- return max;
+ return bus->subordinate;
}
/**
the following patch was just integrated into master:
commit 83b05eb0a85d7b7ac0837cece67afabbdb46ea65
Author: Alexandru Gagniuc <mr.nuke.me(a)gmail.com>
Date: Sun Feb 15 14:09:21 2015 -0600
google/butterfly: Drop MRC.bin in favor of native raminit
I thought this wasn't going to work, and observing the timC detection
failure of early tests, I was getting somewhat discouraged; however,
this works. I've tried it with all possible permutations of the
following memory modules:
* 2 GiB single-rank DDR3-1600
* 4 GiB single-rank DDR3-1600
* 4 GiB dual-rank DDR3-1600
I did notice a limited number of memtest errors during one of the
runs, but they were in an address range that is otherwise marked as
reserved. I wrote that off as "maybe something was doing MMIO there
just when memtest was poking the address range". I was not able to
reproduce that error.
Change-Id: Ibd52e1d52fc8d900591d6a488f9a5b4d1e5e4fd3
Signed-off-by: Alexandru Gagniuc <mr.nuke.me(a)gmail.com>
Reviewed-on: http://review.coreboot.org/8477
Tested-by: build bot (Jenkins)
Reviewed-by: Aaron Durbin <adurbin(a)gmail.com>
See http://review.coreboot.org/8477 for details.
-gerrit
the following patch was just integrated into master:
commit 21d898bad093955d26c928d218a53cc56c18ab57
Author: Timothy Pearson <tpearson(a)raptorengineeringinc.com>
Date: Sat Mar 14 20:07:13 2015 -0500
mainboard/asus/kfsn4-dre: Use Fallback boot image by default
Change-Id: Ib58550acda63132e35a526c72ac7d987b457cea5
Signed-off-by: Timothy Pearson <tpearson(a)raptorengineeringinc.com>
Reviewed-on: http://review.coreboot.org/8686
Tested-by: build bot (Jenkins)
Reviewed-by: Alexandru Gagniuc <mr.nuke.me(a)gmail.com>
See http://review.coreboot.org/8686 for details.
-gerrit
the following patch was just integrated into master:
commit d7210c579e20a2844da3a96747e8f4cc3695b042
Author: Timothy Pearson <tpearson(a)raptorengineeringinc.com>
Date: Sat Mar 14 17:58:24 2015 -0500
mainboard/asus/kfsn4-dre: Change default debug level to Spew
This brings the KFSN4-DRE in line with other boards in the tree.
Change-Id: I9216130f51ed0576871fd27ca6ae4610c5f5810e
Signed-off-by: Timothy Pearson <tpearson(a)raptorengineeringinc.com>
Reviewed-on: http://review.coreboot.org/8683
Tested-by: build bot (Jenkins)
Reviewed-by: Paul Menzel <paulepanter(a)users.sourceforge.net>
Reviewed-by: Alexandru Gagniuc <mr.nuke.me(a)gmail.com>
See http://review.coreboot.org/8683 for details.
-gerrit
the following patch was just integrated into master:
commit b812d5d92fc6f7e2227c10e07478fb0330e3ee94
Author: Timothy Pearson <tpearson(a)raptorengineeringinc.com>
Date: Sat Mar 14 19:59:54 2015 -0500
northbridge/amd/amdht/h3finit.c: Fix boot failure
GIT hash 586d6e introduced a regression that causes boot failure
with an f0011449 AMD stop code.
Change-Id: Ieced9088b79bc89d55117b7240b82a086eff9d21
Signed-off-by: Timothy Pearson <tpearson(a)raptorengineeringinc.com>
Reviewed-on: http://review.coreboot.org/8685
Tested-by: build bot (Jenkins)
Reviewed-by: Alexandru Gagniuc <mr.nuke.me(a)gmail.com>
See http://review.coreboot.org/8685 for details.
-gerrit