Patchwork ASUS M2N-MX support

login
register
about
Submitter Stefan Tauner
Date 2012-08-15 00:59:28
Message ID <201208150059.q7F0xSSw028323@mail2.student.tuwien.ac.at>
Download mbox | patch
Permalink /patch/3710/
State Changes Requested
Headers show

Comments

Stefan Tauner - 2012-08-15 00:59:28
Hello!

I am sending this email to you because you have send logs regarding the
M2N-MX mainboard. For a long time we were missing the necessary
infrastructure to add support for that board easily and later it seems
to have been forgotten. To this day it was only possible to read
from the flash chip but not to write to it. Sorry about that!

I have attached a patch that hopefully enables erase/write on that board
and would like you to test if it works if you still have access to that
board.

The patch has to be applied to the latest development code (r1573) of
flashrom that can be found here:
http://flashrom.org/Downloads
After saving the patch file to the flashrom directory please run the
following inside the flashrom directory to apply it:
patch < 0001-Add-board-enable-for-ASUS-M2N-MX.patch
After that you can compile with "make". It should create an executable
file named "flashrom in that directory.

Although i think it is pretty safe to try, please make at least a
backup of the original flash contents with -r before trying to erase or
write! If anything unexpected happens don't reboot or shut down, but
contact us please. If you try to write please reply with the output of
./flashrom -V -p internal -w <new bios image>
cjt2007 - 2012-08-15 05:54:22
Hello,

many thanks for the reply containing the patch for the M2N-MX board and the 
details how to apply it. I'll try to run it as soon as possible and get back to 
you with the results.

Independent from testing this board: great work guys!

Cheers
Christoph


On 15.08.2012 02:59, Stefan Tauner wrote:
> Hello!
>
> I am sending this email to you because you have send logs regarding the
> M2N-MX mainboard. For a long time we were missing the necessary
> infrastructure to add support for that board easily and later it seems
> to have been forgotten. To this day it was only possible to read
> from the flash chip but not to write to it. Sorry about that!
>
> I have attached a patch that hopefully enables erase/write on that board
> and would like you to test if it works if you still have access to that
> board.
>
> The patch has to be applied to the latest development code (r1573) of
> flashrom that can be found here:
> http://flashrom.org/Downloads
> After saving the patch file to the flashrom directory please run the
> following inside the flashrom directory to apply it:
> patch<  0001-Add-board-enable-for-ASUS-M2N-MX.patch
> After that you can compile with "make". It should create an executable
> file named "flashrom in that directory.
>
> Although i think it is pretty safe to try, please make at least a
> backup of the original flash contents with -r before trying to erase or
> write! If anything unexpected happens don't reboot or shut down, but
> contact us please. If you try to write please reply with the output of
> ./flashrom -V -p internal -w<new bios image>
>
Stefan Tauner - 2012-08-31 21:04:34
On Wed, 15 Aug 2012 07:54:22 +0200
cjt2007 <cjt2007@eisenbroiler.de> wrote:

> Hello,
> 
> many thanks for the reply containing the patch for the M2N-MX board and the 
> details how to apply it. I'll try to run it as soon as possible and get back to 
> you with the results.

we did not get a reply from anybody else, so you are about the last
best hope, hence: ping! :)
cjt2007 - 2012-09-02 19:24:59
On 31.08.2012 23:04, Stefan Tauner wrote:
> On Wed, 15 Aug 2012 07:54:22 +0200
> cjt2007<cjt2007@eisenbroiler.de>  wrote:
>
>> Hello,
>>
>> many thanks for the reply containing the patch for the M2N-MX board and the
>> details how to apply it. I'll try to run it as soon as possible and get back to
>> you with the results.
>
> we did not get a reply from anybody else, so you are about the last
> best hope, hence: ping! :)
>

Earliest access is Sept, 19. I hope this is fine; I'll do my best to find some time.

Cheerio
Christoph
cjt2007 - 2012-09-22 12:52:32
Hi list!

As promised, I trying to test flashrom on the M2N-MX board. Unfortunately, I am 
unable to find the referred source release 1573 on the website, neither in 
releases nor in snapshots. Google redirects me towards the trac system. However, 
access to any files fails due to right restrictions. Presumably this is the 
wrong place to search at...

