Patchwork [2/7] Add missing VT8237A id to bootblock.c

login
register
about
Submitter Tobias Diedrich
Date 2010-11-10 19:06:53
Message ID <20101110190926.958425953@yamamaya.is-a-geek.org>
Download mbox | patch
Permalink /patch/2294/
State Accepted
Headers show

Comments

Tobias Diedrich - 2010-11-10 19:06:53
Add the VT8237A id to src/southbridge/via/vt8237r/bootblock.c
I missed this one since it was working anyway, since
"The LPC BIOS ROM is always accessed when ISA addresses
 FFF80000-FFFFFFFF and 000F0000-000FFFFF are decoded" (VT8237R datasheet)
And the rom I use for testing is smaller than this 512KB default range.

Signed-off-by: Tobias Diedrich <ranma+coreboot@tdiedrich.de>

---
Peter Stuge - 2010-11-11 05:12:05
Tobias Diedrich wrote:
> Add the VT8237A id to src/southbridge/via/vt8237r/bootblock.c
> I missed this one since it was working anyway, since
> "The LPC BIOS ROM is always accessed when ISA addresses
>  FFF80000-FFFFFFFF and 000F0000-000FFFFF are decoded" (VT8237R datasheet)
> And the rom I use for testing is smaller than this 512KB default range.
> 
> Signed-off-by: Tobias Diedrich <ranma+coreboot@tdiedrich.de>

Acked-by: Peter Stuge <peter@stuge.se>

r6062

Patch

Index: src/southbridge/via/vt8237r/bootblock.c
===================================================================
--- src/southbridge/via/vt8237r/bootblock.c.orig	2010-11-07 17:59:47.000000000 +0100
+++ src/southbridge/via/vt8237r/bootblock.c	2010-11-07 18:00:04.000000000 +0100
@@ -38,8 +38,14 @@ 
 		dev = pci_locate_device_on_bus(PCI_ID(PCI_VENDOR_ID_VIA,
 			PCI_DEVICE_ID_VIA_VT8237S_LPC), 0);
 
-		if (dev == PCI_DEV_INVALID)
-			return;
+		if (dev == PCI_DEV_INVALID) {
+			/* Power management controller */
+			dev = pci_locate_device_on_bus(PCI_ID(PCI_VENDOR_ID_VIA,
+				PCI_DEVICE_ID_VIA_VT8237A_LPC), 0);
+
+			if (dev == PCI_DEV_INVALID)
+				return;
+		}
 	}
 
 	pci_write_config8(dev, 0x41, 0x7f);