Patchwork Support for Asus M4A78-EM mainboard

login
register
about
Submitter Juhana Helovuo
Date 2010-12-05 14:39:54
Message ID <4CFBA43A.6030306@iki.fi>
Download mbox | patch
Permalink /patch/2397/
State Accepted
Headers show

Comments

Juhana Helovuo - 2010-12-05 14:39:54
Hello,

Here is a patch to get Asus M4A78-EM supported and booting Linux.

Files attached are:

* Boot log with the patches applied.

* Board-specific patch for SVN 6139

* Resend of Myles Watson's patch for AMD Northbridge, because the 
original did not work for me without manual editing. It is also needed 
for booting Linux.


Before applying the patch, the board directory should be created with

% svn cp src/mainboard/asus/m4a785-m src/mainboard/asus/m4a78-em


Signed-off-by: Juhana Helovuo <juhe@iki.fi>


Best regards,
Juhana Helovuo
Uwe Hermann - 2010-12-06 01:19:55
On Sun, Dec 05, 2010 at 04:39:54PM +0200, Juhana Helovuo wrote:
> Hello,
> 
> Here is a patch to get Asus M4A78-EM supported and booting Linux.
> 
> Files attached are:
> 
> * Boot log with the patches applied.
> 
> * Board-specific patch for SVN 6139
> 
> * Resend of Myles Watson's patch for AMD Northbridge, because the
> original did not work for me without manual editing. It is also
> needed for booting Linux.
> 
> 
> Before applying the patch, the board directory should be created with
> 
> % svn cp src/mainboard/asus/m4a785-m src/mainboard/asus/m4a78-em
> 
> 
> Signed-off-by: Juhana Helovuo <juhe@iki.fi>

Thanks, committed the board as r6141 with some small changes.

I'll leave the northbridge patch out for now, it should be
acked/reviewed in the original thread.

Please review the code carefully for more code/configs which are not
actually specific to this board but rather copy-paste remainders from
the other board dirs this is based on, and/or need to be fixed anyway,
e.g. all of the ACPI files, mptable.c, etc. etc.

 
Thanks, Uwe.

Patch

Index: src/northbridge/amd/amdfam10/northbridge.c
===================================================================
--- src/northbridge/amd/amdfam10/northbridge.c	(revision 6139)
+++ src/northbridge/amd/amdfam10/northbridge.c	(working copy)
@@ -684,6 +684,13 @@ 
 		resource->flags = IORESOURCE_MEM;
 	}
 #endif
+#if CONFIG_MMCONF_SUPPORT
+	struct resource *resource = new_resource(dev, 0xc0010058);
+	resource->base = CONFIG_MMCONF_BASE_ADDRESS;
+	resource->size = CONFIG_MMCONF_BUS_NUMBER * 4096*256;
+	resource->flags = IORESOURCE_MEM | IORESOURCE_RESERVE |
+		IORESOURCE_FIXED | IORESOURCE_STORED |  IORESOURCE_ASSIGNED;
+#endif
 }
 
 static u32 my_find_pci_tolm(struct bus *bus, u32 tolm)
@@ -1447,13 +1454,6 @@ 
 
 static void cpu_bus_read_resources(device_t dev)
 {
-#if CONFIG_MMCONF_SUPPORT
-	struct resource *resource = new_resource(dev, 0xc0010058);
-	resource->base = CONFIG_MMCONF_BASE_ADDRESS;
-	resource->size = CONFIG_MMCONF_BUS_NUMBER * 4096*256;
-	resource->flags = IORESOURCE_MEM | IORESOURCE_RESERVE |
-		IORESOURCE_FIXED | IORESOURCE_STORED |  IORESOURCE_ASSIGNED;
-#endif
 }
 
 static void cpu_bus_set_resources(device_t dev)