Could you please assist me to find the appropriate version for the patch file?

Thanks!
Christoph


On 15.08.2012 02:59, Stefan Tauner wrote:
> Hello!
>
> I am sending this email to you because you have send logs regarding the
> M2N-MX mainboard. For a long time we were missing the necessary
> infrastructure to add support for that board easily and later it seems
> to have been forgotten. To this day it was only possible to read
> from the flash chip but not to write to it. Sorry about that!
>
> I have attached a patch that hopefully enables erase/write on that board
> and would like you to test if it works if you still have access to that
> board.
>
> The patch has to be applied to the latest development code (r1573) of
> flashrom that can be found here:
> http://flashrom.org/Downloads
> After saving the patch file to the flashrom directory please run the
> following inside the flashrom directory to apply it:
> patch<  0001-Add-board-enable-for-ASUS-M2N-MX.patch
> After that you can compile with "make". It should create an executable
> file named "flashrom in that directory.
>
> Although i think it is pretty safe to try, please make at least a
> backup of the original flash contents with -r before trying to erase or
> write! If anything unexpected happens don't reboot or shut down, but
> contact us please. If you try to write please reply with the output of
> ./flashrom -V -p internal -w<new bios image>
>
Stefan Tauner - 2012-09-22 13:28:39
On Sat, 22 Sep 2012 14:52:32 +0200
cjt2007 <cjt2007@eisenbroiler.de> wrote:

> Hi list!
> 
> As promised, I trying to test flashrom on the M2N-MX board. Unfortunately, I am 
> unable to find the referred source release 1573 on the website, neither in 
> releases nor in snapshots. Google redirects me towards the trac system. However, 
> access to any files fails due to right restrictions. Presumably this is the 
> wrong place to search at...
> 
> Could you please assist me to find the appropriate version for the patch file?

hello and thanks for reporting back (which does not go without saying)!

joining us on irc is probably a better way to communicate, if that's ok
with you.
http://webchat.freenode.net/?channels=flashrom&uio=d4

in general any recent flashrom version should work (latest stable, or
any development version since then including the latest), but the patch
may not apply cleanly. the "right" way would be to checkout revision
1573 from our source tree in our repository, but the important bit of
the patch is just a single line, which you could add manually too. just
add the following line to the big table in board_enable.c approximately
at line 2350 instead of applying the whole patch:
	{0x10de, 0x03e0, 0x1043, 0x8234,  0x10de, 0x03f5, 0x1043, 0x8234, "^M2N-MX$",   NULL, NULL,           P3, "ASUS", "M2N-MX",                0,   OK, it8712f_gpio31_raise},
Stefan Tauner - 2012-09-25 12:24:05
On Sat, 22 Sep 2012 15:28:39 +0200
Stefan Tauner <stefan.tauner@student.tuwien.ac.at> wrote:

> 	{0x10de, 0x03e0, 0x1043, 0x8234,  0x10de, 0x03f5, 0x1043, 0x8234, "^M2N-MX$",   NULL, NULL,           P3, "ASUS", "M2N-MX",                0,   OK, it8712f_gpio31_raise},

for the record: that did not work out as expected:
http://paste.flashrom.org/view.php?id=1396

Patch

From e2b51e0e88c721bd0bb318874252b03e66df501a Mon Sep 17 00:00:00 2001
From: Stefan Tauner <stefan.tauner@student.tuwien.ac.at>
Date: Wed, 15 Aug 2012 02:39:46 +0200
Subject: [PATCH] Add board enable for ASUS M2N-MX.

Based on the information posted by Michael Karcher:
http://www.flashrom.org/pipermail/flashrom/2010-February/002280.html

Signed-off-by: Stefan Tauner <stefan.tauner@student.tuwien.ac.at>
---
 board_enable.c |    2 ++
 print.c        |    1 +
 2 files changed, 3 insertions(+)

