[coreboot-gerrit] Patch set updated for coreboot: c17d83a vortex86ex: Change PCI S/B resource reservation functions for more I/O devices.

Andrew Wu (arw@dmp.com.tw) gerrit at coreboot.org
Thu Oct 31 13:13:43 CET 2013


Andrew Wu (arw at dmp.com.tw) just uploaded a new patch set to gerrit, which you can find at http://review.coreboot.org/3976

-gerrit

commit c17d83a4185923cf904bef86b2d402b92b9241f7
Author: Andrew Wu <arw at dmp.com.tw>
Date:   Thu Oct 31 20:12:09 2013 +0800

    vortex86ex: Change PCI S/B resource reservation functions for more I/O devices.
    
    Originally, Vortex86EX PCI S/B internal resource reservation functions can
    only support one big legacy I/O device space (0-0xfff).
    
    Change function signature to support other non-legacy I/O device space in
    the future.
    
    Change-Id: I22f5c877ed441d59f29801d925ee40b24fb796ce
    Signed-off-by: Andrew Wu <arw at dmp.com.tw>
---
 src/southbridge/dmp/vortex86ex/southbridge.c | 18 +++++++++---------
 1 file changed, 9 insertions(+), 9 deletions(-)

diff --git a/src/southbridge/dmp/vortex86ex/southbridge.c b/src/southbridge/dmp/vortex86ex/southbridge.c
index ddb99b8..c6370db 100644
--- a/src/southbridge/dmp/vortex86ex/southbridge.c
+++ b/src/southbridge/dmp/vortex86ex/southbridge.c
@@ -500,21 +500,21 @@ static void fix_cmos_rtc_time(void)
 	}
 }
 
-static void vortex86_sb_set_io_resv(device_t dev, u32 io_resv_size)
+static void vortex86_sb_set_io_resv(device_t dev, unsigned index, u32 base, u32 size)
 {
 	struct resource *res;
-	res = new_resource(dev, 1);
-	res->base = 0x0UL;
-	res->size = io_resv_size;
+	res = new_resource(dev, index);
+	res->base = base;
+	res->size = size;
 	res->limit = 0xffffUL;
 	res->flags = IORESOURCE_IO | IORESOURCE_ASSIGNED | IORESOURCE_FIXED;
 }
 
-static void vortex86_sb_set_spi_flash_size(device_t dev, u32 flash_size)
+static void vortex86_sb_set_spi_flash_size(device_t dev, unsigned index, u32 flash_size)
 {
 	/* SPI flash is in topmost of 4G memory space */
 	struct resource *res;
-	res = new_resource(dev, 2);
+	res = new_resource(dev, index);
 	res->base = 0x100000000LL - flash_size;
 	res->size = flash_size;
 	res->limit = 0xffffffffUL;
@@ -537,11 +537,11 @@ static void vortex86_sb_read_resources(device_t dev)
 		flash_size = 64 * 1024 * 1024;
 	}
 
-	/* Reserve space for I/O */
-	vortex86_sb_set_io_resv(dev, 0x1000UL);
+	/* Reserve space for legacy I/O */
+	vortex86_sb_set_io_resv(dev, 1, 0, 0x1000UL);
 
 	/* Reserve space for flash */
-	vortex86_sb_set_spi_flash_size(dev, flash_size);
+	vortex86_sb_set_spi_flash_size(dev, 2, flash_size);
 }
 
 static void southbridge_init_func1(struct device *dev)



More information about the coreboot-gerrit mailing list