[coreboot-gerrit] Change in coreboot[master]: nb/intel/gm45: Don't substract UMA when computing TOLUD

Arthur Heymans (Code Review) gerrit at coreboot.org
Sat Mar 18 18:16:17 CET 2017


Arthur Heymans has uploaded a new change for review. ( https://review.coreboot.org/18889 )

Change subject: nb/intel/gm45: Don't substract UMA when computing TOLUD
......................................................................

nb/intel/gm45: Don't substract UMA when computing TOLUD

There is no reason to do this and if pci_mmio_size is too low,
increasing UMA size might results in a too high TOLUD for all
resources to fit.

TESTED on Thinkpad X200

Change-Id: I969ffe4a4aaa31dd7993dc6370ccae9e6865a1b1
Signed-off-by: Arthur Heymans <arthur at aheymans.xyz>
---
M src/northbridge/intel/gm45/raminit.c
1 file changed, 1 insertion(+), 22 deletions(-)


  git pull ssh://review.coreboot.org:29418/coreboot refs/changes/89/18889/1

diff --git a/src/northbridge/intel/gm45/raminit.c b/src/northbridge/intel/gm45/raminit.c
index 0435cdd..46aadb5 100644
--- a/src/northbridge/intel/gm45/raminit.c
+++ b/src/northbridge/intel/gm45/raminit.c
@@ -1226,29 +1226,8 @@
 
 	/* Calculate memory mapping, all values in MB. */
 
-	u32 uma_sizem = 0;
-	if (!prejedec) {
-		if (!(ggc & 2)) {
-			printk(BIOS_DEBUG, "IGD decoded, subtracting ");
-
-			/* Graphics memory */
-			const u32 gms_sizek = decode_igd_memory_size((ggc >> 4) & 0xf);
-			printk(BIOS_DEBUG, "%uM UMA", gms_sizek >> 10);
-
-			/* GTT Graphics Stolen Memory Size (GGMS) */
-			const u32 gsm_sizek = decode_igd_gtt_size((ggc >> 8) & 0xf);
-			printk(BIOS_DEBUG, " and %uM GTT\n", gsm_sizek >> 10);
-
-			uma_sizem = (gms_sizek + gsm_sizek) >> 10;
-			/* Further reduce MTRR usage if it costs use less than
-			   16 MiB.  */
-			if (ALIGN_UP(uma_sizem, 64) - uma_sizem <= 16)
-				uma_sizem = ALIGN_UP(uma_sizem, 64);
-		}
-	}
-
 	const unsigned int mmio_size = get_mmio_size();
-	const unsigned int MMIOstart = 4096 - mmio_size + uma_sizem;
+	const unsigned int MMIOstart = 4096 - mmio_size;
 	const int me_active = pci_read_config8(PCI_DEV(0, 3, 0), PCI_CLASS_REVISION) != 0xff;
 	const unsigned int ME_SIZE = prejedec || !me_active ? 0 : 32;
 	const unsigned int usedMEsize = (total_mb[0] != total_mb[1]) ? ME_SIZE : 2 * ME_SIZE;

-- 
To view, visit https://review.coreboot.org/18889
To unsubscribe, visit https://review.coreboot.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I969ffe4a4aaa31dd7993dc6370ccae9e6865a1b1
Gerrit-PatchSet: 1
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-Owner: Arthur Heymans <arthur at aheymans.xyz>



More information about the coreboot-gerrit mailing list