diff --git a/board_enable.c b/board_enable.c
index 9c16905..be6072f 100644
--- a/board_enable.c
+++ b/board_enable.c
@@ -2227,6 +2227,7 @@  static int it8712f_gpio12_raise(void)
  * Suited for:
  * - ASUS A7V600-X: VIA KT600 + VT8237 + IT8712F
  * - ASUS A7V8X-X: VIA KT400 + VT8235 + IT8712F
+ * - ASUS M2N-MX: NVIDIA MCP61 + IT8712F
  */
 static int it8712f_gpio31_raise(void)
 {
@@ -2338,6 +2339,7 @@  const struct board_match board_matches[] = {
 	{0x10DE, 0x0260, 0x103c, 0x2a3e,  0x10DE, 0x0264, 0x103c, 0x2a3e, "NAGAMI2L",   NULL, NULL,           P3, "ASUS",        "A8N-LA (Nagami-GL8E)",  0,   OK, nvidia_mcp_gpio0_raise},
 	{0x10DE, 0x005E, 0x1043, 0x815A,  0x10DE, 0x0054, 0x1043, 0x815A, "^A8N-SLI DELUXE", NULL, NULL,      P3, "ASUS",        "A8N-SLI Deluxe",        0,   NT, board_shuttle_fn25},
 	{0x10de, 0x0264, 0x1043, 0x81bc,  0x10de, 0x02f0, 0x1043, 0x81cd, NULL,         NULL, NULL,           P3, "ASUS",        "A8N-VM CSM",            0,   OK, w83627ehf_gpio22_raise_2e},
+	{0x10de, 0x03e0, 0x1043, 0x8234,  0x10de, 0x03f5, 0x1043, 0x8234, "^M2N-MX$",   NULL, NULL,           P3, "ASUS",        "M2N-MX",                0,   OK, it8712f_gpio31_raise},
 	{0x10DE, 0x0264, 0x1043, 0x81C0,  0x10DE, 0x0260, 0x1043, 0x81C0, NULL,         NULL, NULL,           P3, "ASUS",        "M2NBP-VM CSM",          0,   OK, nvidia_mcp_gpio0_raise},
 	{0x1106, 0x1336, 0x1043, 0x80ed,  0x1106, 0x3288, 0x1043, 0x8249, NULL,         NULL, NULL,           P3, "ASUS",        "M2V-MX",                0,   OK, via_vt823x_gpio5_raise},
 	{0x8086, 0x24cc,      0,      0,  0x8086, 0x24c3, 0x1043, 0x1869, "^M6Ne$",     NULL, NULL,           P3, "ASUS",        "M6Ne",                  0,   NT, intel_ich_gpio43_raise},
diff --git a/print.c b/print.c
index 5a2f902..cffa50b 100644
--- a/print.c
+++ b/print.c
@@ -643,6 +643,7 @@  const struct board_info boards_known[] = {
 	B("ASUS",	"M2N68-VM",		OK, "http://www.asus.com/Motherboards/AMD_AM2Plus/M2N68VM/", NULL),
 	B("ASUS",	"M2N-E",		OK, "http://www.asus.com/Motherboards/AMD_AM2/M2NE/", "If the machine doesn't come up again after flashing, try resetting the NVRAM(CMOS). The MAC address of the onboard network card will change to the value stored in the new image, so backup the old address first. See http://www.flashrom.org/pipermail/flashrom/2009-November/000879.html"),
 	B("ASUS",	"M2N-E SLI",		OK, "http://www.asus.com/Motherboards/AMD_AM2/M2NE_SLI/", NULL),
+	B("ASUS",	"M2N-MX",		OK, "http://www.asus.com/Motherboards/AMD_AM2/M2NMX/", NULL),
 	B("ASUS",	"M2N-SLI Deluxe",	OK, "http://www.asus.com/Motherboards/AMD_AM2/M2NSLI_Deluxe/", NULL),
 	B("ASUS",	"M2NBP-VM CSM",		OK, "http://www.asus.com/Motherboards/AMD_AM2/M2NBPVM_CSM/", NULL),
 	B("ASUS",	"M2NPV-VM",		OK, "http://www.asus.com/Motherboards/AMD_AM2/M2NPVVM/", NULL),
-- 
Kind regards, Stefan Tauner