On Thu, 19 Jul 2012 04:19:32 +0200
Miloud Malagouen <miloud.malagouen(a)gmail.com> wrote:
> I bricked a MSI MS-7302 motherboard with a bad coreboot image. I'm trying
> to flash the bios with a C232HM-DDHSL-0 FTDI USB
> cable<http://www.ftdichip.com/Products/Cables/USBMPSSE.htm>using the
> MSI JSPI1 Header <http://www.coreboot.org/MSI_JSPI1> present on the board
> for SPI connection. The FTDI cable uses a FT232H chip witch is capable of
> providing a USB to …
[View More]SPI, I2C or JTAG interface.
>
> The FTDI D2XX Linux driver cited that the FT232H chip has type number 6
> (while the FT4232H has type 5), so i had to modify the file
> */usr/include/ftdi.h* and change the ftdi_chip_type enumeration definition:
>
> /** FTDI chip type */
> enum ftdi_chip_type { TYPE_AM=0, TYPE_BM=1, TYPE_2232C=2, TYPE_R=3,
> TYPE_2232H=4, TYPE_4232H=5,*TYPE_232H=6* };
there is probably a way around this, we will have to investigate that.
> I had to add support to the FT232H chip (vid=0403 pid=6014) in the *
> ft2232_spi* programmer of flashrom. I's very simple. Here is the patch of
> file ft2232_spi.c:
thanks for the patch, i'll review it in detail later.
two things certainly need to be changed before this can enter our
repository though:
- man page needs to be updated
- the patch has to be signed off, see
http://www.coreboot.org/Development_Guidelines#Sign-off_Procedure
> =======================BEGIN DIFF================================
> --- flashrom/ft2232_spi.c 2012-07-19 03:43:28.866724677 +0200
> +++ flashrom-0.9.5.2-r1547/ft2232_spi.c 2012-07-16 05:16:53.000000000
> +0200
> […]
> =======================END DIFF==================================
>
>
> The flash memory is probed correctly but erase an write operations failed.
> Here is flashrom command (bold) and output:
> ____________________________________________________________________________________
>
> *flashrom -p ft2232_spi:type=232H,port=A -w A7302AMS.160*
> flashrom v0.9.5.2-runknown on Linux 3.4.4-5.fc17.i686.PAE (i686)
> flashrom is free software, get the source code at http://www.flashrom.org
>
> […]
>
> The chip is powered with an external PSU (3.3V orange cable of an ATX PSU).
> I will try with a 1200F capacitor on the VCC link. I hope this is just
> a magnetic noise issue.
Are all pins connected correctly? especially the #WP pin could introduce
the problem, but all others should be connected as specified in the
datasheet too (e.g. hold pin if available).
--
Kind regards/Mit freundlichen Grüßen, Stefan Tauner
[View Less]
2012/7/19 Riccardo Berto <riccardobrt(a)gmail.com>:
>
>
> ok lol
>
> thanks for the explanation
> btw I think that with battery on it and connected to AC you can use a
> laptop
> safely (with battery you avoid instant shutdowns)
No, the battery isn't there to prevent unexpected poweroffs.
Read the following two wiki pages, there you'll find out more about
why we strongly discourage running flashrom on laptops/mobile
hardware.
http://flashrom.org/Laptopshttp://flashrom.org/Laptop_enable
On Thu, 19 Jul 2012 17:20:46 +0200
Riccardo Berto <riccardobrt(a)gmail.com> wrote:
> ok lol
>
> thanks for the explanation
> btw I think that with battery on it and connected to AC you can use a
> laptop safely (with battery you avoid instant shutdowns)
no that problem is not the supply of power (that is actually a plus for
laptops compared to desktops without an UPS), but the internal workings
of most laptops. they include a chip called embedded controller that
runs its …
[View More]own software and controls things like the backlight of the
display or charging the battery. the problem is that these chips are
often near the flash chip logically and flashrom sometimes irritates
them enough that they just shut down the whole machine.
the main reason why this can happen is that they are not documented
publicly at all, see also http://flashrom.org/Laptops
--
Kind regards/Mit freundlichen Grüßen, Stefan Tauner
[View Less]
On Thu, 19 Jul 2012 16:52:43 +0200
Riccardo Berto <riccardobrt(a)gmail.com> wrote:
> didn't understand to send only if it has succes.
>
>
> sorry but i'm a noob in hardware questions, all the things i can tell you
> is that I have this
> pc<http://www.hackerscomputer.com/art/id15255/acer/acer-aspire-5740g-624g64mn-…>
> (mb Mobile
> Intel HM55 Express).
thank you, that was what i was looking for. at first i presumed you were
running flashrom on a desktop …
[View More]machine.
flashrom tries to detect this (with dmidecode) but failed, hence my
confusion. the reason it checks that at all is that running flashrom on
laptops can be dangerous (e.g. instant shutdowns). it was not in your
case but please refrain from running it on other laptops.
--
Kind regards/Mit freundlichen Grüßen, Stefan Tauner
[View Less]
On Thu, 19 Jul 2012 13:31:03 +0200
Riccardo Berto <riccardobrt(a)gmail.com> wrote:
> in the output of the program, it says to send to this email the verbose
> output if I have untested chip
Hello and thanks for your report,
actually the message requested you to send an email if one of READ,
ERASE or WRITE worked, but that was apparently not the case, and probing
was already marked as working on that chip.
But there is something else in your log that is interesting to us: the
…
[View More]locked ME region. Which mainboard model is that?
--
Kind regards/Mit freundlichen Grüßen, Stefan Tauner
[View Less]
Dear Sir,
I bricked a MSI MS-7302 motherboard with a bad coreboot image. I'm trying
to flash the bios with a C232HM-DDHSL-0 FTDI USB
cable<http://www.ftdichip.com/Products/Cables/USBMPSSE.htm>using the
MSI JSPI1 Header <http://www.coreboot.org/MSI_JSPI1> present on the board
for SPI connection. The FTDI cable uses a FT232H chip witch is capable of
providing a USB to SPI, I2C or JTAG interface.
The FTDI D2XX Linux driver cited that the FT232H chip has type number 6
(while the …
[View More]FT4232H has type 5), so i had to modify the file
*/usr/include/ftdi.h* and change the ftdi_chip_type enumeration definition:
/** FTDI chip type */
enum ftdi_chip_type { TYPE_AM=0, TYPE_BM=1, TYPE_2232C=2, TYPE_R=3,
TYPE_2232H=4, TYPE_4232H=5,*TYPE_232H=6* };
I had to add support to the FT232H chip (vid=0403 pid=6014) in the *
ft2232_spi* programmer of flashrom. I's very simple. Here is the patch of
file ft2232_spi.c:
=======================BEGIN DIFF================================
--- flashrom/ft2232_spi.c 2012-07-19 03:43:28.866724677 +0200
+++ flashrom-0.9.5.2-r1547/ft2232_spi.c 2012-07-16 05:16:53.000000000
+0200
@@ -34,6 +34,7 @@
#define FTDI_VID 0x0403
#define FTDI_FT2232H_PID 0x6010
#define FTDI_FT4232H_PID 0x6011
+#define FTDI_FT232H_PID 0x6014
#define TIAO_TUMPA_PID 0x8a98
#define AMONTEC_JTAGKEY_PID 0xCFF8
@@ -52,6 +53,7 @@
const struct usbdev_status devs_ft2232spi[] = {
{FTDI_VID, FTDI_FT2232H_PID, OK, "FTDI", "FT2232H"},
{FTDI_VID, FTDI_FT4232H_PID, OK, "FTDI", "FT4232H"},
+ {FTDI_VID, FTDI_FT232H_PID, NT, "FTDI", "FT232H"},
{FTDI_VID, TIAO_TUMPA_PID, OK, "TIAO", "USB Multi-Protocol Adapter"},
{FTDI_VID, AMONTEC_JTAGKEY_PID, OK, "Amontec", "JTAGkey"},
{GOEPEL_VID, GOEPEL_PICOTAP_PID, OK, "GOEPEL", "PicoTAP"},
@@ -185,6 +187,8 @@ int ft2232_spi_init(void)
ft2232_type = FTDI_FT2232H_PID;
else if (!strcasecmp(arg, "4232H"))
ft2232_type = FTDI_FT4232H_PID;
+ else if (!strcasecmp(arg, "232H"))
+ ft2232_type = FTDI_FT232H_PID;
else if (!strcasecmp(arg, "jtagkey")) {
ft2232_type = AMONTEC_JTAGKEY_PID;
ft2232_interface = INTERFACE_A;
@@ -285,7 +289,7 @@ int ft2232_spi_init(void)
return -4;
}
- if (ftdic->type != TYPE_2232H && ftdic->type != TYPE_4232H) {
+ if (ftdic->type != TYPE_2232H && ftdic->type != TYPE_4232H &&
ftdic->type != TYPE_232H) {
msg_pdbg("FTDI chip type %d is not high-speed\n",
ftdic->type);
clock_5x = 0;
=======================END DIFF==================================
The flash memory is probed correctly but erase an write operations failed.
Here is flashrom command (bold) and output:
____________________________________________________________________________________
*flashrom -p ft2232_spi:type=232H,port=A -w A7302AMS.160*
flashrom v0.9.5.2-runknown on Linux 3.4.4-5.fc17.i686.PAE (i686)
flashrom is free software, get the source code at http://www.flashrom.org
Calibrating delay loop... OK.
Found Winbond flash chip "W25X80" (1024 kB, SPI) on ft2232_spi.
Reading old flash chip contents... done.
Erasing and writing flash chip... ERASE FAILED at 0x00000000!
Expected=0xff, Read=0x00, failed byte count from 0x00000000-0x00000fff: 0x10
ERASE FAILED!
Reading current flash chip contents... done. ERASE FAILED at 0x00000000!
Expected=0xff, Read=0x00, failed byte count from 0x00000000-0x0000ffff:
0x100
ERASE FAILED!
Reading current flash chip contents... done. ERASE FAILED at 0x00000000!
Expected=0xff, Read=0x00, failed byte count from 0x00000000-0x000fffff:
0xffc
ERASE FAILED!
FAILED!
Uh oh. Erase/write failed. Checking if anything changed.
Your flash chip is in an unknown state.
Get help on IRC at chat.freenode.net (channel #flashrom) or
mail flashrom(a)flashrom.org with the subject "FAILED: <your board name>"!
-------------------------------------------------------------------------------
DO NOT REBOOT OR POWEROFF!
____________________________________________________________________________________
The chip is powered with an external PSU (3.3V orange cable of an ATX PSU).
I will try with a 1200F capacitor on the VCC link. I hope this is just
a magnetic noise issue.
Thank you.
[View Less]
On Wed, 18 Jul 2012 17:12:14 -0400
William Speirs <wspeirs(a)apache.org> wrote:
> So if restoring the backup ROM worked am I safe to power cycle my machine?
yes
> Any ideas on what would be wrong with that ROM?
not yet.
but it is not related to the image itself pretty sure (there is a
theoretical chance that there is a bad bit, that is in the right state
in the old image but not in the new image, but that is quite unlikely).
more likely is that there is some (partial) copy …
[View More]protection in place...
--
Kind regards/Mit freundlichen Grüßen, Stefan Tauner
[View Less]
So if restoring the backup ROM worked am I safe to power cycle my machine?
Any ideas on what would be wrong with that ROM?
Thanks...
Bill-
On Jul 17, 2012 8:49 PM, "William Speirs" <wspeirs(a)apache.org> wrote:
> I was able to write the backup and run verify and it worked. I still
> haven't and won't restart my machine.
>
> After restoring the backup, I tried again with the new BIOS and got the
> same error/issue. I was able to backup yet again without issue.
>
> …
[View More]So I'm guessing it's more of a problem with the ROM image than the program
> writing the ROM. I've attached the ROM to see if that provides any insight.
>
> Thanks again for the help!
>
> Bill-
>
> On Tue, Jul 17, 2012 at 8:22 PM, William Speirs <wspeirs(a)apache.org>wrote:
>
>> I will try writing the backup and certainly leave the machine on.
>>
>> Thanks, and get some sleep ;-)
>>
>> Bill-
>> On Jul 17, 2012 8:20 PM, "Stefan Tauner" <
>> stefan.tauner(a)student.tuwien.ac.at> wrote:
>>
>>> On Tue, 17 Jul 2012 19:39:31 -0400
>>> William Speirs <wspeirs(a)apache.org> wrote:
>>>
>>> > I tried a flashrom -r and compared it to the backup I made and it's
>>> > different. It is also different from the ROM I tried to install.
>>> >
>>> > Any thoughts?
>>>
>>> Most importantly: dont reboot or shutdown that computer. (we really
>>> mean it... but some users do it anyway, and brick their boards that
>>> way)
>>>
>>> i would try writing the backup image again to get to a safe state
>>> again. the reason why it failed in the first place is not obvious to
>>> me, but it is 2:00 AM here, so i might be overlooking something.
>>> --
>>> Kind regards/Mit freundlichen Grüßen, Stefan Tauner
>>>
>>
>
[View Less]
I was able to write the backup and run verify and it worked. I still
haven't and won't restart my machine.
After restoring the backup, I tried again with the new BIOS and got the
same error/issue. I was able to backup yet again without issue.
So I'm guessing it's more of a problem with the ROM image than the program
writing the ROM. I've attached the ROM to see if that provides any insight.
Thanks again for the help!
Bill-
On Tue, Jul 17, 2012 at 8:22 PM, William Speirs <wspeirs(a)…
[View More]apache.org> wrote:
> I will try writing the backup and certainly leave the machine on.
>
> Thanks, and get some sleep ;-)
>
> Bill-
> On Jul 17, 2012 8:20 PM, "Stefan Tauner" <
> stefan.tauner(a)student.tuwien.ac.at> wrote:
>
>> On Tue, 17 Jul 2012 19:39:31 -0400
>> William Speirs <wspeirs(a)apache.org> wrote:
>>
>> > I tried a flashrom -r and compared it to the backup I made and it's
>> > different. It is also different from the ROM I tried to install.
>> >
>> > Any thoughts?
>>
>> Most importantly: dont reboot or shutdown that computer. (we really
>> mean it... but some users do it anyway, and brick their boards that
>> way)
>>
>> i would try writing the backup image again to get to a safe state
>> again. the reason why it failed in the first place is not obvious to
>> me, but it is 2:00 AM here, so i might be overlooking something.
>> --
>> Kind regards/Mit freundlichen Grüßen, Stefan Tauner
>>
>
A non-text attachment has been stripped: M2N_0902.ROM
It is available at http://paste.flashrom.org/view.php?id05
[View Less]