[coreboot-gerrit] New patch to review for coreboot: nb/i945/gma.c: Set MSAC register correctly

Arthur Heymans (arthur@aheymans.xyz) gerrit at coreboot.org
Sat Oct 22 14:36:56 CEST 2016


Arthur Heymans (arthur at aheymans.xyz) just uploaded a new patch set to gerrit, which you can find at https://review.coreboot.org/17094

-gerrit

commit a909fa05168f97cbcc3c060f02020a6246485d74
Author: Arthur Heymans <arthur at aheymans.xyz>
Date:   Sat Oct 22 14:16:48 2016 +0200

    nb/i945/gma.c: Set MSAC register correctly
    
    This fixes instability on 945gc where asking the IGD
    to do something with compositing, (e.g. launching gdm, gnome, ...)
    completely locks up the system.
    
    TESTED on ga-945gcm-s2l and d945gclf
    TEST: launch GDM (gnome display manager)
    
    Change-Id: Iec49bccf3e3164df9dc1e0b54460a616fe92e04d
    Signed-off-by: Arthur Heymans <arthur at aheymans.xyz>
---
 src/northbridge/intel/i945/gma.c | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/src/northbridge/intel/i945/gma.c b/src/northbridge/intel/i945/gma.c
index 4baed80..a0c5864 100644
--- a/src/northbridge/intel/i945/gma.c
+++ b/src/northbridge/intel/i945/gma.c
@@ -32,6 +32,7 @@
 #include "chip.h"
 
 #define GDRST 0xc0
+#define MSAC 0x62 /* Multi Size Aperture Control */
 
 #define  LVDS_CLOCK_A_POWERUP_ALL	(3 << 8)
 #define  LVDS_CLOCK_B_POWERUP_ALL	(3 << 4)
@@ -580,6 +581,7 @@ static int probe_edid(u8 *pmmio, u8 slave)
 
 static void gma_func0_init(struct device *dev)
 {
+	u8 reg8;
 	u32 reg32;
 
 	/* Unconditionally reset graphics */
@@ -594,6 +596,12 @@ static void gma_func0_init(struct device *dev)
 	pci_write_config32(dev, PCI_COMMAND, reg32 | PCI_COMMAND_MASTER
 		 | PCI_COMMAND_IO | PCI_COMMAND_MEMORY);
 
+	/* Set Untrusted Aperture Size to 256mb */
+	reg8 = pci_read_config8(dev, MSAC);
+	reg8 &= ~0x3;
+	reg8 |= 0x2;
+	pci_write_config8(dev, MSAC, reg8);
+
 	if (IS_ENABLED(CONFIG_MAINBOARD_DO_NATIVE_VGA_INIT)) {
 		/* PCI Init, will run VBIOS */
 		pci_dev_init(dev);



More information about the coreboot-gerrit mailing list