From bbb6d1020f97b2694f496d87c1f49a0cb2e0bb96 Mon Sep 17 00:00:00 2001 From: Eric Biederman Date: Mon, 4 Aug 2003 19:54:48 +0000 Subject: - Fix poor resource allocation estimate. git-svn-id: svn://svn.coreboot.org/coreboot/trunk@1066 2b7e53f0-3cfb-0310-b3e9-8179ed1497e1 --- src/devices/device.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/devices/device.c b/src/devices/device.c index 9e5e24580c..8e6fcb3519 100644 --- a/src/devices/device.c +++ b/src/devices/device.c @@ -217,8 +217,12 @@ void compute_allocate_resource( if (resource->flags & IORESOURCE_IO) { /* Don't allow potential aliases over the * legacy pci expansion card addresses. + * The legacy pci decodes only 10 bits, + * uses 100h - 3ffh. Therefor, only 0 - ff + * can be used out of each 400h block of io + * space. */ - if ((base > 0x3ff) && ((base & 0x300) != 0)) { + if ((base & 0x300) != 0) { base = (base & ~0x3ff) + 0x400; } /* Don't allow allocations in the VGA IO range. -- cgit v1.2.3