ENE KB9012QF A3 reflash help needed
Hi! I'm trying to flash an ENE KB9012QF A3 KBC on LA-8241P motherboard. The problem is flashrom can't detect the internal SPI of it, fails with error. flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) flashrom is free software, get the source code at https://flashrom.org flashrom was built with libpci 3.5.2, GCC 7.3.0, little endian Command line (5 args): ./flashrom -p rayer_spi -c KB9012 (EDI) -V Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). Initializing rayer_spi programmer Using address 0x378 as I/O base for parallel port access. Using RayeR SPIPGM pinout. The following protocols are supported: SPI. Probing for ENE KB9012 (EDI), 128 kB: edi_chip_probe: reading hwversion failed No EEPROM/flash device found. Note: flashrom can never write if the flash chip isn't found automatically. How to get it working? Thanks a lot for help!
Hi Nyulos, Have you tried following the KB9012 flashing instructions at DangerousPrototypes wiki? http://dangerousprototypes.com/docs/Flashing_KB9012_with_Bus_Pirate Although that is for Bus Pirate / CH341A programmers and LA-A091P, should be similar for your Rayer programmer and LA-8241P motherboard. Most importantly, before plugging the power adapter you should unite three grounds: 1) GND of laptop's motherboard 2) GND of your programmer 3) GND of KB9012 Best regards, Mike Banon On Tue, Jan 8, 2019 at 3:30 PM Nyúlós Lónyál <udpsendtofailed@gmail.com> wrote:
Hi!
I'm trying to flash an ENE KB9012QF A3 KBC on LA-8241P motherboard. The problem is flashrom can't detect the internal SPI of it, fails with error.
flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) flashrom is free software, get the source code at https://flashrom.org
flashrom was built with libpci 3.5.2, GCC 7.3.0, little endian Command line (5 args): ./flashrom -p rayer_spi -c KB9012 (EDI) -V Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). Initializing rayer_spi programmer Using address 0x378 as I/O base for parallel port access. Using RayeR SPIPGM pinout. The following protocols are supported: SPI. Probing for ENE KB9012 (EDI), 128 kB: edi_chip_probe: reading hwversion failed No EEPROM/flash device found. Note: flashrom can never write if the flash chip isn't found automatically.
How to get it working? Thanks a lot for help! _______________________________________________ flashrom mailing list -- flashrom@flashrom.org To unsubscribe send an email to flashrom-leave@flashrom.org
Mike Banon wrote on 1/8/19 3:08 PM:
Hi Nyulos, Have you tried following the KB9012 flashing instructions at DangerousPrototypes wiki? http://dangerousprototypes.com/docs/Flashing_KB9012_with_Bus_Pirate Although that is for Bus Pirate / CH341A programmers and LA-A091P, should be similar for your Rayer programmer and LA-8241P motherboard. Most importantly, before plugging the power adapter you should unite three grounds: 1) GND of laptop's motherboard 2) GND of your programmer 3) GND of KB9012 Best regards, Mike Banon
On Tue, Jan 8, 2019 at 3:30 PM Nyúlós Lónyál <udpsendtofailed@gmail.com> wrote:
Hi!
I'm trying to flash an ENE KB9012QF A3 KBC on LA-8241P motherboard. The problem is flashrom can't detect the internal SPI of it, fails with error.
flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) flashrom is free software, get the source code at https://flashrom.org
flashrom was built with libpci 3.5.2, GCC 7.3.0, little endian Command line (5 args): ./flashrom -p rayer_spi -c KB9012 (EDI) -V Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). Initializing rayer_spi programmer Using address 0x378 as I/O base for parallel port access. Using RayeR SPIPGM pinout. The following protocols are supported: SPI. Probing for ENE KB9012 (EDI), 128 kB: edi_chip_probe: reading hwversion failed No EEPROM/flash device found. Note: flashrom can never write if the flash chip isn't found automatically.
How to get it working? Thanks a lot for help!
I think he's trying to use an internal SPI (maybe he should try "-p internal_spi" instead of "-p rayer_spi"?), so tying grounds probably won't help for that? He might have to use an external programmer instead, so he'd want to tie grounds then!
This rayer_spi is "RayeR parallel port programmer" which is external. Internal flashing will not work until someone will reverse engineer the proprietary UEFI update mechanism part of updating EC firmware. P.S. Meanwhile I'm contributing various patches to coreboot, although they are not discrete GPU-related yet (sorry I'm such a slowpoke!) you may want to take a look, e.g. some of them are for ACPI S3 inspired by HJK https://review.coreboot.org/q/mikeb+mikeb On Wed, Jan 9, 2019 at 12:45 AM awokd via flashrom <flashrom@flashrom.org> wrote:
Mike Banon wrote on 1/8/19 3:08 PM:
Hi Nyulos, Have you tried following the KB9012 flashing instructions at DangerousPrototypes wiki? http://dangerousprototypes.com/docs/Flashing_KB9012_with_Bus_Pirate Although that is for Bus Pirate / CH341A programmers and LA-A091P, should be similar for your Rayer programmer and LA-8241P motherboard. Most importantly, before plugging the power adapter you should unite three grounds: 1) GND of laptop's motherboard 2) GND of your programmer 3) GND of KB9012 Best regards, Mike Banon
On Tue, Jan 8, 2019 at 3:30 PM Nyúlós Lónyál <udpsendtofailed@gmail.com> wrote:
Hi!
I'm trying to flash an ENE KB9012QF A3 KBC on LA-8241P motherboard. The problem is flashrom can't detect the internal SPI of it, fails with error.
flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) flashrom is free software, get the source code at https://flashrom.org
flashrom was built with libpci 3.5.2, GCC 7.3.0, little endian Command line (5 args): ./flashrom -p rayer_spi -c KB9012 (EDI) -V Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). Initializing rayer_spi programmer Using address 0x378 as I/O base for parallel port access. Using RayeR SPIPGM pinout. The following protocols are supported: SPI. Probing for ENE KB9012 (EDI), 128 kB: edi_chip_probe: reading hwversion failed No EEPROM/flash device found. Note: flashrom can never write if the flash chip isn't found automatically.
How to get it working? Thanks a lot for help!
I think he's trying to use an internal SPI (maybe he should try "-p internal_spi" instead of "-p rayer_spi"?), so tying grounds probably won't help for that? He might have to use an external programmer instead, so he'd want to tie grounds then!
_______________________________________________ flashrom mailing list -- flashrom@flashrom.org To unsubscribe send an email to flashrom-leave@flashrom.org
Hi Mike! I've followed the linked guide, it gave me these results. The grounds are united, still the same error happens. I have tried to GND pin 42 of KB9012 as mentioned in the guide, and tried to connect both pin 41 and 42 to GND, as in KBC's datasheet at EDI related part, still no success, flashrom doesn't detect it. Mike Banon <mikebdp2@gmail.com> ezt írta (időpont: 2019. jan. 8., K, 16:08):
Hi Nyulos, Have you tried following the KB9012 flashing instructions at DangerousPrototypes wiki? http://dangerousprototypes.com/docs/Flashing_KB9012_with_Bus_Pirate Although that is for Bus Pirate / CH341A programmers and LA-A091P, should be similar for your Rayer programmer and LA-8241P motherboard. Most importantly, before plugging the power adapter you should unite three grounds: 1) GND of laptop's motherboard 2) GND of your programmer 3) GND of KB9012 Best regards, Mike Banon
On Tue, Jan 8, 2019 at 3:30 PM Nyúlós Lónyál <udpsendtofailed@gmail.com> wrote:
Hi!
I'm trying to flash an ENE KB9012QF A3 KBC on LA-8241P motherboard. The
problem is flashrom can't detect the internal SPI of it, fails with error.
flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) flashrom is free software, get the source code at https://flashrom.org
flashrom was built with libpci 3.5.2, GCC 7.3.0, little endian Command line (5 args): ./flashrom -p rayer_spi -c KB9012 (EDI) -V Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). Initializing rayer_spi programmer Using address 0x378 as I/O base for parallel port access. Using RayeR SPIPGM pinout. The following protocols are supported: SPI. Probing for ENE KB9012 (EDI), 128 kB: edi_chip_probe: reading hwversion
failed
No EEPROM/flash device found. Note: flashrom can never write if the flash chip isn't found automatically.
How to get it working? Thanks a lot for help! _______________________________________________ flashrom mailing list -- flashrom@flashrom.org To unsubscribe send an email to flashrom-leave@flashrom.org
Just to double-check: please discharge the motherboard completely by trying to turn it on while there is no power adapter connected, then unite three grounds (KB9012 / programmer / motherboard ) and only then connect the board's power adapter . After doing all that, please check if you could read it now. Also, what if your issues are programmer related? Is it possible for you to try another programmer, like CH341A ? (because it costs like $2-$3 with free shipping from china, just prefer to get a green PCB version because there were some 3.3/5V issues with some black PCB CH341A , and blue PCB version costs the same low price while having fewer pins) Or maybe you could get it locally for a (hopefully) small premium if you're in hurry On Wed, Jan 9, 2019 at 3:20 PM Nyúlós Lónyál <udpsendtofailed@gmail.com> wrote:
Hi Mike!
I've followed the linked guide, it gave me these results. The grounds are united, still the same error happens. I have tried to GND pin 42 of KB9012 as mentioned in the guide, and tried to connect both pin 41 and 42 to GND, as in KBC's datasheet at EDI related part, still no success, flashrom doesn't detect it.
Mike Banon <mikebdp2@gmail.com> ezt írta (időpont: 2019. jan. 8., K, 16:08):
Hi Nyulos, Have you tried following the KB9012 flashing instructions at DangerousPrototypes wiki? http://dangerousprototypes.com/docs/Flashing_KB9012_with_Bus_Pirate Although that is for Bus Pirate / CH341A programmers and LA-A091P, should be similar for your Rayer programmer and LA-8241P motherboard. Most importantly, before plugging the power adapter you should unite three grounds: 1) GND of laptop's motherboard 2) GND of your programmer 3) GND of KB9012 Best regards, Mike Banon
On Tue, Jan 8, 2019 at 3:30 PM Nyúlós Lónyál <udpsendtofailed@gmail.com> wrote:
Hi!
I'm trying to flash an ENE KB9012QF A3 KBC on LA-8241P motherboard. The problem is flashrom can't detect the internal SPI of it, fails with error.
flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) flashrom is free software, get the source code at https://flashrom.org
flashrom was built with libpci 3.5.2, GCC 7.3.0, little endian Command line (5 args): ./flashrom -p rayer_spi -c KB9012 (EDI) -V Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). Initializing rayer_spi programmer Using address 0x378 as I/O base for parallel port access. Using RayeR SPIPGM pinout. The following protocols are supported: SPI. Probing for ENE KB9012 (EDI), 128 kB: edi_chip_probe: reading hwversion failed No EEPROM/flash device found. Note: flashrom can never write if the flash chip isn't found automatically.
How to get it working? Thanks a lot for help! _______________________________________________ flashrom mailing list -- flashrom@flashrom.org To unsubscribe send an email to flashrom-leave@flashrom.org
Yea, tried to discharge the motherboard, taken out CMOS battery too, it didn't help. I don't know if this is programmer related or not, I have reflashed 2 types of BIOS SPI chips with it, EN25QH16 and W25Q32BV. But these chips are maybe different from KB9012's debug interface. I can't get a CH341A for now, maybe some months later. It would be good to recover the laptop if it's possible with the tools I have currently, but not very urgent. Here is the programmer's config, if it helps: https://github.com/flashrom/flashrom/blob/master/rayer_spi.c Mike Banon <mikebdp2@gmail.com> ezt írta (időpont: 2019. jan. 9., Sze, 18:59):
Just to double-check: please discharge the motherboard completely by trying to turn it on while there is no power adapter connected, then unite three grounds (KB9012 / programmer / motherboard ) and only then connect the board's power adapter . After doing all that, please check if you could read it now. Also, what if your issues are programmer related? Is it possible for you to try another programmer, like CH341A ? (because it costs like $2-$3 with free shipping from china, just prefer to get a green PCB version because there were some 3.3/5V issues with some black PCB CH341A , and blue PCB version costs the same low price while having fewer pins) Or maybe you could get it locally for a (hopefully) small premium if you're in hurry
On Wed, Jan 9, 2019 at 3:20 PM Nyúlós Lónyál <udpsendtofailed@gmail.com> wrote:
Hi Mike!
I've followed the linked guide, it gave me these results. The grounds
are united, still the same error happens. I have tried to GND pin 42 of KB9012 as mentioned in the guide, and tried to connect both pin 41 and 42 to GND, as in KBC's datasheet at EDI related part, still no success, flashrom doesn't detect it.
Mike Banon <mikebdp2@gmail.com> ezt írta (időpont: 2019. jan. 8., K,
16:08):
Hi Nyulos, Have you tried following the KB9012 flashing instructions at DangerousPrototypes wiki? http://dangerousprototypes.com/docs/Flashing_KB9012_with_Bus_Pirate Although that is for Bus Pirate / CH341A programmers and LA-A091P, should be similar for your Rayer programmer and LA-8241P motherboard. Most importantly, before plugging the power adapter you should unite three grounds: 1) GND of laptop's motherboard 2) GND of your programmer 3) GND of KB9012 Best regards, Mike Banon
On Tue, Jan 8, 2019 at 3:30 PM Nyúlós Lónyál <udpsendtofailed@gmail.com>
wrote:
Hi!
I'm trying to flash an ENE KB9012QF A3 KBC on LA-8241P motherboard.
The problem is flashrom can't detect the internal SPI of it, fails with error.
flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) flashrom is free software, get the source code at
flashrom was built with libpci 3.5.2, GCC 7.3.0, little endian Command line (5 args): ./flashrom -p rayer_spi -c KB9012 (EDI) -V Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). Initializing rayer_spi programmer Using address 0x378 as I/O base for parallel port access. Using RayeR SPIPGM pinout. The following protocols are supported: SPI. Probing for ENE KB9012 (EDI), 128 kB: edi_chip_probe: reading
hwversion failed
No EEPROM/flash device found. Note: flashrom can never write if the flash chip isn't found automatically.
How to get it working? Thanks a lot for help! _______________________________________________ flashrom mailing list -- flashrom@flashrom.org To unsubscribe send an email to flashrom-leave@flashrom.org
Finally managed it to detect KBC's internal flash using the motherboard's BIOS socket with removing it's SPI chip after boot, and connecting KB9012 in there. But the read always gives me different files, so I can't backup the current content of KB9012. *xubuntu@xubuntu:~/flashrom$ sudo ./flashrom -p internal -c "KB9012 (EDI)" -r /home/xubuntu/Desktop/ene1.binflashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64)flashrom is free software, get the source code at https://flashrom.org <https://flashrom.org>Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns).Found chipset "Intel ICH7/ICH7R".Enabling flash write... OK.edi_read: Retrying read with greater buffer length!edi_read: Retrying read with greater buffer length!Found ENE flash chip "KB9012 (EDI)" (128 kB, SPI) mapped at physical address 0x00000000fffe0000.Reading flash... done.xubuntu@xubuntu:~/flashrom$ sudo ./flashrom -p internal -c "KB9012 (EDI)" -v /home/xubuntu/Desktop/ene1.binflashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64)flashrom is free software, get the source code at https://flashrom.org <https://flashrom.org>Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns).Found chipset "Intel ICH7/ICH7R".Enabling flash write... OK.edi_read: Retrying read with greater buffer length!edi_read: Retrying read with greater buffer length!Found ENE flash chip "KB9012 (EDI)" (128 kB, SPI) mapped at physical address 0x00000000fffe0000.Verifying flash... FAILED at 0x000034c2! Expected=0xff, Found=0x78, failed byte count from 0x00000000-0x0001ffff: 0x6c52* Nyúlós Lónyál <udpsendtofailed@gmail.com> ezt írta (időpont: 2019. jan. 10., Cs, 12:14):
Yea, tried to discharge the motherboard, taken out CMOS battery too, it didn't help. I don't know if this is programmer related or not, I have reflashed 2 types of BIOS SPI chips with it, EN25QH16 and W25Q32BV. But these chips are maybe different from KB9012's debug interface. I can't get a CH341A for now, maybe some months later. It would be good to recover the laptop if it's possible with the tools I have currently, but not very urgent. Here is the programmer's config, if it helps: https://github.com/flashrom/flashrom/blob/master/rayer_spi.c
Mike Banon <mikebdp2@gmail.com> ezt írta (időpont: 2019. jan. 9., Sze, 18:59):
Just to double-check: please discharge the motherboard completely by trying to turn it on while there is no power adapter connected, then unite three grounds (KB9012 / programmer / motherboard ) and only then connect the board's power adapter . After doing all that, please check if you could read it now. Also, what if your issues are programmer related? Is it possible for you to try another programmer, like CH341A ? (because it costs like $2-$3 with free shipping from china, just prefer to get a green PCB version because there were some 3.3/5V issues with some black PCB CH341A , and blue PCB version costs the same low price while having fewer pins) Or maybe you could get it locally for a (hopefully) small premium if you're in hurry
On Wed, Jan 9, 2019 at 3:20 PM Nyúlós Lónyál <udpsendtofailed@gmail.com> wrote:
Hi Mike!
I've followed the linked guide, it gave me these results. The grounds
are united, still the same error happens. I have tried to GND pin 42 of KB9012 as mentioned in the guide, and tried to connect both pin 41 and 42 to GND, as in KBC's datasheet at EDI related part, still no success, flashrom doesn't detect it.
Mike Banon <mikebdp2@gmail.com> ezt írta (időpont: 2019. jan. 8., K,
16:08):
Hi Nyulos, Have you tried following the KB9012 flashing instructions at DangerousPrototypes wiki? http://dangerousprototypes.com/docs/Flashing_KB9012_with_Bus_Pirate Although that is for Bus Pirate / CH341A programmers and LA-A091P, should be similar for your Rayer programmer and LA-8241P motherboard. Most importantly, before plugging the power adapter you should unite three grounds: 1) GND of laptop's motherboard 2) GND of your programmer 3) GND of KB9012 Best regards, Mike Banon
On Tue, Jan 8, 2019 at 3:30 PM Nyúlós Lónyál <
udpsendtofailed@gmail.com> wrote:
Hi!
I'm trying to flash an ENE KB9012QF A3 KBC on LA-8241P motherboard.
The problem is flashrom can't detect the internal SPI of it, fails with error.
flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) flashrom is free software, get the source code at
flashrom was built with libpci 3.5.2, GCC 7.3.0, little endian Command line (5 args): ./flashrom -p rayer_spi -c KB9012 (EDI) -V Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). Initializing rayer_spi programmer Using address 0x378 as I/O base for parallel port access. Using RayeR SPIPGM pinout. The following protocols are supported: SPI. Probing for ENE KB9012 (EDI), 128 kB: edi_chip_probe: reading
hwversion failed
No EEPROM/flash device found. Note: flashrom can never write if the flash chip isn't found automatically.
How to get it working? Thanks a lot for help! _______________________________________________ flashrom mailing list -- flashrom@flashrom.org To unsubscribe send an email to flashrom-leave@flashrom.org
Sorry for double mail. Erasing and writing fails too. *xubuntu@xubuntu:~/flashrom$ sudo ./flashrom -p internal -c "KB9012 (EDI)" -w /home/xubuntu/Desktop/EC-FD-Extract.bin flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64)flashrom is free software, get the source code at https://flashrom.org <https://flashrom.org>Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns).Found chipset "Intel ICH7/ICH7R".Enabling flash write... OK.edi_read: Retrying read with greater buffer length!edi_read: Retrying read with greater buffer length!Found ENE flash chip "KB9012 (EDI)" (128 kB, SPI) mapped at physical address 0x00000000fffe0000.Reading old flash chip contents... done.Erasing and writing flash chip... edi_chip_block_erase: Timed out waiting for SPI not busy!Reading current flash chip contents... done. Looking for another erase function.Looking for another erase function.Looking for another erase function.Looking for another erase function.Looking for another erase function.Looking for another erase function.Looking for another erase function.No usable erase functions left.FAILED!Uh oh. Erase/write failed. Checking if anything has changed.Reading current flash chip contents... done.Apparently at least some data has changed.Your flash chip is in an unknown state.Get help on IRC at chat.freenode.net <http://chat.freenode.net> (channel #flashrom) ormail flashrom@flashrom.org <flashrom@flashrom.org> with the subject "FAILED: <your board name>"!-------------------------------------------------------------------------------DO NOT REBOOT OR POWEROFF!* *xubuntu@xubuntu:~/flashrom$ sudo ./flashrom -p internal -c "KB9012 (EDI)" -E flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64)flashrom is free software, get the source code at https://flashrom.org <https://flashrom.org>Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns).Found chipset "Intel ICH7/ICH7R".Enabling flash write... OK.edi_read: Retrying read with greater buffer length!edi_read: Retrying read with greater buffer length!Found ENE flash chip "KB9012 (EDI)" (128 kB, SPI) mapped at physical address 0x00000000fffe0000.Erasing and writing flash chip... edi_chip_block_erase: Timed out waiting for SPI not busy!Looking for another erase function.Looking for another erase function.Looking for another erase function.Looking for another erase function.Looking for another erase function.Looking for another erase function.Looking for another erase function.No usable erase functions left.FAILED!Your flash chip is in an unknown state.Get help on IRC at chat.freenode.net <http://chat.freenode.net> (channel #flashrom) ormail flashrom@flashrom.org <flashrom@flashrom.org> with the subject "FAILED: <your board name>"!-------------------------------------------------------------------------------DO NOT REBOOT OR POWEROFF!* Nyúlós Lónyál <udpsendtofailed@gmail.com> ezt írta (időpont: 2019. jan. 11., P, 13:49):
Finally managed it to detect KBC's internal flash using the motherboard's BIOS socket with removing it's SPI chip after boot, and connecting KB9012 in there. But the read always gives me different files, so I can't backup the current content of KB9012.
*xubuntu@xubuntu:~/flashrom$ sudo ./flashrom -p internal -c "KB9012 (EDI)" -r /home/xubuntu/Desktop/ene1.binflashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64)flashrom is free software, get the source code at https://flashrom.org <https://flashrom.org>Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns).Found chipset "Intel ICH7/ICH7R".Enabling flash write... OK.edi_read: Retrying read with greater buffer length!edi_read: Retrying read with greater buffer length!Found ENE flash chip "KB9012 (EDI)" (128 kB, SPI) mapped at physical address 0x00000000fffe0000.Reading flash... done.xubuntu@xubuntu:~/flashrom$ sudo ./flashrom -p internal -c "KB9012 (EDI)" -v /home/xubuntu/Desktop/ene1.binflashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64)flashrom is free software, get the source code at https://flashrom.org <https://flashrom.org>Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns).Found chipset "Intel ICH7/ICH7R".Enabling flash write... OK.edi_read: Retrying read with greater buffer length!edi_read: Retrying read with greater buffer length!Found ENE flash chip "KB9012 (EDI)" (128 kB, SPI) mapped at physical address 0x00000000fffe0000.Verifying flash... FAILED at 0x000034c2! Expected=0xff, Found=0x78, failed byte count from 0x00000000-0x0001ffff: 0x6c52*
Nyúlós Lónyál <udpsendtofailed@gmail.com> ezt írta (időpont: 2019. jan. 10., Cs, 12:14):
Yea, tried to discharge the motherboard, taken out CMOS battery too, it didn't help. I don't know if this is programmer related or not, I have reflashed 2 types of BIOS SPI chips with it, EN25QH16 and W25Q32BV. But these chips are maybe different from KB9012's debug interface. I can't get a CH341A for now, maybe some months later. It would be good to recover the laptop if it's possible with the tools I have currently, but not very urgent. Here is the programmer's config, if it helps: https://github.com/flashrom/flashrom/blob/master/rayer_spi.c
Mike Banon <mikebdp2@gmail.com> ezt írta (időpont: 2019. jan. 9., Sze, 18:59):
Just to double-check: please discharge the motherboard completely by trying to turn it on while there is no power adapter connected, then unite three grounds (KB9012 / programmer / motherboard ) and only then connect the board's power adapter . After doing all that, please check if you could read it now. Also, what if your issues are programmer related? Is it possible for you to try another programmer, like CH341A ? (because it costs like $2-$3 with free shipping from china, just prefer to get a green PCB version because there were some 3.3/5V issues with some black PCB CH341A , and blue PCB version costs the same low price while having fewer pins) Or maybe you could get it locally for a (hopefully) small premium if you're in hurry
On Wed, Jan 9, 2019 at 3:20 PM Nyúlós Lónyál <udpsendtofailed@gmail.com> wrote:
Hi Mike!
I've followed the linked guide, it gave me these results. The grounds
are united, still the same error happens. I have tried to GND pin 42 of KB9012 as mentioned in the guide, and tried to connect both pin 41 and 42 to GND, as in KBC's datasheet at EDI related part, still no success, flashrom doesn't detect it.
Mike Banon <mikebdp2@gmail.com> ezt írta (időpont: 2019. jan. 8., K,
16:08):
Hi Nyulos, Have you tried following the KB9012 flashing instructions at DangerousPrototypes wiki? http://dangerousprototypes.com/docs/Flashing_KB9012_with_Bus_Pirate Although that is for Bus Pirate / CH341A programmers and LA-A091P, should be similar for your Rayer programmer and LA-8241P motherboard. Most importantly, before plugging the power adapter you should unite three grounds: 1) GND of laptop's motherboard 2) GND of your programmer 3) GND of KB9012 Best regards, Mike Banon
On Tue, Jan 8, 2019 at 3:30 PM Nyúlós Lónyál <
udpsendtofailed@gmail.com> wrote:
Hi!
I'm trying to flash an ENE KB9012QF A3 KBC on LA-8241P motherboard.
The problem is flashrom can't detect the internal SPI of it, fails with error.
flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) flashrom is free software, get the source code at
flashrom was built with libpci 3.5.2, GCC 7.3.0, little endian Command line (5 args): ./flashrom -p rayer_spi -c KB9012 (EDI) -V Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). Initializing rayer_spi programmer Using address 0x378 as I/O base for parallel port access. Using RayeR SPIPGM pinout. The following protocols are supported: SPI. Probing for ENE KB9012 (EDI), 128 kB: edi_chip_probe: reading
hwversion failed
No EEPROM/flash device found. Note: flashrom can never write if the flash chip isn't found automatically.
How to get it working? Thanks a lot for help! _______________________________________________ flashrom mailing list -- flashrom@flashrom.org To unsubscribe send an email to flashrom-leave@flashrom.org
That is because KB9012 is active after your laptop has booted and not in debug state where it is possible to reflash it without a problem. Have you double checked your laptop's datasheet to make sure your connection is correct, and also that your laptop's corner ground is really connected to its' ground? (what if not all its' copper circles are the grounds in your case) On Fri, Jan 11, 2019 at 5:01 PM Nyúlós Lónyál <udpsendtofailed@gmail.com> wrote:
Sorry for double mail. Erasing and writing fails too.
xubuntu@xubuntu:~/flashrom$ sudo ./flashrom -p internal -c "KB9012 (EDI)" -w /home/xubuntu/Desktop/EC-FD-Extract.bin flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) flashrom is free software, get the source code at https://flashrom.org
Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). Found chipset "Intel ICH7/ICH7R". Enabling flash write... OK. edi_read: Retrying read with greater buffer length! edi_read: Retrying read with greater buffer length! Found ENE flash chip "KB9012 (EDI)" (128 kB, SPI) mapped at physical address 0x00000000fffe0000. Reading old flash chip contents... done. Erasing and writing flash chip... edi_chip_block_erase: Timed out waiting for SPI not busy! Reading current flash chip contents... done. Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. No usable erase functions left. FAILED! Uh oh. Erase/write failed. Checking if anything has changed. Reading current flash chip contents... done. Apparently at least some data has changed. Your flash chip is in an unknown state. Get help on IRC at chat.freenode.net (channel #flashrom) or mail flashrom@flashrom.org with the subject "FAILED: <your board name>"! ------------------------------------------------------------------------------- DO NOT REBOOT OR POWEROFF!
xubuntu@xubuntu:~/flashrom$ sudo ./flashrom -p internal -c "KB9012 (EDI)" -E flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) flashrom is free software, get the source code at https://flashrom.org
Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). Found chipset "Intel ICH7/ICH7R". Enabling flash write... OK. edi_read: Retrying read with greater buffer length! edi_read: Retrying read with greater buffer length! Found ENE flash chip "KB9012 (EDI)" (128 kB, SPI) mapped at physical address 0x00000000fffe0000. Erasing and writing flash chip... edi_chip_block_erase: Timed out waiting for SPI not busy! Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. No usable erase functions left. FAILED! Your flash chip is in an unknown state. Get help on IRC at chat.freenode.net (channel #flashrom) or mail flashrom@flashrom.org with the subject "FAILED: <your board name>"! ------------------------------------------------------------------------------- DO NOT REBOOT OR POWEROFF!
Nyúlós Lónyál <udpsendtofailed@gmail.com> ezt írta (időpont: 2019. jan. 11., P, 13:49):
Finally managed it to detect KBC's internal flash using the motherboard's BIOS socket with removing it's SPI chip after boot, and connecting KB9012 in there. But the read always gives me different files, so I can't backup the current content of KB9012.
xubuntu@xubuntu:~/flashrom$ sudo ./flashrom -p internal -c "KB9012 (EDI)" -r /home/xubuntu/Desktop/ene1.bin flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) flashrom is free software, get the source code at https://flashrom.org
Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). Found chipset "Intel ICH7/ICH7R". Enabling flash write... OK. edi_read: Retrying read with greater buffer length! edi_read: Retrying read with greater buffer length! Found ENE flash chip "KB9012 (EDI)" (128 kB, SPI) mapped at physical address 0x00000000fffe0000. Reading flash... done. xubuntu@xubuntu:~/flashrom$ sudo ./flashrom -p internal -c "KB9012 (EDI)" -v /home/xubuntu/Desktop/ene1.bin flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) flashrom is free software, get the source code at https://flashrom.org
Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). Found chipset "Intel ICH7/ICH7R". Enabling flash write... OK. edi_read: Retrying read with greater buffer length! edi_read: Retrying read with greater buffer length! Found ENE flash chip "KB9012 (EDI)" (128 kB, SPI) mapped at physical address 0x00000000fffe0000. Verifying flash... FAILED at 0x000034c2! Expected=0xff, Found=0x78, failed byte count from 0x00000000-0x0001ffff: 0x6c52
Nyúlós Lónyál <udpsendtofailed@gmail.com> ezt írta (időpont: 2019. jan. 10., Cs, 12:14):
Yea, tried to discharge the motherboard, taken out CMOS battery too, it didn't help. I don't know if this is programmer related or not, I have reflashed 2 types of BIOS SPI chips with it, EN25QH16 and W25Q32BV. But these chips are maybe different from KB9012's debug interface. I can't get a CH341A for now, maybe some months later. It would be good to recover the laptop if it's possible with the tools I have currently, but not very urgent. Here is the programmer's config, if it helps: https://github.com/flashrom/flashrom/blob/master/rayer_spi.c
Mike Banon <mikebdp2@gmail.com> ezt írta (időpont: 2019. jan. 9., Sze, 18:59):
Just to double-check: please discharge the motherboard completely by trying to turn it on while there is no power adapter connected, then unite three grounds (KB9012 / programmer / motherboard ) and only then connect the board's power adapter . After doing all that, please check if you could read it now. Also, what if your issues are programmer related? Is it possible for you to try another programmer, like CH341A ? (because it costs like $2-$3 with free shipping from china, just prefer to get a green PCB version because there were some 3.3/5V issues with some black PCB CH341A , and blue PCB version costs the same low price while having fewer pins) Or maybe you could get it locally for a (hopefully) small premium if you're in hurry
On Wed, Jan 9, 2019 at 3:20 PM Nyúlós Lónyál <udpsendtofailed@gmail.com> wrote:
Hi Mike!
I've followed the linked guide, it gave me these results. The grounds are united, still the same error happens. I have tried to GND pin 42 of KB9012 as mentioned in the guide, and tried to connect both pin 41 and 42 to GND, as in KBC's datasheet at EDI related part, still no success, flashrom doesn't detect it.
Mike Banon <mikebdp2@gmail.com> ezt írta (időpont: 2019. jan. 8., K, 16:08):
Hi Nyulos, Have you tried following the KB9012 flashing instructions at DangerousPrototypes wiki? http://dangerousprototypes.com/docs/Flashing_KB9012_with_Bus_Pirate Although that is for Bus Pirate / CH341A programmers and LA-A091P, should be similar for your Rayer programmer and LA-8241P motherboard. Most importantly, before plugging the power adapter you should unite three grounds: 1) GND of laptop's motherboard 2) GND of your programmer 3) GND of KB9012 Best regards, Mike Banon
On Tue, Jan 8, 2019 at 3:30 PM Nyúlós Lónyál <udpsendtofailed@gmail.com> wrote: > > Hi! > > I'm trying to flash an ENE KB9012QF A3 KBC on LA-8241P motherboard. The problem is flashrom can't detect the internal SPI of it, fails with error. > > flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) > flashrom is free software, get the source code at https://flashrom.org > > flashrom was built with libpci 3.5.2, GCC 7.3.0, little endian > Command line (5 args): ./flashrom -p rayer_spi -c KB9012 (EDI) -V > Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). > Initializing rayer_spi programmer > Using address 0x378 as I/O base for parallel port access. > Using RayeR SPIPGM pinout. > The following protocols are supported: SPI. > Probing for ENE KB9012 (EDI), 128 kB: edi_chip_probe: reading hwversion failed > No EEPROM/flash device found. > Note: flashrom can never write if the flash chip isn't found automatically. > > How to get it working? Thanks a lot for help! > _______________________________________________ > flashrom mailing list -- flashrom@flashrom.org > To unsubscribe send an email to flashrom-leave@flashrom.org
Sorry for the confusion. :( I think you have misunderstood me. My laptop's motherboard is taken out of the laptop. I have another machine, a desktop PC which I've used for trying rayer_spi programmer. Now I connect the laptop's KB9012's debug pins into the desktop PC motherboard's DIP8 BIOS socket with wires, after it booted the linux distribution with flashrom installed and removing it's original BIOS SPI chip. The two machine's GND, DIP8 socket's GND, and KB9012's pin 42 are united. Like when recovering a regular motherboard BIOS with hot-swapping chips, just the only difference I connect the laptop's KBC instead of another BIOS chip: https://www.coreboot.org/FAQ#Developers I think the desktop motherboard's BIOS socket can be used as an SPI programmer this way, originally it has W25Q80BVAIG DIP8 chip which can be removed. That gave me these results, read and write errors which I sent before, but at least it can detect KB9012. I've tested with the original BIOS chip, flashrom can read, erase, and write it. The motherboard is an Asrock G41C-GS first generation, rev 1.0.2. The laptop can't boot, doesn't even react to power button or recovery key combination, and no charging LED lighting up, since it got bricked with a wrong BIOS update, this is why I want to reflash KB9012 with an external tool, like the desktop PC motherboard's DIP8 socket. Mike Banon <mikebdp2@gmail.com> ezt írta (időpont: 2019. jan. 14., H, 22:43):
That is because KB9012 is active after your laptop has booted and not in debug state where it is possible to reflash it without a problem.
Have you double checked your laptop's datasheet to make sure your connection is correct, and also that your laptop's corner ground is really connected to its' ground? (what if not all its' copper circles are the grounds in your case)
On Fri, Jan 11, 2019 at 5:01 PM Nyúlós Lónyál <udpsendtofailed@gmail.com> wrote:
Sorry for double mail. Erasing and writing fails too.
xubuntu@xubuntu:~/flashrom$ sudo ./flashrom -p internal -c "KB9012
(EDI)" -w /home/xubuntu/Desktop/EC-FD-Extract.bin
flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) flashrom is free software, get the source code at https://flashrom.org
Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). Found chipset "Intel ICH7/ICH7R". Enabling flash write... OK. edi_read: Retrying read with greater buffer length! edi_read: Retrying read with greater buffer length! Found ENE flash chip "KB9012 (EDI)" (128 kB, SPI) mapped at physical address 0x00000000fffe0000. Reading old flash chip contents... done. Erasing and writing flash chip... edi_chip_block_erase: Timed out waiting for SPI not busy! Reading current flash chip contents... done. Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. No usable erase functions left. FAILED! Uh oh. Erase/write failed. Checking if anything has changed. Reading current flash chip contents... done. Apparently at least some data has changed. Your flash chip is in an unknown state. Get help on IRC at chat.freenode.net (channel #flashrom) or mail flashrom@flashrom.org with the subject "FAILED: <your board name>"!
-------------------------------------------------------------------------------
DO NOT REBOOT OR POWEROFF!
xubuntu@xubuntu:~/flashrom$ sudo ./flashrom -p internal -c "KB9012 (EDI)" -E flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) flashrom is free software, get the source code at https://flashrom.org
Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). Found chipset "Intel ICH7/ICH7R". Enabling flash write... OK. edi_read: Retrying read with greater buffer length! edi_read: Retrying read with greater buffer length! Found ENE flash chip "KB9012 (EDI)" (128 kB, SPI) mapped at physical address 0x00000000fffe0000. Erasing and writing flash chip... edi_chip_block_erase: Timed out waiting for SPI not busy! Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. No usable erase functions left. FAILED! Your flash chip is in an unknown state. Get help on IRC at chat.freenode.net (channel #flashrom) or mail flashrom@flashrom.org with the subject "FAILED: <your board name>"!
-------------------------------------------------------------------------------
DO NOT REBOOT OR POWEROFF!
Nyúlós Lónyál <udpsendtofailed@gmail.com> ezt írta (időpont: 2019. jan. 11., P, 13:49):
Finally managed it to detect KBC's internal flash using the
motherboard's BIOS socket with removing it's SPI chip after boot, and connecting KB9012 in there. But the read always gives me different files, so I can't backup the current content of KB9012.
xubuntu@xubuntu:~/flashrom$ sudo ./flashrom -p internal -c "KB9012
(EDI)" -r /home/xubuntu/Desktop/ene1.bin
flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) flashrom is free software, get the source code at https://flashrom.org
Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). Found chipset "Intel ICH7/ICH7R". Enabling flash write... OK. edi_read: Retrying read with greater buffer length! edi_read: Retrying read with greater buffer length! Found ENE flash chip "KB9012 (EDI)" (128 kB, SPI) mapped at physical address 0x00000000fffe0000. Reading flash... done. xubuntu@xubuntu:~/flashrom$ sudo ./flashrom -p internal -c "KB9012 (EDI)" -v /home/xubuntu/Desktop/ene1.bin flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) flashrom is free software, get the source code at https://flashrom.org
Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). Found chipset "Intel ICH7/ICH7R". Enabling flash write... OK. edi_read: Retrying read with greater buffer length! edi_read: Retrying read with greater buffer length! Found ENE flash chip "KB9012 (EDI)" (128 kB, SPI) mapped at physical address 0x00000000fffe0000. Verifying flash... FAILED at 0x000034c2! Expected=0xff, Found=0x78, failed byte count from 0x00000000-0x0001ffff: 0x6c52
Nyúlós Lónyál <udpsendtofailed@gmail.com> ezt írta (időpont: 2019. jan. 10., Cs, 12:14):
Yea, tried to discharge the motherboard, taken out CMOS battery too,
it didn't help. I don't know if this is programmer related or not, I have reflashed 2 types of BIOS SPI chips with it, EN25QH16 and W25Q32BV. But these chips are maybe different from KB9012's debug interface. I can't get a CH341A for now, maybe some months later. It would be good to recover the laptop if it's possible with the tools I have currently, but not very urgent. Here is the programmer's config, if it helps: https://github.com/flashrom/flashrom/blob/master/rayer_spi.c
Mike Banon <mikebdp2@gmail.com> ezt írta (időpont: 2019. jan. 9.,
Sze, 18:59):
Just to double-check: please discharge the motherboard completely by trying to turn it on while there is no power adapter connected, then unite three grounds (KB9012 / programmer / motherboard ) and only then connect the board's power adapter . After doing all that, please check if you could read it now. Also, what if your issues are programmer related? Is it possible for you to try another programmer, like CH341A ? (because it costs like $2-$3 with free shipping from china, just prefer to get a green PCB version because there were some 3.3/5V issues with some black PCB CH341A , and blue PCB version costs the same low price while having fewer pins) Or maybe you could get it locally for a (hopefully) small premium if you're in hurry
On Wed, Jan 9, 2019 at 3:20 PM Nyúlós Lónyál <
udpsendtofailed@gmail.com> wrote:
Hi Mike!
I've followed the linked guide, it gave me these results. The
grounds are united, still the same error happens. I have tried to GND pin 42 of KB9012 as mentioned in the guide, and tried to connect both pin 41 and 42 to GND, as in KBC's datasheet at EDI related part, still no success, flashrom doesn't detect it.
Mike Banon <mikebdp2@gmail.com> ezt írta (időpont: 2019. jan. 8.,
K, 16:08):
> > Hi Nyulos, > Have you tried following the KB9012 flashing instructions at > DangerousPrototypes wiki? > http://dangerousprototypes.com/docs/Flashing_KB9012_with_Bus_Pirate > Although that is for Bus Pirate / CH341A programmers and LA-A091P, > should be similar for your Rayer programmer and LA-8241P motherboard. > Most importantly, before plugging the power adapter you should unite > three grounds: > 1) GND of laptop's motherboard > 2) GND of your programmer > 3) GND of KB9012 > Best regards, > Mike Banon > > On Tue, Jan 8, 2019 at 3:30 PM Nyúlós Lónyál < udpsendtofailed@gmail.com> wrote: > > > > Hi! > > > > I'm trying to flash an ENE KB9012QF A3 KBC on LA-8241P motherboard. The problem is flashrom can't detect the internal SPI of it, fails with error. > > > > flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) > > flashrom is free software, get the source code at https://flashrom.org > > > > flashrom was built with libpci 3.5.2, GCC 7.3.0, little endian > > Command line (5 args): ./flashrom -p rayer_spi -c KB9012 (EDI) -V > > Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). > > Initializing rayer_spi programmer > > Using address 0x378 as I/O base for parallel port access. > > Using RayeR SPIPGM pinout. > > The following protocols are supported: SPI. > > Probing for ENE KB9012 (EDI), 128 kB: edi_chip_probe: reading hwversion failed > > No EEPROM/flash device found. > > Note: flashrom can never write if the flash chip isn't found automatically. > > > > How to get it working? Thanks a lot for help! > > _______________________________________________ > > flashrom mailing list -- flashrom@flashrom.org > > To unsubscribe send an email to flashrom-leave@flashrom.org
Sorry if I've already asked this question, but how long are your wires? Ideally they should be about 10cm length and made of good copper. Although it could work even for 30cm poor aluminum wires, still when there are read/write errors - the first suggestion which comes to my mind is to shorten the wires. I understand that it could be difficult to use short wires at your flashing setup, but hope it is possible for you to try. And also I hope that you've ordered CH341A just in case our suggestions wouldn't work.
The laptop can't boot, doesn't even react to power button or recovery key combination, and no charging LED lighting up Everything from this list is expected if there is a corrupted KB9012 firmware, because it is KB9012 which listens for your power button keypresses / controls the LEDs / etc
On Tue, Jan 15, 2019 at 2:44 PM Nyúlós Lónyál <udpsendtofailed@gmail.com> wrote:
Sorry for the confusion. :( I think you have misunderstood me.
My laptop's motherboard is taken out of the laptop. I have another machine, a desktop PC which I've used for trying rayer_spi programmer. Now I connect the laptop's KB9012's debug pins into the desktop PC motherboard's DIP8 BIOS socket with wires, after it booted the linux distribution with flashrom installed and removing it's original BIOS SPI chip. The two machine's GND, DIP8 socket's GND, and KB9012's pin 42 are united.
Like when recovering a regular motherboard BIOS with hot-swapping chips, just the only difference I connect the laptop's KBC instead of another BIOS chip: https://www.coreboot.org/FAQ#Developers
I think the desktop motherboard's BIOS socket can be used as an SPI programmer this way, originally it has W25Q80BVAIG DIP8 chip which can be removed. That gave me these results, read and write errors which I sent before, but at least it can detect KB9012. I've tested with the original BIOS chip, flashrom can read, erase, and write it. The motherboard is an Asrock G41C-GS first generation, rev 1.0.2.
The laptop can't boot, doesn't even react to power button or recovery key combination, and no charging LED lighting up, since it got bricked with a wrong BIOS update, this is why I want to reflash KB9012 with an external tool, like the desktop PC motherboard's DIP8 socket.
Mike Banon <mikebdp2@gmail.com> ezt írta (időpont: 2019. jan. 14., H, 22:43):
That is because KB9012 is active after your laptop has booted and not in debug state where it is possible to reflash it without a problem.
Have you double checked your laptop's datasheet to make sure your connection is correct, and also that your laptop's corner ground is really connected to its' ground? (what if not all its' copper circles are the grounds in your case)
On Fri, Jan 11, 2019 at 5:01 PM Nyúlós Lónyál <udpsendtofailed@gmail.com> wrote:
Sorry for double mail. Erasing and writing fails too.
xubuntu@xubuntu:~/flashrom$ sudo ./flashrom -p internal -c "KB9012 (EDI)" -w /home/xubuntu/Desktop/EC-FD-Extract.bin flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) flashrom is free software, get the source code at https://flashrom.org
Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). Found chipset "Intel ICH7/ICH7R". Enabling flash write... OK. edi_read: Retrying read with greater buffer length! edi_read: Retrying read with greater buffer length! Found ENE flash chip "KB9012 (EDI)" (128 kB, SPI) mapped at physical address 0x00000000fffe0000. Reading old flash chip contents... done. Erasing and writing flash chip... edi_chip_block_erase: Timed out waiting for SPI not busy! Reading current flash chip contents... done. Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. No usable erase functions left. FAILED! Uh oh. Erase/write failed. Checking if anything has changed. Reading current flash chip contents... done. Apparently at least some data has changed. Your flash chip is in an unknown state. Get help on IRC at chat.freenode.net (channel #flashrom) or mail flashrom@flashrom.org with the subject "FAILED: <your board name>"! ------------------------------------------------------------------------------- DO NOT REBOOT OR POWEROFF!
xubuntu@xubuntu:~/flashrom$ sudo ./flashrom -p internal -c "KB9012 (EDI)" -E flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) flashrom is free software, get the source code at https://flashrom.org
Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). Found chipset "Intel ICH7/ICH7R". Enabling flash write... OK. edi_read: Retrying read with greater buffer length! edi_read: Retrying read with greater buffer length! Found ENE flash chip "KB9012 (EDI)" (128 kB, SPI) mapped at physical address 0x00000000fffe0000. Erasing and writing flash chip... edi_chip_block_erase: Timed out waiting for SPI not busy! Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. No usable erase functions left. FAILED! Your flash chip is in an unknown state. Get help on IRC at chat.freenode.net (channel #flashrom) or mail flashrom@flashrom.org with the subject "FAILED: <your board name>"! ------------------------------------------------------------------------------- DO NOT REBOOT OR POWEROFF!
Nyúlós Lónyál <udpsendtofailed@gmail.com> ezt írta (időpont: 2019. jan. 11., P, 13:49):
Finally managed it to detect KBC's internal flash using the motherboard's BIOS socket with removing it's SPI chip after boot, and connecting KB9012 in there. But the read always gives me different files, so I can't backup the current content of KB9012.
xubuntu@xubuntu:~/flashrom$ sudo ./flashrom -p internal -c "KB9012 (EDI)" -r /home/xubuntu/Desktop/ene1.bin flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) flashrom is free software, get the source code at https://flashrom.org
Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). Found chipset "Intel ICH7/ICH7R". Enabling flash write... OK. edi_read: Retrying read with greater buffer length! edi_read: Retrying read with greater buffer length! Found ENE flash chip "KB9012 (EDI)" (128 kB, SPI) mapped at physical address 0x00000000fffe0000. Reading flash... done. xubuntu@xubuntu:~/flashrom$ sudo ./flashrom -p internal -c "KB9012 (EDI)" -v /home/xubuntu/Desktop/ene1.bin flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) flashrom is free software, get the source code at https://flashrom.org
Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). Found chipset "Intel ICH7/ICH7R". Enabling flash write... OK. edi_read: Retrying read with greater buffer length! edi_read: Retrying read with greater buffer length! Found ENE flash chip "KB9012 (EDI)" (128 kB, SPI) mapped at physical address 0x00000000fffe0000. Verifying flash... FAILED at 0x000034c2! Expected=0xff, Found=0x78, failed byte count from 0x00000000-0x0001ffff: 0x6c52
Nyúlós Lónyál <udpsendtofailed@gmail.com> ezt írta (időpont: 2019. jan. 10., Cs, 12:14):
Yea, tried to discharge the motherboard, taken out CMOS battery too, it didn't help. I don't know if this is programmer related or not, I have reflashed 2 types of BIOS SPI chips with it, EN25QH16 and W25Q32BV. But these chips are maybe different from KB9012's debug interface. I can't get a CH341A for now, maybe some months later. It would be good to recover the laptop if it's possible with the tools I have currently, but not very urgent. Here is the programmer's config, if it helps: https://github.com/flashrom/flashrom/blob/master/rayer_spi.c
Mike Banon <mikebdp2@gmail.com> ezt írta (időpont: 2019. jan. 9., Sze, 18:59):
Just to double-check: please discharge the motherboard completely by trying to turn it on while there is no power adapter connected, then unite three grounds (KB9012 / programmer / motherboard ) and only then connect the board's power adapter . After doing all that, please check if you could read it now. Also, what if your issues are programmer related? Is it possible for you to try another programmer, like CH341A ? (because it costs like $2-$3 with free shipping from china, just prefer to get a green PCB version because there were some 3.3/5V issues with some black PCB CH341A , and blue PCB version costs the same low price while having fewer pins) Or maybe you could get it locally for a (hopefully) small premium if you're in hurry
On Wed, Jan 9, 2019 at 3:20 PM Nyúlós Lónyál <udpsendtofailed@gmail.com> wrote: > > Hi Mike! > > I've followed the linked guide, it gave me these results. The grounds are united, still the same error happens. I have tried to GND pin 42 of KB9012 as mentioned in the guide, and tried to connect both pin 41 and 42 to GND, as in KBC's datasheet at EDI related part, still no success, flashrom doesn't detect it. > > Mike Banon <mikebdp2@gmail.com> ezt írta (időpont: 2019. jan. 8., K, 16:08): >> >> Hi Nyulos, >> Have you tried following the KB9012 flashing instructions at >> DangerousPrototypes wiki? >> http://dangerousprototypes.com/docs/Flashing_KB9012_with_Bus_Pirate >> Although that is for Bus Pirate / CH341A programmers and LA-A091P, >> should be similar for your Rayer programmer and LA-8241P motherboard. >> Most importantly, before plugging the power adapter you should unite >> three grounds: >> 1) GND of laptop's motherboard >> 2) GND of your programmer >> 3) GND of KB9012 >> Best regards, >> Mike Banon >> >> On Tue, Jan 8, 2019 at 3:30 PM Nyúlós Lónyál <udpsendtofailed@gmail.com> wrote: >> > >> > Hi! >> > >> > I'm trying to flash an ENE KB9012QF A3 KBC on LA-8241P motherboard. The problem is flashrom can't detect the internal SPI of it, fails with error. >> > >> > flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) >> > flashrom is free software, get the source code at https://flashrom.org >> > >> > flashrom was built with libpci 3.5.2, GCC 7.3.0, little endian >> > Command line (5 args): ./flashrom -p rayer_spi -c KB9012 (EDI) -V >> > Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). >> > Initializing rayer_spi programmer >> > Using address 0x378 as I/O base for parallel port access. >> > Using RayeR SPIPGM pinout. >> > The following protocols are supported: SPI. >> > Probing for ENE KB9012 (EDI), 128 kB: edi_chip_probe: reading hwversion failed >> > No EEPROM/flash device found. >> > Note: flashrom can never write if the flash chip isn't found automatically. >> > >> > How to get it working? Thanks a lot for help! >> > _______________________________________________ >> > flashrom mailing list -- flashrom@flashrom.org >> > To unsubscribe send an email to flashrom-leave@flashrom.org
The wires are ~20-25cm made of aluminium, but I have some broken USB cables with copper wires. I can reduce the distance of laptop's keyboard connector and DIP8 socket to about 5cm wire length, will give it a try tomorrow. And something that I've noticed at verifying with flashrom, it always gives a random hex number after "failed byte count from 0x00000000-0x0001ffff". Maybe the "Timed out waiting for SPI not busy!" error is caused by the wires too. Thanks for the idea, I will reply back with results. Mike Banon <mikebdp2@gmail.com> ezt írta (időpont: 2019. jan. 16., Sze, 1:09):
Sorry if I've already asked this question, but how long are your wires? Ideally they should be about 10cm length and made of good copper. Although it could work even for 30cm poor aluminum wires, still when there are read/write errors - the first suggestion which comes to my mind is to shorten the wires. I understand that it could be difficult to use short wires at your flashing setup, but hope it is possible for you to try. And also I hope that you've ordered CH341A just in case our suggestions wouldn't work.
The laptop can't boot, doesn't even react to power button or recovery key combination, and no charging LED lighting up Everything from this list is expected if there is a corrupted KB9012 firmware, because it is KB9012 which listens for your power button keypresses / controls the LEDs / etc
On Tue, Jan 15, 2019 at 2:44 PM Nyúlós Lónyál <udpsendtofailed@gmail.com> wrote:
Sorry for the confusion. :( I think you have misunderstood me.
My laptop's motherboard is taken out of the laptop. I have another
machine, a desktop PC which I've used for trying rayer_spi programmer. Now I connect the laptop's KB9012's debug pins into the desktop PC motherboard's DIP8 BIOS socket with wires, after it booted the linux distribution with flashrom installed and removing it's original BIOS SPI chip. The two machine's GND, DIP8 socket's GND, and KB9012's pin 42 are united.
Like when recovering a regular motherboard BIOS with hot-swapping chips,
just the only difference I connect the laptop's KBC instead of another BIOS chip: https://www.coreboot.org/FAQ#Developers
I think the desktop motherboard's BIOS socket can be used as an SPI
programmer this way, originally it has W25Q80BVAIG DIP8 chip which can be removed. That gave me these results, read and write errors which I sent before, but at least it can detect KB9012. I've tested with the original BIOS chip, flashrom can read, erase, and write it. The motherboard is an Asrock G41C-GS first generation, rev 1.0.2.
The laptop can't boot, doesn't even react to power button or recovery
key combination, and no charging LED lighting up, since it got bricked with a wrong BIOS update, this is why I want to reflash KB9012 with an external tool, like the desktop PC motherboard's DIP8 socket.
Mike Banon <mikebdp2@gmail.com> ezt írta (időpont: 2019. jan. 14., H,
22:43):
That is because KB9012 is active after your laptop has booted and not in debug state where it is possible to reflash it without a problem.
Have you double checked your laptop's datasheet to make sure your connection is correct, and also that your laptop's corner ground is really connected to its' ground? (what if not all its' copper circles are the grounds in your case)
On Fri, Jan 11, 2019 at 5:01 PM Nyúlós Lónyál <
udpsendtofailed@gmail.com> wrote:
Sorry for double mail. Erasing and writing fails too.
xubuntu@xubuntu:~/flashrom$ sudo ./flashrom -p internal -c "KB9012
(EDI)" -w /home/xubuntu/Desktop/EC-FD-Extract.bin
flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) flashrom is free software, get the source code at https://flashrom.org
Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). Found chipset "Intel ICH7/ICH7R". Enabling flash write... OK. edi_read: Retrying read with greater buffer length! edi_read: Retrying read with greater buffer length! Found ENE flash chip "KB9012 (EDI)" (128 kB, SPI) mapped at physical address 0x00000000fffe0000. Reading old flash chip contents... done. Erasing and writing flash chip... edi_chip_block_erase: Timed out waiting for SPI not busy! Reading current flash chip contents... done. Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. No usable erase functions left. FAILED! Uh oh. Erase/write failed. Checking if anything has changed. Reading current flash chip contents... done. Apparently at least some data has changed. Your flash chip is in an unknown state. Get help on IRC at chat.freenode.net (channel #flashrom) or mail flashrom@flashrom.org with the subject "FAILED: <your board name>"!
DO NOT REBOOT OR POWEROFF!
xubuntu@xubuntu:~/flashrom$ sudo ./flashrom -p internal -c "KB9012 (EDI)" -E flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) flashrom is free software, get the source code at https://flashrom.org
Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). Found chipset "Intel ICH7/ICH7R". Enabling flash write... OK. edi_read: Retrying read with greater buffer length! edi_read: Retrying read with greater buffer length! Found ENE flash chip "KB9012 (EDI)" (128 kB, SPI) mapped at physical address 0x00000000fffe0000. Erasing and writing flash chip... edi_chip_block_erase: Timed out waiting for SPI not busy! Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. No usable erase functions left. FAILED! Your flash chip is in an unknown state. Get help on IRC at chat.freenode.net (channel #flashrom) or mail flashrom@flashrom.org with the subject "FAILED: <your board name>"!
DO NOT REBOOT OR POWEROFF!
Nyúlós Lónyál <udpsendtofailed@gmail.com> ezt írta (időpont: 2019. jan. 11., P, 13:49):
Finally managed it to detect KBC's internal flash using the
motherboard's BIOS socket with removing it's SPI chip after boot, and connecting KB9012 in there. But the read always gives me different files, so I can't backup the current content of KB9012.
xubuntu@xubuntu:~/flashrom$ sudo ./flashrom -p internal -c "KB9012
(EDI)" -r /home/xubuntu/Desktop/ene1.bin
flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) flashrom is free software, get the source code at https://flashrom.org
Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). Found chipset "Intel ICH7/ICH7R". Enabling flash write... OK. edi_read: Retrying read with greater buffer length! edi_read: Retrying read with greater buffer length! Found ENE flash chip "KB9012 (EDI)" (128 kB, SPI) mapped at physical address 0x00000000fffe0000. Reading flash... done. xubuntu@xubuntu:~/flashrom$ sudo ./flashrom -p internal -c "KB9012 (EDI)" -v /home/xubuntu/Desktop/ene1.bin flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) flashrom is free software, get the source code at https://flashrom.org
Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). Found chipset "Intel ICH7/ICH7R". Enabling flash write... OK. edi_read: Retrying read with greater buffer length! edi_read: Retrying read with greater buffer length! Found ENE flash chip "KB9012 (EDI)" (128 kB, SPI) mapped at physical address 0x00000000fffe0000. Verifying flash... FAILED at 0x000034c2! Expected=0xff, Found=0x78, failed byte count from 0x00000000-0x0001ffff: 0x6c52
Nyúlós Lónyál <udpsendtofailed@gmail.com> ezt írta (időpont: 2019. jan. 10., Cs, 12:14):
Yea, tried to discharge the motherboard, taken out CMOS battery
too, it didn't help. I don't know if this is programmer related or not, I have reflashed 2 types of BIOS SPI chips with it, EN25QH16 and W25Q32BV. But these chips are maybe different from KB9012's debug interface. I can't get a CH341A for now, maybe some months later. It would be good to recover the laptop if it's possible with the tools I have currently, but not very urgent. Here is the programmer's config, if it helps: https://github.com/flashrom/flashrom/blob/master/rayer_spi.c
Mike Banon <mikebdp2@gmail.com> ezt írta (időpont: 2019. jan. 9.,
Sze, 18:59):
> > Just to double-check: please discharge the motherboard completely by > trying to turn it on while there is no power adapter connected, then > unite three grounds (KB9012 / programmer / motherboard ) and only then > connect the board's power adapter . After doing all that, please check > if you could read it now. Also, what if your issues are programmer > related? Is it possible for you to try another programmer, like CH341A > ? (because it costs like $2-$3 with free shipping from china, just > prefer to get a green PCB version because there were some 3.3/5V > issues with some black PCB CH341A , and blue PCB version costs the > same low price while having fewer pins) Or maybe you could get it > locally for a (hopefully) small premium if you're in hurry > > On Wed, Jan 9, 2019 at 3:20 PM Nyúlós Lónyál < udpsendtofailed@gmail.com> wrote: > > > > Hi Mike! > > > > I've followed the linked guide, it gave me these results. The grounds are united, still the same error happens. I have tried to GND pin 42 of KB9012 as mentioned in the guide, and tried to connect both pin 41 and 42 to GND, as in KBC's datasheet at EDI related part, still no success, flashrom doesn't detect it. > > > > Mike Banon <mikebdp2@gmail.com> ezt írta (időpont: 2019. jan. 8., K, 16:08): > >> > >> Hi Nyulos, > >> Have you tried following the KB9012 flashing instructions at > >> DangerousPrototypes wiki? > >> http://dangerousprototypes.com/docs/Flashing_KB9012_with_Bus_Pirate > >> Although that is for Bus Pirate / CH341A programmers and LA-A091P, > >> should be similar for your Rayer programmer and LA-8241P motherboard. > >> Most importantly, before plugging the power adapter you should unite > >> three grounds: > >> 1) GND of laptop's motherboard > >> 2) GND of your programmer > >> 3) GND of KB9012 > >> Best regards, > >> Mike Banon > >> > >> On Tue, Jan 8, 2019 at 3:30 PM Nyúlós Lónyál < udpsendtofailed@gmail.com> wrote: > >> > > >> > Hi! > >> > > >> > I'm trying to flash an ENE KB9012QF A3 KBC on LA-8241P motherboard. The problem is flashrom can't detect the internal SPI of it, fails with error. > >> > > >> > flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) > >> > flashrom is free software, get the source code at https://flashrom.org > >> > > >> > flashrom was built with libpci 3.5.2, GCC 7.3.0, little endian > >> > Command line (5 args): ./flashrom -p rayer_spi -c KB9012 (EDI) -V > >> > Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). > >> > Initializing rayer_spi programmer > >> > Using address 0x378 as I/O base for parallel port access. > >> > Using RayeR SPIPGM pinout. > >> > The following protocols are supported: SPI. > >> > Probing for ENE KB9012 (EDI), 128 kB: edi_chip_probe: reading hwversion failed > >> > No EEPROM/flash device found. > >> > Note: flashrom can never write if the flash chip isn't found automatically. > >> > > >> > How to get it working? Thanks a lot for help! > >> > _______________________________________________ > >> > flashrom mailing list -- flashrom@flashrom.org > >> > To unsubscribe send an email to flashrom-leave@flashrom.org
Same problem with 5cm long copper wires. Here is a video of what's happening: https://www.youtube.com/watch?v=JlbRGK9_gPg Nyúlós Lónyál <udpsendtofailed@gmail.com> ezt írta (időpont: 2019. jan. 16., Sze, 1:38):
The wires are ~20-25cm made of aluminium, but I have some broken USB cables with copper wires. I can reduce the distance of laptop's keyboard connector and DIP8 socket to about 5cm wire length, will give it a try tomorrow. And something that I've noticed at verifying with flashrom, it always gives a random hex number after "failed byte count from 0x00000000-0x0001ffff". Maybe the "Timed out waiting for SPI not busy!" error is caused by the wires too. Thanks for the idea, I will reply back with results.
Mike Banon <mikebdp2@gmail.com> ezt írta (időpont: 2019. jan. 16., Sze, 1:09):
Sorry if I've already asked this question, but how long are your wires? Ideally they should be about 10cm length and made of good copper. Although it could work even for 30cm poor aluminum wires, still when there are read/write errors - the first suggestion which comes to my mind is to shorten the wires. I understand that it could be difficult to use short wires at your flashing setup, but hope it is possible for you to try. And also I hope that you've ordered CH341A just in case our suggestions wouldn't work.
The laptop can't boot, doesn't even react to power button or recovery key combination, and no charging LED lighting up Everything from this list is expected if there is a corrupted KB9012 firmware, because it is KB9012 which listens for your power button keypresses / controls the LEDs / etc
On Tue, Jan 15, 2019 at 2:44 PM Nyúlós Lónyál <udpsendtofailed@gmail.com> wrote:
Sorry for the confusion. :( I think you have misunderstood me.
My laptop's motherboard is taken out of the laptop. I have another
machine, a desktop PC which I've used for trying rayer_spi programmer. Now I connect the laptop's KB9012's debug pins into the desktop PC motherboard's DIP8 BIOS socket with wires, after it booted the linux distribution with flashrom installed and removing it's original BIOS SPI chip. The two machine's GND, DIP8 socket's GND, and KB9012's pin 42 are united.
Like when recovering a regular motherboard BIOS with hot-swapping
chips, just the only difference I connect the laptop's KBC instead of another BIOS chip: https://www.coreboot.org/FAQ#Developers
I think the desktop motherboard's BIOS socket can be used as an SPI
programmer this way, originally it has W25Q80BVAIG DIP8 chip which can be removed. That gave me these results, read and write errors which I sent before, but at least it can detect KB9012. I've tested with the original BIOS chip, flashrom can read, erase, and write it. The motherboard is an Asrock G41C-GS first generation, rev 1.0.2.
The laptop can't boot, doesn't even react to power button or recovery
key combination, and no charging LED lighting up, since it got bricked with a wrong BIOS update, this is why I want to reflash KB9012 with an external tool, like the desktop PC motherboard's DIP8 socket.
Mike Banon <mikebdp2@gmail.com> ezt írta (időpont: 2019. jan. 14., H,
22:43):
That is because KB9012 is active after your laptop has booted and not in debug state where it is possible to reflash it without a problem.
Have you double checked your laptop's datasheet to make sure your connection is correct, and also that your laptop's corner ground is really connected to its' ground? (what if not all its' copper circles are the grounds in your case)
On Fri, Jan 11, 2019 at 5:01 PM Nyúlós Lónyál <
udpsendtofailed@gmail.com> wrote:
Sorry for double mail. Erasing and writing fails too.
xubuntu@xubuntu:~/flashrom$ sudo ./flashrom -p internal -c "KB9012
(EDI)" -w /home/xubuntu/Desktop/EC-FD-Extract.bin
flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) flashrom is free software, get the source code at https://flashrom.org
Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). Found chipset "Intel ICH7/ICH7R". Enabling flash write... OK. edi_read: Retrying read with greater buffer length! edi_read: Retrying read with greater buffer length! Found ENE flash chip "KB9012 (EDI)" (128 kB, SPI) mapped at physical address 0x00000000fffe0000. Reading old flash chip contents... done. Erasing and writing flash chip... edi_chip_block_erase: Timed out waiting for SPI not busy! Reading current flash chip contents... done. Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. No usable erase functions left. FAILED! Uh oh. Erase/write failed. Checking if anything has changed. Reading current flash chip contents... done. Apparently at least some data has changed. Your flash chip is in an unknown state. Get help on IRC at chat.freenode.net (channel #flashrom) or mail flashrom@flashrom.org with the subject "FAILED: <your board name>"!
DO NOT REBOOT OR POWEROFF!
xubuntu@xubuntu:~/flashrom$ sudo ./flashrom -p internal -c "KB9012 (EDI)" -E flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) flashrom is free software, get the source code at https://flashrom.org
Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). Found chipset "Intel ICH7/ICH7R". Enabling flash write... OK. edi_read: Retrying read with greater buffer length! edi_read: Retrying read with greater buffer length! Found ENE flash chip "KB9012 (EDI)" (128 kB, SPI) mapped at physical address 0x00000000fffe0000. Erasing and writing flash chip... edi_chip_block_erase: Timed out waiting for SPI not busy! Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. No usable erase functions left. FAILED! Your flash chip is in an unknown state. Get help on IRC at chat.freenode.net (channel #flashrom) or mail flashrom@flashrom.org with the subject "FAILED: <your board name>"!
DO NOT REBOOT OR POWEROFF!
Nyúlós Lónyál <udpsendtofailed@gmail.com> ezt írta (időpont: 2019. jan. 11., P, 13:49):
Finally managed it to detect KBC's internal flash using the
motherboard's BIOS socket with removing it's SPI chip after boot, and connecting KB9012 in there. But the read always gives me different files, so I can't backup the current content of KB9012.
xubuntu@xubuntu:~/flashrom$ sudo ./flashrom -p internal -c "KB9012
(EDI)" -r /home/xubuntu/Desktop/ene1.bin
flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) flashrom is free software, get the source code at https://flashrom.org
Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). Found chipset "Intel ICH7/ICH7R". Enabling flash write... OK. edi_read: Retrying read with greater buffer length! edi_read: Retrying read with greater buffer length! Found ENE flash chip "KB9012 (EDI)" (128 kB, SPI) mapped at physical address 0x00000000fffe0000. Reading flash... done. xubuntu@xubuntu:~/flashrom$ sudo ./flashrom -p internal -c "KB9012 (EDI)" -v /home/xubuntu/Desktop/ene1.bin flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) flashrom is free software, get the source code at https://flashrom.org
Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). Found chipset "Intel ICH7/ICH7R". Enabling flash write... OK. edi_read: Retrying read with greater buffer length! edi_read: Retrying read with greater buffer length! Found ENE flash chip "KB9012 (EDI)" (128 kB, SPI) mapped at physical address 0x00000000fffe0000. Verifying flash... FAILED at 0x000034c2! Expected=0xff, Found=0x78, failed byte count from 0x00000000-0x0001ffff: 0x6c52
Nyúlós Lónyál <udpsendtofailed@gmail.com> ezt írta (időpont: 2019. jan. 10., Cs, 12:14): > > Yea, tried to discharge the motherboard, taken out CMOS battery too, it didn't help. I don't know if this is programmer related or not, I have reflashed 2 types of BIOS SPI chips with it, EN25QH16 and W25Q32BV. But these chips are maybe different from KB9012's debug interface. I can't get a CH341A for now, maybe some months later. It would be good to recover the laptop if it's possible with the tools I have currently, but not very urgent. Here is the programmer's config, if it helps: https://github.com/flashrom/flashrom/blob/master/rayer_spi.c > > Mike Banon <mikebdp2@gmail.com> ezt írta (időpont: 2019. jan. 9., Sze, 18:59): >> >> Just to double-check: please discharge the motherboard completely by >> trying to turn it on while there is no power adapter connected, then >> unite three grounds (KB9012 / programmer / motherboard ) and only then >> connect the board's power adapter . After doing all that, please check >> if you could read it now. Also, what if your issues are programmer >> related? Is it possible for you to try another programmer, like CH341A >> ? (because it costs like $2-$3 with free shipping from china, just >> prefer to get a green PCB version because there were some 3.3/5V >> issues with some black PCB CH341A , and blue PCB version costs the >> same low price while having fewer pins) Or maybe you could get it >> locally for a (hopefully) small premium if you're in hurry >> >> On Wed, Jan 9, 2019 at 3:20 PM Nyúlós Lónyál < udpsendtofailed@gmail.com> wrote: >> > >> > Hi Mike! >> > >> > I've followed the linked guide, it gave me these results. The grounds are united, still the same error happens. I have tried to GND pin 42 of KB9012 as mentioned in the guide, and tried to connect both pin 41 and 42 to GND, as in KBC's datasheet at EDI related part, still no success, flashrom doesn't detect it. >> > >> > Mike Banon <mikebdp2@gmail.com> ezt írta (időpont: 2019. jan. 8., K, 16:08): >> >> >> >> Hi Nyulos, >> >> Have you tried following the KB9012 flashing instructions at >> >> DangerousPrototypes wiki? >> >> http://dangerousprototypes.com/docs/Flashing_KB9012_with_Bus_Pirate >> >> Although that is for Bus Pirate / CH341A programmers and LA-A091P, >> >> should be similar for your Rayer programmer and LA-8241P motherboard. >> >> Most importantly, before plugging the power adapter you should unite >> >> three grounds: >> >> 1) GND of laptop's motherboard >> >> 2) GND of your programmer >> >> 3) GND of KB9012 >> >> Best regards, >> >> Mike Banon >> >> >> >> On Tue, Jan 8, 2019 at 3:30 PM Nyúlós Lónyál < udpsendtofailed@gmail.com> wrote: >> >> > >> >> > Hi! >> >> > >> >> > I'm trying to flash an ENE KB9012QF A3 KBC on LA-8241P motherboard. The problem is flashrom can't detect the internal SPI of it, fails with error. >> >> > >> >> > flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) >> >> > flashrom is free software, get the source code at https://flashrom.org >> >> > >> >> > flashrom was built with libpci 3.5.2, GCC 7.3.0, little endian >> >> > Command line (5 args): ./flashrom -p rayer_spi -c KB9012 (EDI) -V >> >> > Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). >> >> > Initializing rayer_spi programmer >> >> > Using address 0x378 as I/O base for parallel port access. >> >> > Using RayeR SPIPGM pinout. >> >> > The following protocols are supported: SPI. >> >> > Probing for ENE KB9012 (EDI), 128 kB: edi_chip_probe: reading hwversion failed >> >> > No EEPROM/flash device found. >> >> > Note: flashrom can never write if the flash chip isn't found automatically. >> >> > >> >> > How to get it working? Thanks a lot for help! >> >> > _______________________________________________ >> >> > flashrom mailing list -- flashrom@flashrom.org >> >> > To unsubscribe send an email to flashrom-leave@flashrom.org
Sorry for a long reply, I just watched your video and - unless you changed its' speed - it seems to me that your KB9012 operations are going faster than expected, e.g. it reached 0x4*** address almost instantly while in my CH341A case it was almost certainly slower. So maybe you could experiment with spispeed parameter, like flashrom -p internal:spispeed=frequency , please look it up online ( I can't at the moment ) On Wed, Jan 16, 2019 at 5:01 PM Nyúlós Lónyál <udpsendtofailed@gmail.com> wrote:
Same problem with 5cm long copper wires. Here is a video of what's happening: https://www.youtube.com/watch?v=JlbRGK9_gPg
Nyúlós Lónyál <udpsendtofailed@gmail.com> ezt írta (időpont: 2019. jan. 16., Sze, 1:38):
The wires are ~20-25cm made of aluminium, but I have some broken USB cables with copper wires. I can reduce the distance of laptop's keyboard connector and DIP8 socket to about 5cm wire length, will give it a try tomorrow. And something that I've noticed at verifying with flashrom, it always gives a random hex number after "failed byte count from 0x00000000-0x0001ffff". Maybe the "Timed out waiting for SPI not busy!" error is caused by the wires too. Thanks for the idea, I will reply back with results.
Mike Banon <mikebdp2@gmail.com> ezt írta (időpont: 2019. jan. 16., Sze, 1:09):
Sorry if I've already asked this question, but how long are your wires? Ideally they should be about 10cm length and made of good copper. Although it could work even for 30cm poor aluminum wires, still when there are read/write errors - the first suggestion which comes to my mind is to shorten the wires. I understand that it could be difficult to use short wires at your flashing setup, but hope it is possible for you to try. And also I hope that you've ordered CH341A just in case our suggestions wouldn't work.
The laptop can't boot, doesn't even react to power button or recovery key combination, and no charging LED lighting up Everything from this list is expected if there is a corrupted KB9012 firmware, because it is KB9012 which listens for your power button keypresses / controls the LEDs / etc
On Tue, Jan 15, 2019 at 2:44 PM Nyúlós Lónyál <udpsendtofailed@gmail.com> wrote:
Sorry for the confusion. :( I think you have misunderstood me.
My laptop's motherboard is taken out of the laptop. I have another machine, a desktop PC which I've used for trying rayer_spi programmer. Now I connect the laptop's KB9012's debug pins into the desktop PC motherboard's DIP8 BIOS socket with wires, after it booted the linux distribution with flashrom installed and removing it's original BIOS SPI chip. The two machine's GND, DIP8 socket's GND, and KB9012's pin 42 are united.
Like when recovering a regular motherboard BIOS with hot-swapping chips, just the only difference I connect the laptop's KBC instead of another BIOS chip: https://www.coreboot.org/FAQ#Developers
I think the desktop motherboard's BIOS socket can be used as an SPI programmer this way, originally it has W25Q80BVAIG DIP8 chip which can be removed. That gave me these results, read and write errors which I sent before, but at least it can detect KB9012. I've tested with the original BIOS chip, flashrom can read, erase, and write it. The motherboard is an Asrock G41C-GS first generation, rev 1.0.2.
The laptop can't boot, doesn't even react to power button or recovery key combination, and no charging LED lighting up, since it got bricked with a wrong BIOS update, this is why I want to reflash KB9012 with an external tool, like the desktop PC motherboard's DIP8 socket.
Mike Banon <mikebdp2@gmail.com> ezt írta (időpont: 2019. jan. 14., H, 22:43):
That is because KB9012 is active after your laptop has booted and not in debug state where it is possible to reflash it without a problem.
Have you double checked your laptop's datasheet to make sure your connection is correct, and also that your laptop's corner ground is really connected to its' ground? (what if not all its' copper circles are the grounds in your case)
On Fri, Jan 11, 2019 at 5:01 PM Nyúlós Lónyál <udpsendtofailed@gmail.com> wrote:
Sorry for double mail. Erasing and writing fails too.
xubuntu@xubuntu:~/flashrom$ sudo ./flashrom -p internal -c "KB9012 (EDI)" -w /home/xubuntu/Desktop/EC-FD-Extract.bin flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) flashrom is free software, get the source code at https://flashrom.org
Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). Found chipset "Intel ICH7/ICH7R". Enabling flash write... OK. edi_read: Retrying read with greater buffer length! edi_read: Retrying read with greater buffer length! Found ENE flash chip "KB9012 (EDI)" (128 kB, SPI) mapped at physical address 0x00000000fffe0000. Reading old flash chip contents... done. Erasing and writing flash chip... edi_chip_block_erase: Timed out waiting for SPI not busy! Reading current flash chip contents... done. Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. No usable erase functions left. FAILED! Uh oh. Erase/write failed. Checking if anything has changed. Reading current flash chip contents... done. Apparently at least some data has changed. Your flash chip is in an unknown state. Get help on IRC at chat.freenode.net (channel #flashrom) or mail flashrom@flashrom.org with the subject "FAILED: <your board name>"! ------------------------------------------------------------------------------- DO NOT REBOOT OR POWEROFF!
xubuntu@xubuntu:~/flashrom$ sudo ./flashrom -p internal -c "KB9012 (EDI)" -E flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) flashrom is free software, get the source code at https://flashrom.org
Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). Found chipset "Intel ICH7/ICH7R". Enabling flash write... OK. edi_read: Retrying read with greater buffer length! edi_read: Retrying read with greater buffer length! Found ENE flash chip "KB9012 (EDI)" (128 kB, SPI) mapped at physical address 0x00000000fffe0000. Erasing and writing flash chip... edi_chip_block_erase: Timed out waiting for SPI not busy! Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. Looking for another erase function. No usable erase functions left. FAILED! Your flash chip is in an unknown state. Get help on IRC at chat.freenode.net (channel #flashrom) or mail flashrom@flashrom.org with the subject "FAILED: <your board name>"! ------------------------------------------------------------------------------- DO NOT REBOOT OR POWEROFF!
Nyúlós Lónyál <udpsendtofailed@gmail.com> ezt írta (időpont: 2019. jan. 11., P, 13:49): > > Finally managed it to detect KBC's internal flash using the motherboard's BIOS socket with removing it's SPI chip after boot, and connecting KB9012 in there. But the read always gives me different files, so I can't backup the current content of KB9012. > > xubuntu@xubuntu:~/flashrom$ sudo ./flashrom -p internal -c "KB9012 (EDI)" -r /home/xubuntu/Desktop/ene1.bin > flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) > flashrom is free software, get the source code at https://flashrom.org > > Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). > Found chipset "Intel ICH7/ICH7R". > Enabling flash write... OK. > edi_read: Retrying read with greater buffer length! > edi_read: Retrying read with greater buffer length! > Found ENE flash chip "KB9012 (EDI)" (128 kB, SPI) mapped at physical address 0x00000000fffe0000. > Reading flash... done. > xubuntu@xubuntu:~/flashrom$ sudo ./flashrom -p internal -c "KB9012 (EDI)" -v /home/xubuntu/Desktop/ene1.bin > flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) > flashrom is free software, get the source code at https://flashrom.org > > Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). > Found chipset "Intel ICH7/ICH7R". > Enabling flash write... OK. > edi_read: Retrying read with greater buffer length! > edi_read: Retrying read with greater buffer length! > Found ENE flash chip "KB9012 (EDI)" (128 kB, SPI) mapped at physical address 0x00000000fffe0000. > Verifying flash... FAILED at 0x000034c2! Expected=0xff, Found=0x78, failed byte count from 0x00000000-0x0001ffff: 0x6c52 > > > Nyúlós Lónyál <udpsendtofailed@gmail.com> ezt írta (időpont: 2019. jan. 10., Cs, 12:14): >> >> Yea, tried to discharge the motherboard, taken out CMOS battery too, it didn't help. I don't know if this is programmer related or not, I have reflashed 2 types of BIOS SPI chips with it, EN25QH16 and W25Q32BV. But these chips are maybe different from KB9012's debug interface. I can't get a CH341A for now, maybe some months later. It would be good to recover the laptop if it's possible with the tools I have currently, but not very urgent. Here is the programmer's config, if it helps: https://github.com/flashrom/flashrom/blob/master/rayer_spi.c >> >> Mike Banon <mikebdp2@gmail.com> ezt írta (időpont: 2019. jan. 9., Sze, 18:59): >>> >>> Just to double-check: please discharge the motherboard completely by >>> trying to turn it on while there is no power adapter connected, then >>> unite three grounds (KB9012 / programmer / motherboard ) and only then >>> connect the board's power adapter . After doing all that, please check >>> if you could read it now. Also, what if your issues are programmer >>> related? Is it possible for you to try another programmer, like CH341A >>> ? (because it costs like $2-$3 with free shipping from china, just >>> prefer to get a green PCB version because there were some 3.3/5V >>> issues with some black PCB CH341A , and blue PCB version costs the >>> same low price while having fewer pins) Or maybe you could get it >>> locally for a (hopefully) small premium if you're in hurry >>> >>> On Wed, Jan 9, 2019 at 3:20 PM Nyúlós Lónyál <udpsendtofailed@gmail.com> wrote: >>> > >>> > Hi Mike! >>> > >>> > I've followed the linked guide, it gave me these results. The grounds are united, still the same error happens. I have tried to GND pin 42 of KB9012 as mentioned in the guide, and tried to connect both pin 41 and 42 to GND, as in KBC's datasheet at EDI related part, still no success, flashrom doesn't detect it. >>> > >>> > Mike Banon <mikebdp2@gmail.com> ezt írta (időpont: 2019. jan. 8., K, 16:08): >>> >> >>> >> Hi Nyulos, >>> >> Have you tried following the KB9012 flashing instructions at >>> >> DangerousPrototypes wiki? >>> >> http://dangerousprototypes.com/docs/Flashing_KB9012_with_Bus_Pirate >>> >> Although that is for Bus Pirate / CH341A programmers and LA-A091P, >>> >> should be similar for your Rayer programmer and LA-8241P motherboard. >>> >> Most importantly, before plugging the power adapter you should unite >>> >> three grounds: >>> >> 1) GND of laptop's motherboard >>> >> 2) GND of your programmer >>> >> 3) GND of KB9012 >>> >> Best regards, >>> >> Mike Banon >>> >> >>> >> On Tue, Jan 8, 2019 at 3:30 PM Nyúlós Lónyál <udpsendtofailed@gmail.com> wrote: >>> >> > >>> >> > Hi! >>> >> > >>> >> > I'm trying to flash an ENE KB9012QF A3 KBC on LA-8241P motherboard. The problem is flashrom can't detect the internal SPI of it, fails with error. >>> >> > >>> >> > flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) >>> >> > flashrom is free software, get the source code at https://flashrom.org >>> >> > >>> >> > flashrom was built with libpci 3.5.2, GCC 7.3.0, little endian >>> >> > Command line (5 args): ./flashrom -p rayer_spi -c KB9012 (EDI) -V >>> >> > Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). >>> >> > Initializing rayer_spi programmer >>> >> > Using address 0x378 as I/O base for parallel port access. >>> >> > Using RayeR SPIPGM pinout. >>> >> > The following protocols are supported: SPI. >>> >> > Probing for ENE KB9012 (EDI), 128 kB: edi_chip_probe: reading hwversion failed >>> >> > No EEPROM/flash device found. >>> >> > Note: flashrom can never write if the flash chip isn't found automatically. >>> >> > >>> >> > How to get it working? Thanks a lot for help! >>> >> > _______________________________________________ >>> >> > flashrom mailing list -- flashrom@flashrom.org >>> >> > To unsubscribe send an email to flashrom-leave@flashrom.org
Thanks for replying at my noob questions. :) The spispeed parameter, yea, I thought about it after looking into flashrom's source on GitHub. Sadly it's not in the code of ICH7 chipset (ichspi.c), so the spispeed option in flashrom command is unavailable. Someone already did that for AMD SB600 chipset (sb600spi.c), found a link about it: https://mail.coreboot.org/pipermail/flashrom/2013-August/011410.html I don't know much about C programming language, so I can't transform that code for ICH7. I have no more ideas, maybe it's possible to modify the default SPI frequency in ichspi.c, I'm not sure. Mike Banon <mikebdp2@gmail.com> ezt írta (időpont: 2019. jan. 19., Szo, 23:25): > Sorry for a long reply, I just watched your video and - unless you > changed its' speed - it seems to me that your KB9012 operations are > going faster than expected, e.g. it reached 0x4*** address almost > instantly while in my CH341A case it was almost certainly slower. So > maybe you could experiment with spispeed parameter, like flashrom -p > internal:spispeed=frequency , please look it up online ( I can't at > the moment ) > > > On Wed, Jan 16, 2019 at 5:01 PM Nyúlós Lónyál <udpsendtofailed@gmail.com> > wrote: > > > > Same problem with 5cm long copper wires. Here is a video of what's > happening: https://www.youtube.com/watch?v=JlbRGK9_gPg > > > > Nyúlós Lónyál <udpsendtofailed@gmail.com> ezt írta (időpont: 2019. jan. > 16., Sze, 1:38): > >> > >> The wires are ~20-25cm made of aluminium, but I have some broken USB > cables with copper wires. I can reduce the distance of laptop's keyboard > connector and DIP8 socket to about 5cm wire length, will give it a try > tomorrow. And something that I've noticed at verifying with flashrom, it > always gives a random hex number after "failed byte count from > 0x00000000-0x0001ffff". Maybe the "Timed out waiting for SPI not busy!" > error is caused by the wires too. Thanks for the idea, I will reply back > with results. > >> > >> Mike Banon <mikebdp2@gmail.com> ezt írta (időpont: 2019. jan. 16., > Sze, 1:09): > >>> > >>> Sorry if I've already asked this question, but how long are your > >>> wires? Ideally they should be about 10cm length and made of good > >>> copper. Although it could work even for 30cm poor aluminum wires, > >>> still when there are read/write errors - the first suggestion which > >>> comes to my mind is to shorten the wires. I understand that it could > >>> be difficult to use short wires at your flashing setup, but hope it is > >>> possible for you to try. And also I hope that you've ordered CH341A > >>> just in case our suggestions wouldn't work. > >>> > The laptop can't boot, doesn't even react to power button or > recovery key combination, and no charging LED lighting up > >>> Everything from this list is expected if there is a corrupted KB9012 > >>> firmware, because it is KB9012 which listens for your power button > >>> keypresses / controls the LEDs / etc > >>> > >>> On Tue, Jan 15, 2019 at 2:44 PM Nyúlós Lónyál < > udpsendtofailed@gmail.com> wrote: > >>> > > >>> > Sorry for the confusion. :( I think you have misunderstood me. > >>> > > >>> > My laptop's motherboard is taken out of the laptop. I have another > machine, a desktop PC which I've used for trying rayer_spi programmer. Now > I connect the laptop's KB9012's debug pins into the desktop PC > motherboard's DIP8 BIOS socket with wires, after it booted the linux > distribution with flashrom installed and removing it's original BIOS SPI > chip. The two machine's GND, DIP8 socket's GND, and KB9012's pin 42 are > united. > >>> > > >>> > Like when recovering a regular motherboard BIOS with hot-swapping > chips, just the only difference I connect the laptop's KBC instead of > another BIOS chip: https://www.coreboot.org/FAQ#Developers > >>> > > >>> > I think the desktop motherboard's BIOS socket can be used as an SPI > programmer this way, originally it has W25Q80BVAIG DIP8 chip which can be > removed. That gave me these results, read and write errors which I sent > before, but at least it can detect KB9012. I've tested with the original > BIOS chip, flashrom can read, erase, and write it. The motherboard is an > Asrock G41C-GS first generation, rev 1.0.2. > >>> > > >>> > The laptop can't boot, doesn't even react to power button or > recovery key combination, and no charging LED lighting up, since it got > bricked with a wrong BIOS update, this is why I want to reflash KB9012 with > an external tool, like the desktop PC motherboard's DIP8 socket. > >>> > > >>> > Mike Banon <mikebdp2@gmail.com> ezt írta (időpont: 2019. jan. 14., > H, 22:43): > >>> >> > >>> >> That is because KB9012 is active after your laptop has booted and > not > >>> >> in debug state where it is possible to reflash it without a problem. > >>> >> > >>> >> Have you double checked your laptop's datasheet to make sure your > >>> >> connection is correct, and also that your laptop's corner ground is > >>> >> really connected to its' ground? (what if not all its' copper > circles > >>> >> are the grounds in your case) > >>> >> > >>> >> On Fri, Jan 11, 2019 at 5:01 PM Nyúlós Lónyál < > udpsendtofailed@gmail.com> wrote: > >>> >> > > >>> >> > Sorry for double mail. Erasing and writing fails too. > >>> >> > > >>> >> > xubuntu@xubuntu:~/flashrom$ sudo ./flashrom -p internal -c > "KB9012 (EDI)" -w /home/xubuntu/Desktop/EC-FD-Extract.bin > >>> >> > flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) > >>> >> > flashrom is free software, get the source code at > https://flashrom.org > >>> >> > > >>> >> > Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). > >>> >> > Found chipset "Intel ICH7/ICH7R". > >>> >> > Enabling flash write... OK. > >>> >> > edi_read: Retrying read with greater buffer length! > >>> >> > edi_read: Retrying read with greater buffer length! > >>> >> > Found ENE flash chip "KB9012 (EDI)" (128 kB, SPI) mapped at > physical address 0x00000000fffe0000. > >>> >> > Reading old flash chip contents... done. > >>> >> > Erasing and writing flash chip... edi_chip_block_erase: Timed out > waiting for SPI not busy! > >>> >> > Reading current flash chip contents... done. Looking for another > erase function. > >>> >> > Looking for another erase function. > >>> >> > Looking for another erase function. > >>> >> > Looking for another erase function. > >>> >> > Looking for another erase function. > >>> >> > Looking for another erase function. > >>> >> > Looking for another erase function. > >>> >> > No usable erase functions left. > >>> >> > FAILED! > >>> >> > Uh oh. Erase/write failed. Checking if anything has changed. > >>> >> > Reading current flash chip contents... done. > >>> >> > Apparently at least some data has changed. > >>> >> > Your flash chip is in an unknown state. > >>> >> > Get help on IRC at chat.freenode.net (channel #flashrom) or > >>> >> > mail flashrom@flashrom.org with the subject "FAILED: <your board > name>"! > >>> >> > > ------------------------------------------------------------------------------- > >>> >> > DO NOT REBOOT OR POWEROFF! > >>> >> > > >>> >> > xubuntu@xubuntu:~/flashrom$ sudo ./flashrom -p internal -c > "KB9012 (EDI)" -E > >>> >> > flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) > >>> >> > flashrom is free software, get the source code at > https://flashrom.org > >>> >> > > >>> >> > Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). > >>> >> > Found chipset "Intel ICH7/ICH7R". > >>> >> > Enabling flash write... OK. > >>> >> > edi_read: Retrying read with greater buffer length! > >>> >> > edi_read: Retrying read with greater buffer length! > >>> >> > Found ENE flash chip "KB9012 (EDI)" (128 kB, SPI) mapped at > physical address 0x00000000fffe0000. > >>> >> > Erasing and writing flash chip... edi_chip_block_erase: Timed out > waiting for SPI not busy! > >>> >> > Looking for another erase function. > >>> >> > Looking for another erase function. > >>> >> > Looking for another erase function. > >>> >> > Looking for another erase function. > >>> >> > Looking for another erase function. > >>> >> > Looking for another erase function. > >>> >> > Looking for another erase function. > >>> >> > No usable erase functions left. > >>> >> > FAILED! > >>> >> > Your flash chip is in an unknown state. > >>> >> > Get help on IRC at chat.freenode.net (channel #flashrom) or > >>> >> > mail flashrom@flashrom.org with the subject "FAILED: <your board > name>"! > >>> >> > > ------------------------------------------------------------------------------- > >>> >> > DO NOT REBOOT OR POWEROFF! > >>> >> > > >>> >> > Nyúlós Lónyál <udpsendtofailed@gmail.com> ezt írta (időpont: > 2019. jan. 11., P, 13:49): > >>> >> >> > >>> >> >> Finally managed it to detect KBC's internal flash using the > motherboard's BIOS socket with removing it's SPI chip after boot, and > connecting KB9012 in there. But the read always gives me different files, > so I can't backup the current content of KB9012. > >>> >> >> > >>> >> >> xubuntu@xubuntu:~/flashrom$ sudo ./flashrom -p internal -c > "KB9012 (EDI)" -r /home/xubuntu/Desktop/ene1.bin > >>> >> >> flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) > >>> >> >> flashrom is free software, get the source code at > https://flashrom.org > >>> >> >> > >>> >> >> Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). > >>> >> >> Found chipset "Intel ICH7/ICH7R". > >>> >> >> Enabling flash write... OK. > >>> >> >> edi_read: Retrying read with greater buffer length! > >>> >> >> edi_read: Retrying read with greater buffer length! > >>> >> >> Found ENE flash chip "KB9012 (EDI)" (128 kB, SPI) mapped at > physical address 0x00000000fffe0000. > >>> >> >> Reading flash... done. > >>> >> >> xubuntu@xubuntu:~/flashrom$ sudo ./flashrom -p internal -c > "KB9012 (EDI)" -v /home/xubuntu/Desktop/ene1.bin > >>> >> >> flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) > >>> >> >> flashrom is free software, get the source code at > https://flashrom.org > >>> >> >> > >>> >> >> Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). > >>> >> >> Found chipset "Intel ICH7/ICH7R". > >>> >> >> Enabling flash write... OK. > >>> >> >> edi_read: Retrying read with greater buffer length! > >>> >> >> edi_read: Retrying read with greater buffer length! > >>> >> >> Found ENE flash chip "KB9012 (EDI)" (128 kB, SPI) mapped at > physical address 0x00000000fffe0000. > >>> >> >> Verifying flash... FAILED at 0x000034c2! Expected=0xff, > Found=0x78, failed byte count from 0x00000000-0x0001ffff: 0x6c52 > >>> >> >> > >>> >> >> > >>> >> >> Nyúlós Lónyál <udpsendtofailed@gmail.com> ezt írta (időpont: > 2019. jan. 10., Cs, 12:14): > >>> >> >>> > >>> >> >>> Yea, tried to discharge the motherboard, taken out CMOS battery > too, it didn't help. I don't know if this is programmer related or not, I > have reflashed 2 types of BIOS SPI chips with it, EN25QH16 and W25Q32BV. > But these chips are maybe different from KB9012's debug interface. I can't > get a CH341A for now, maybe some months later. It would be good to recover > the laptop if it's possible with the tools I have currently, but not very > urgent. Here is the programmer's config, if it helps: > https://github.com/flashrom/flashrom/blob/master/rayer_spi.c > >>> >> >>> > >>> >> >>> Mike Banon <mikebdp2@gmail.com> ezt írta (időpont: 2019. jan. > 9., Sze, 18:59): > >>> >> >>>> > >>> >> >>>> Just to double-check: please discharge the motherboard > completely by > >>> >> >>>> trying to turn it on while there is no power adapter > connected, then > >>> >> >>>> unite three grounds (KB9012 / programmer / motherboard ) and > only then > >>> >> >>>> connect the board's power adapter . After doing all that, > please check > >>> >> >>>> if you could read it now. Also, what if your issues are > programmer > >>> >> >>>> related? Is it possible for you to try another programmer, > like CH341A > >>> >> >>>> ? (because it costs like $2-$3 with free shipping from china, > just > >>> >> >>>> prefer to get a green PCB version because there were some > 3.3/5V > >>> >> >>>> issues with some black PCB CH341A , and blue PCB version costs > the > >>> >> >>>> same low price while having fewer pins) Or maybe you could get > it > >>> >> >>>> locally for a (hopefully) small premium if you're in hurry > >>> >> >>>> > >>> >> >>>> On Wed, Jan 9, 2019 at 3:20 PM Nyúlós Lónyál < > udpsendtofailed@gmail.com> wrote: > >>> >> >>>> > > >>> >> >>>> > Hi Mike! > >>> >> >>>> > > >>> >> >>>> > I've followed the linked guide, it gave me these results. > The grounds are united, still the same error happens. I have tried to GND > pin 42 of KB9012 as mentioned in the guide, and tried to connect both pin > 41 and 42 to GND, as in KBC's datasheet at EDI related part, still no > success, flashrom doesn't detect it. > >>> >> >>>> > > >>> >> >>>> > Mike Banon <mikebdp2@gmail.com> ezt írta (időpont: 2019. > jan. 8., K, 16:08): > >>> >> >>>> >> > >>> >> >>>> >> Hi Nyulos, > >>> >> >>>> >> Have you tried following the KB9012 flashing instructions at > >>> >> >>>> >> DangerousPrototypes wiki? > >>> >> >>>> >> > http://dangerousprototypes.com/docs/Flashing_KB9012_with_Bus_Pirate > >>> >> >>>> >> Although that is for Bus Pirate / CH341A programmers and > LA-A091P, > >>> >> >>>> >> should be similar for your Rayer programmer and LA-8241P > motherboard. > >>> >> >>>> >> Most importantly, before plugging the power adapter you > should unite > >>> >> >>>> >> three grounds: > >>> >> >>>> >> 1) GND of laptop's motherboard > >>> >> >>>> >> 2) GND of your programmer > >>> >> >>>> >> 3) GND of KB9012 > >>> >> >>>> >> Best regards, > >>> >> >>>> >> Mike Banon > >>> >> >>>> >> > >>> >> >>>> >> On Tue, Jan 8, 2019 at 3:30 PM Nyúlós Lónyál < > udpsendtofailed@gmail.com> wrote: > >>> >> >>>> >> > > >>> >> >>>> >> > Hi! > >>> >> >>>> >> > > >>> >> >>>> >> > I'm trying to flash an ENE KB9012QF A3 KBC on LA-8241P > motherboard. The problem is flashrom can't detect the internal SPI of it, > fails with error. > >>> >> >>>> >> > > >>> >> >>>> >> > flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic > (x86_64) > >>> >> >>>> >> > flashrom is free software, get the source code at > https://flashrom.org > >>> >> >>>> >> > > >>> >> >>>> >> > flashrom was built with libpci 3.5.2, GCC 7.3.0, little > endian > >>> >> >>>> >> > Command line (5 args): ./flashrom -p rayer_spi -c KB9012 > (EDI) -V > >>> >> >>>> >> > Using clock_gettime for delay loops (clk_id: 1, > resolution: 1ns). > >>> >> >>>> >> > Initializing rayer_spi programmer > >>> >> >>>> >> > Using address 0x378 as I/O base for parallel port access. > >>> >> >>>> >> > Using RayeR SPIPGM pinout. > >>> >> >>>> >> > The following protocols are supported: SPI. > >>> >> >>>> >> > Probing for ENE KB9012 (EDI), 128 kB: edi_chip_probe: > reading hwversion failed > >>> >> >>>> >> > No EEPROM/flash device found. > >>> >> >>>> >> > Note: flashrom can never write if the flash chip isn't > found automatically. > >>> >> >>>> >> > > >>> >> >>>> >> > How to get it working? Thanks a lot for help! > >>> >> >>>> >> > _______________________________________________ > >>> >> >>>> >> > flashrom mailing list -- flashrom@flashrom.org > >>> >> >>>> >> > To unsubscribe send an email to > flashrom-leave@flashrom.org >
Maybe try inserting some extra programmer_delay(n) to your ichspi.c ? Also I had a patch for the unreliable flashing environments - https://review.coreboot.org/c/flashrom/+/23840 - but didn't improve it yet so it haven't been merged, and already incompatible with the latest flashrom. Also maybe it doesn't affect KB9012 if its' flashing functions are different, but maybe it could be useful somehow. Still I hope that you've already ordered that CH341A since it costs very cheap, just $2-$3, and could save a lot of your time. On Sun, Jan 20, 2019 at 3:35 AM Nyúlós Lónyál <udpsendtofailed@gmail.com> wrote:
Thanks for replying at my noob questions. :) The spispeed parameter, yea, I thought about it after looking into flashrom's source on GitHub. Sadly it's not in the code of ICH7 chipset (ichspi.c), so the spispeed option in flashrom command is unavailable. Someone already did that for AMD SB600 chipset (sb600spi.c), found a link about it: https://mail.coreboot.org/pipermail/flashrom/2013-August/011410.html
I don't know much about C programming language, so I can't transform that code for ICH7. I have no more ideas, maybe it's possible to modify the default SPI frequency in ichspi.c, I'm not sure.
Mike Banon <mikebdp2@gmail.com> ezt írta (időpont: 2019. jan. 19., Szo, 23:25):
Sorry for a long reply, I just watched your video and - unless you changed its' speed - it seems to me that your KB9012 operations are going faster than expected, e.g. it reached 0x4*** address almost instantly while in my CH341A case it was almost certainly slower. So maybe you could experiment with spispeed parameter, like flashrom -p internal:spispeed=frequency , please look it up online ( I can't at the moment )
On Wed, Jan 16, 2019 at 5:01 PM Nyúlós Lónyál <udpsendtofailed@gmail.com> wrote:
Same problem with 5cm long copper wires. Here is a video of what's happening: https://www.youtube.com/watch?v=JlbRGK9_gPg
Nyúlós Lónyál <udpsendtofailed@gmail.com> ezt írta (időpont: 2019. jan. 16., Sze, 1:38):
The wires are ~20-25cm made of aluminium, but I have some broken USB cables with copper wires. I can reduce the distance of laptop's keyboard connector and DIP8 socket to about 5cm wire length, will give it a try tomorrow. And something that I've noticed at verifying with flashrom, it always gives a random hex number after "failed byte count from 0x00000000-0x0001ffff". Maybe the "Timed out waiting for SPI not busy!" error is caused by the wires too. Thanks for the idea, I will reply back with results.
Mike Banon <mikebdp2@gmail.com> ezt írta (időpont: 2019. jan. 16., Sze, 1:09):
Sorry if I've already asked this question, but how long are your wires? Ideally they should be about 10cm length and made of good copper. Although it could work even for 30cm poor aluminum wires, still when there are read/write errors - the first suggestion which comes to my mind is to shorten the wires. I understand that it could be difficult to use short wires at your flashing setup, but hope it is possible for you to try. And also I hope that you've ordered CH341A just in case our suggestions wouldn't work.
The laptop can't boot, doesn't even react to power button or recovery key combination, and no charging LED lighting up Everything from this list is expected if there is a corrupted KB9012 firmware, because it is KB9012 which listens for your power button keypresses / controls the LEDs / etc
On Tue, Jan 15, 2019 at 2:44 PM Nyúlós Lónyál <udpsendtofailed@gmail.com> wrote:
Sorry for the confusion. :( I think you have misunderstood me.
My laptop's motherboard is taken out of the laptop. I have another machine, a desktop PC which I've used for trying rayer_spi programmer. Now I connect the laptop's KB9012's debug pins into the desktop PC motherboard's DIP8 BIOS socket with wires, after it booted the linux distribution with flashrom installed and removing it's original BIOS SPI chip. The two machine's GND, DIP8 socket's GND, and KB9012's pin 42 are united.
Like when recovering a regular motherboard BIOS with hot-swapping chips, just the only difference I connect the laptop's KBC instead of another BIOS chip: https://www.coreboot.org/FAQ#Developers
I think the desktop motherboard's BIOS socket can be used as an SPI programmer this way, originally it has W25Q80BVAIG DIP8 chip which can be removed. That gave me these results, read and write errors which I sent before, but at least it can detect KB9012. I've tested with the original BIOS chip, flashrom can read, erase, and write it. The motherboard is an Asrock G41C-GS first generation, rev 1.0.2.
The laptop can't boot, doesn't even react to power button or recovery key combination, and no charging LED lighting up, since it got bricked with a wrong BIOS update, this is why I want to reflash KB9012 with an external tool, like the desktop PC motherboard's DIP8 socket.
Mike Banon <mikebdp2@gmail.com> ezt írta (időpont: 2019. jan. 14., H, 22:43): > > That is because KB9012 is active after your laptop has booted and not > in debug state where it is possible to reflash it without a problem. > > Have you double checked your laptop's datasheet to make sure your > connection is correct, and also that your laptop's corner ground is > really connected to its' ground? (what if not all its' copper circles > are the grounds in your case) > > On Fri, Jan 11, 2019 at 5:01 PM Nyúlós Lónyál <udpsendtofailed@gmail.com> wrote: > > > > Sorry for double mail. Erasing and writing fails too. > > > > xubuntu@xubuntu:~/flashrom$ sudo ./flashrom -p internal -c "KB9012 (EDI)" -w /home/xubuntu/Desktop/EC-FD-Extract.bin > > flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) > > flashrom is free software, get the source code at https://flashrom.org > > > > Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). > > Found chipset "Intel ICH7/ICH7R". > > Enabling flash write... OK. > > edi_read: Retrying read with greater buffer length! > > edi_read: Retrying read with greater buffer length! > > Found ENE flash chip "KB9012 (EDI)" (128 kB, SPI) mapped at physical address 0x00000000fffe0000. > > Reading old flash chip contents... done. > > Erasing and writing flash chip... edi_chip_block_erase: Timed out waiting for SPI not busy! > > Reading current flash chip contents... done. Looking for another erase function. > > Looking for another erase function. > > Looking for another erase function. > > Looking for another erase function. > > Looking for another erase function. > > Looking for another erase function. > > Looking for another erase function. > > No usable erase functions left. > > FAILED! > > Uh oh. Erase/write failed. Checking if anything has changed. > > Reading current flash chip contents... done. > > Apparently at least some data has changed. > > Your flash chip is in an unknown state. > > Get help on IRC at chat.freenode.net (channel #flashrom) or > > mail flashrom@flashrom.org with the subject "FAILED: <your board name>"! > > ------------------------------------------------------------------------------- > > DO NOT REBOOT OR POWEROFF! > > > > xubuntu@xubuntu:~/flashrom$ sudo ./flashrom -p internal -c "KB9012 (EDI)" -E > > flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) > > flashrom is free software, get the source code at https://flashrom.org > > > > Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). > > Found chipset "Intel ICH7/ICH7R". > > Enabling flash write... OK. > > edi_read: Retrying read with greater buffer length! > > edi_read: Retrying read with greater buffer length! > > Found ENE flash chip "KB9012 (EDI)" (128 kB, SPI) mapped at physical address 0x00000000fffe0000. > > Erasing and writing flash chip... edi_chip_block_erase: Timed out waiting for SPI not busy! > > Looking for another erase function. > > Looking for another erase function. > > Looking for another erase function. > > Looking for another erase function. > > Looking for another erase function. > > Looking for another erase function. > > Looking for another erase function. > > No usable erase functions left. > > FAILED! > > Your flash chip is in an unknown state. > > Get help on IRC at chat.freenode.net (channel #flashrom) or > > mail flashrom@flashrom.org with the subject "FAILED: <your board name>"! > > ------------------------------------------------------------------------------- > > DO NOT REBOOT OR POWEROFF! > > > > Nyúlós Lónyál <udpsendtofailed@gmail.com> ezt írta (időpont: 2019. jan. 11., P, 13:49): > >> > >> Finally managed it to detect KBC's internal flash using the motherboard's BIOS socket with removing it's SPI chip after boot, and connecting KB9012 in there. But the read always gives me different files, so I can't backup the current content of KB9012. > >> > >> xubuntu@xubuntu:~/flashrom$ sudo ./flashrom -p internal -c "KB9012 (EDI)" -r /home/xubuntu/Desktop/ene1.bin > >> flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) > >> flashrom is free software, get the source code at https://flashrom.org > >> > >> Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). > >> Found chipset "Intel ICH7/ICH7R". > >> Enabling flash write... OK. > >> edi_read: Retrying read with greater buffer length! > >> edi_read: Retrying read with greater buffer length! > >> Found ENE flash chip "KB9012 (EDI)" (128 kB, SPI) mapped at physical address 0x00000000fffe0000. > >> Reading flash... done. > >> xubuntu@xubuntu:~/flashrom$ sudo ./flashrom -p internal -c "KB9012 (EDI)" -v /home/xubuntu/Desktop/ene1.bin > >> flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) > >> flashrom is free software, get the source code at https://flashrom.org > >> > >> Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). > >> Found chipset "Intel ICH7/ICH7R". > >> Enabling flash write... OK. > >> edi_read: Retrying read with greater buffer length! > >> edi_read: Retrying read with greater buffer length! > >> Found ENE flash chip "KB9012 (EDI)" (128 kB, SPI) mapped at physical address 0x00000000fffe0000. > >> Verifying flash... FAILED at 0x000034c2! Expected=0xff, Found=0x78, failed byte count from 0x00000000-0x0001ffff: 0x6c52 > >> > >> > >> Nyúlós Lónyál <udpsendtofailed@gmail.com> ezt írta (időpont: 2019. jan. 10., Cs, 12:14): > >>> > >>> Yea, tried to discharge the motherboard, taken out CMOS battery too, it didn't help. I don't know if this is programmer related or not, I have reflashed 2 types of BIOS SPI chips with it, EN25QH16 and W25Q32BV. But these chips are maybe different from KB9012's debug interface. I can't get a CH341A for now, maybe some months later. It would be good to recover the laptop if it's possible with the tools I have currently, but not very urgent. Here is the programmer's config, if it helps: https://github.com/flashrom/flashrom/blob/master/rayer_spi.c > >>> > >>> Mike Banon <mikebdp2@gmail.com> ezt írta (időpont: 2019. jan. 9., Sze, 18:59): > >>>> > >>>> Just to double-check: please discharge the motherboard completely by > >>>> trying to turn it on while there is no power adapter connected, then > >>>> unite three grounds (KB9012 / programmer / motherboard ) and only then > >>>> connect the board's power adapter . After doing all that, please check > >>>> if you could read it now. Also, what if your issues are programmer > >>>> related? Is it possible for you to try another programmer, like CH341A > >>>> ? (because it costs like $2-$3 with free shipping from china, just > >>>> prefer to get a green PCB version because there were some 3.3/5V > >>>> issues with some black PCB CH341A , and blue PCB version costs the > >>>> same low price while having fewer pins) Or maybe you could get it > >>>> locally for a (hopefully) small premium if you're in hurry > >>>> > >>>> On Wed, Jan 9, 2019 at 3:20 PM Nyúlós Lónyál <udpsendtofailed@gmail.com> wrote: > >>>> > > >>>> > Hi Mike! > >>>> > > >>>> > I've followed the linked guide, it gave me these results. The grounds are united, still the same error happens. I have tried to GND pin 42 of KB9012 as mentioned in the guide, and tried to connect both pin 41 and 42 to GND, as in KBC's datasheet at EDI related part, still no success, flashrom doesn't detect it. > >>>> > > >>>> > Mike Banon <mikebdp2@gmail.com> ezt írta (időpont: 2019. jan. 8., K, 16:08): > >>>> >> > >>>> >> Hi Nyulos, > >>>> >> Have you tried following the KB9012 flashing instructions at > >>>> >> DangerousPrototypes wiki? > >>>> >> http://dangerousprototypes.com/docs/Flashing_KB9012_with_Bus_Pirate > >>>> >> Although that is for Bus Pirate / CH341A programmers and LA-A091P, > >>>> >> should be similar for your Rayer programmer and LA-8241P motherboard. > >>>> >> Most importantly, before plugging the power adapter you should unite > >>>> >> three grounds: > >>>> >> 1) GND of laptop's motherboard > >>>> >> 2) GND of your programmer > >>>> >> 3) GND of KB9012 > >>>> >> Best regards, > >>>> >> Mike Banon > >>>> >> > >>>> >> On Tue, Jan 8, 2019 at 3:30 PM Nyúlós Lónyál <udpsendtofailed@gmail.com> wrote: > >>>> >> > > >>>> >> > Hi! > >>>> >> > > >>>> >> > I'm trying to flash an ENE KB9012QF A3 KBC on LA-8241P motherboard. The problem is flashrom can't detect the internal SPI of it, fails with error. > >>>> >> > > >>>> >> > flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64) > >>>> >> > flashrom is free software, get the source code at https://flashrom.org > >>>> >> > > >>>> >> > flashrom was built with libpci 3.5.2, GCC 7.3.0, little endian > >>>> >> > Command line (5 args): ./flashrom -p rayer_spi -c KB9012 (EDI) -V > >>>> >> > Using clock_gettime for delay loops (clk_id: 1, resolution: 1ns). > >>>> >> > Initializing rayer_spi programmer > >>>> >> > Using address 0x378 as I/O base for parallel port access. > >>>> >> > Using RayeR SPIPGM pinout. > >>>> >> > The following protocols are supported: SPI. > >>>> >> > Probing for ENE KB9012 (EDI), 128 kB: edi_chip_probe: reading hwversion failed > >>>> >> > No EEPROM/flash device found. > >>>> >> > Note: flashrom can never write if the flash chip isn't found automatically. > >>>> >> > > >>>> >> > How to get it working? Thanks a lot for help! > >>>> >> > _______________________________________________ > >>>> >> > flashrom mailing list -- flashrom@flashrom.org > >>>> >> > To unsubscribe send an email to flashrom-leave@flashrom.org
There are some programmer_delay values in ichspi.c, here is one which says
something about frequency:
timeout = 100 * 60; /* 60 ms are 9.6 million cycles at 16 MHz. */
while ((REGREAD16(ICH7_REG_SPIS) & SPIS_SCIP) && --timeout) {
programmer_delay(10);
So I just need to increase programmer_delay, for example to 20 and maybe
the timeout to 200 * 60?
I can try another method too as the KB9012 datasheet says "To enable EDI,
it is by detecting any SPI command with EDI_CLK frequency between 1MHz to 8
MHz.", so maybe after probing with flashrom in DIP8 socket, and connecting
it to rayer_spi LPT it will detect and flash KB9012 correctly with lower
SPI frequency.
And yes, I know getting a CH341A would be the easiest way to solve my
problem, but I'm currently not at home, so I should wait with it for some
months, that's a long story. :/ I'm just trying what I can do to spend the
waiting time useful and maybe as result with solving this earlier.
Mike Banon <mikebdp2@gmail.com> ezt írta (időpont: 2019. jan. 20., V, 9:39):
> Maybe try inserting some extra programmer_delay(n) to your ichspi.c ?
> Also I had a patch for the unreliable flashing environments -
> https://review.coreboot.org/c/flashrom/+/23840 - but didn't improve it
> yet so it haven't been merged, and already incompatible with the
> latest flashrom. Also maybe it doesn't affect KB9012 if its' flashing
> functions are different, but maybe it could be useful somehow. Still I
> hope that you've already ordered that CH341A since it costs very
> cheap, just $2-$3, and could save a lot of your time.
>
> On Sun, Jan 20, 2019 at 3:35 AM Nyúlós Lónyál <udpsendtofailed@gmail.com>
> wrote:
> >
> > Thanks for replying at my noob questions. :) The spispeed parameter,
> yea, I thought about it after looking into flashrom's source on GitHub.
> Sadly it's not in the code of ICH7 chipset (ichspi.c), so the spispeed
> option in flashrom command is unavailable. Someone already did that for AMD
> SB600 chipset (sb600spi.c), found a link about it:
> https://mail.coreboot.org/pipermail/flashrom/2013-August/011410.html
> >
> > I don't know much about C programming language, so I can't transform
> that code for ICH7. I have no more ideas, maybe it's possible to modify the
> default SPI frequency in ichspi.c, I'm not sure.
> >
> > Mike Banon <mikebdp2@gmail.com> ezt írta (időpont: 2019. jan. 19., Szo,
> 23:25):
> >>
> >> Sorry for a long reply, I just watched your video and - unless you
> >> changed its' speed - it seems to me that your KB9012 operations are
> >> going faster than expected, e.g. it reached 0x4*** address almost
> >> instantly while in my CH341A case it was almost certainly slower. So
> >> maybe you could experiment with spispeed parameter, like flashrom -p
> >> internal:spispeed=frequency , please look it up online ( I can't at
> >> the moment )
> >>
> >>
> >> On Wed, Jan 16, 2019 at 5:01 PM Nyúlós Lónyál <
> udpsendtofailed@gmail.com> wrote:
> >> >
> >> > Same problem with 5cm long copper wires. Here is a video of what's
> happening: https://www.youtube.com/watch?v=JlbRGK9_gPg
> >> >
> >> > Nyúlós Lónyál <udpsendtofailed@gmail.com> ezt írta (időpont: 2019.
> jan. 16., Sze, 1:38):
> >> >>
> >> >> The wires are ~20-25cm made of aluminium, but I have some broken USB
> cables with copper wires. I can reduce the distance of laptop's keyboard
> connector and DIP8 socket to about 5cm wire length, will give it a try
> tomorrow. And something that I've noticed at verifying with flashrom, it
> always gives a random hex number after "failed byte count from
> 0x00000000-0x0001ffff". Maybe the "Timed out waiting for SPI not busy!"
> error is caused by the wires too. Thanks for the idea, I will reply back
> with results.
> >> >>
> >> >> Mike Banon <mikebdp2@gmail.com> ezt írta (időpont: 2019. jan. 16.,
> Sze, 1:09):
> >> >>>
> >> >>> Sorry if I've already asked this question, but how long are your
> >> >>> wires? Ideally they should be about 10cm length and made of good
> >> >>> copper. Although it could work even for 30cm poor aluminum wires,
> >> >>> still when there are read/write errors - the first suggestion which
> >> >>> comes to my mind is to shorten the wires. I understand that it could
> >> >>> be difficult to use short wires at your flashing setup, but hope it
> is
> >> >>> possible for you to try. And also I hope that you've ordered CH341A
> >> >>> just in case our suggestions wouldn't work.
> >> >>> > The laptop can't boot, doesn't even react to power button or
> recovery key combination, and no charging LED lighting up
> >> >>> Everything from this list is expected if there is a corrupted KB9012
> >> >>> firmware, because it is KB9012 which listens for your power button
> >> >>> keypresses / controls the LEDs / etc
> >> >>>
> >> >>> On Tue, Jan 15, 2019 at 2:44 PM Nyúlós Lónyál <
> udpsendtofailed@gmail.com> wrote:
> >> >>> >
> >> >>> > Sorry for the confusion. :( I think you have misunderstood me.
> >> >>> >
> >> >>> > My laptop's motherboard is taken out of the laptop. I have
> another machine, a desktop PC which I've used for trying rayer_spi
> programmer. Now I connect the laptop's KB9012's debug pins into the desktop
> PC motherboard's DIP8 BIOS socket with wires, after it booted the linux
> distribution with flashrom installed and removing it's original BIOS SPI
> chip. The two machine's GND, DIP8 socket's GND, and KB9012's pin 42 are
> united.
> >> >>> >
> >> >>> > Like when recovering a regular motherboard BIOS with hot-swapping
> chips, just the only difference I connect the laptop's KBC instead of
> another BIOS chip: https://www.coreboot.org/FAQ#Developers
> >> >>> >
> >> >>> > I think the desktop motherboard's BIOS socket can be used as an
> SPI programmer this way, originally it has W25Q80BVAIG DIP8 chip which can
> be removed. That gave me these results, read and write errors which I sent
> before, but at least it can detect KB9012. I've tested with the original
> BIOS chip, flashrom can read, erase, and write it. The motherboard is an
> Asrock G41C-GS first generation, rev 1.0.2.
> >> >>> >
> >> >>> > The laptop can't boot, doesn't even react to power button or
> recovery key combination, and no charging LED lighting up, since it got
> bricked with a wrong BIOS update, this is why I want to reflash KB9012 with
> an external tool, like the desktop PC motherboard's DIP8 socket.
> >> >>> >
> >> >>> > Mike Banon <mikebdp2@gmail.com> ezt írta (időpont: 2019. jan.
> 14., H, 22:43):
> >> >>> >>
> >> >>> >> That is because KB9012 is active after your laptop has booted
> and not
> >> >>> >> in debug state where it is possible to reflash it without a
> problem.
> >> >>> >>
> >> >>> >> Have you double checked your laptop's datasheet to make sure your
> >> >>> >> connection is correct, and also that your laptop's corner ground
> is
> >> >>> >> really connected to its' ground? (what if not all its' copper
> circles
> >> >>> >> are the grounds in your case)
> >> >>> >>
> >> >>> >> On Fri, Jan 11, 2019 at 5:01 PM Nyúlós Lónyál <
> udpsendtofailed@gmail.com> wrote:
> >> >>> >> >
> >> >>> >> > Sorry for double mail. Erasing and writing fails too.
> >> >>> >> >
> >> >>> >> > xubuntu@xubuntu:~/flashrom$ sudo ./flashrom -p internal -c
> "KB9012 (EDI)" -w /home/xubuntu/Desktop/EC-FD-Extract.bin
> >> >>> >> > flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64)
> >> >>> >> > flashrom is free software, get the source code at
> https://flashrom.org
> >> >>> >> >
> >> >>> >> > Using clock_gettime for delay loops (clk_id: 1, resolution:
> 1ns).
> >> >>> >> > Found chipset "Intel ICH7/ICH7R".
> >> >>> >> > Enabling flash write... OK.
> >> >>> >> > edi_read: Retrying read with greater buffer length!
> >> >>> >> > edi_read: Retrying read with greater buffer length!
> >> >>> >> > Found ENE flash chip "KB9012 (EDI)" (128 kB, SPI) mapped at
> physical address 0x00000000fffe0000.
> >> >>> >> > Reading old flash chip contents... done.
> >> >>> >> > Erasing and writing flash chip... edi_chip_block_erase: Timed
> out waiting for SPI not busy!
> >> >>> >> > Reading current flash chip contents... done. Looking for
> another erase function.
> >> >>> >> > Looking for another erase function.
> >> >>> >> > Looking for another erase function.
> >> >>> >> > Looking for another erase function.
> >> >>> >> > Looking for another erase function.
> >> >>> >> > Looking for another erase function.
> >> >>> >> > Looking for another erase function.
> >> >>> >> > No usable erase functions left.
> >> >>> >> > FAILED!
> >> >>> >> > Uh oh. Erase/write failed. Checking if anything has changed.
> >> >>> >> > Reading current flash chip contents... done.
> >> >>> >> > Apparently at least some data has changed.
> >> >>> >> > Your flash chip is in an unknown state.
> >> >>> >> > Get help on IRC at chat.freenode.net (channel #flashrom) or
> >> >>> >> > mail flashrom@flashrom.org with the subject "FAILED: <your
> board name>"!
> >> >>> >> >
> -------------------------------------------------------------------------------
> >> >>> >> > DO NOT REBOOT OR POWEROFF!
> >> >>> >> >
> >> >>> >> > xubuntu@xubuntu:~/flashrom$ sudo ./flashrom -p internal -c
> "KB9012 (EDI)" -E
> >> >>> >> > flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64)
> >> >>> >> > flashrom is free software, get the source code at
> https://flashrom.org
> >> >>> >> >
> >> >>> >> > Using clock_gettime for delay loops (clk_id: 1, resolution:
> 1ns).
> >> >>> >> > Found chipset "Intel ICH7/ICH7R".
> >> >>> >> > Enabling flash write... OK.
> >> >>> >> > edi_read: Retrying read with greater buffer length!
> >> >>> >> > edi_read: Retrying read with greater buffer length!
> >> >>> >> > Found ENE flash chip "KB9012 (EDI)" (128 kB, SPI) mapped at
> physical address 0x00000000fffe0000.
> >> >>> >> > Erasing and writing flash chip... edi_chip_block_erase: Timed
> out waiting for SPI not busy!
> >> >>> >> > Looking for another erase function.
> >> >>> >> > Looking for another erase function.
> >> >>> >> > Looking for another erase function.
> >> >>> >> > Looking for another erase function.
> >> >>> >> > Looking for another erase function.
> >> >>> >> > Looking for another erase function.
> >> >>> >> > Looking for another erase function.
> >> >>> >> > No usable erase functions left.
> >> >>> >> > FAILED!
> >> >>> >> > Your flash chip is in an unknown state.
> >> >>> >> > Get help on IRC at chat.freenode.net (channel #flashrom) or
> >> >>> >> > mail flashrom@flashrom.org with the subject "FAILED: <your
> board name>"!
> >> >>> >> >
> -------------------------------------------------------------------------------
> >> >>> >> > DO NOT REBOOT OR POWEROFF!
> >> >>> >> >
> >> >>> >> > Nyúlós Lónyál <udpsendtofailed@gmail.com> ezt írta (időpont:
> 2019. jan. 11., P, 13:49):
> >> >>> >> >>
> >> >>> >> >> Finally managed it to detect KBC's internal flash using the
> motherboard's BIOS socket with removing it's SPI chip after boot, and
> connecting KB9012 in there. But the read always gives me different files,
> so I can't backup the current content of KB9012.
> >> >>> >> >>
> >> >>> >> >> xubuntu@xubuntu:~/flashrom$ sudo ./flashrom -p internal -c
> "KB9012 (EDI)" -r /home/xubuntu/Desktop/ene1.bin
> >> >>> >> >> flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64)
> >> >>> >> >> flashrom is free software, get the source code at
> https://flashrom.org
> >> >>> >> >>
> >> >>> >> >> Using clock_gettime for delay loops (clk_id: 1, resolution:
> 1ns).
> >> >>> >> >> Found chipset "Intel ICH7/ICH7R".
> >> >>> >> >> Enabling flash write... OK.
> >> >>> >> >> edi_read: Retrying read with greater buffer length!
> >> >>> >> >> edi_read: Retrying read with greater buffer length!
> >> >>> >> >> Found ENE flash chip "KB9012 (EDI)" (128 kB, SPI) mapped at
> physical address 0x00000000fffe0000.
> >> >>> >> >> Reading flash... done.
> >> >>> >> >> xubuntu@xubuntu:~/flashrom$ sudo ./flashrom -p internal -c
> "KB9012 (EDI)" -v /home/xubuntu/Desktop/ene1.bin
> >> >>> >> >> flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic (x86_64)
> >> >>> >> >> flashrom is free software, get the source code at
> https://flashrom.org
> >> >>> >> >>
> >> >>> >> >> Using clock_gettime for delay loops (clk_id: 1, resolution:
> 1ns).
> >> >>> >> >> Found chipset "Intel ICH7/ICH7R".
> >> >>> >> >> Enabling flash write... OK.
> >> >>> >> >> edi_read: Retrying read with greater buffer length!
> >> >>> >> >> edi_read: Retrying read with greater buffer length!
> >> >>> >> >> Found ENE flash chip "KB9012 (EDI)" (128 kB, SPI) mapped at
> physical address 0x00000000fffe0000.
> >> >>> >> >> Verifying flash... FAILED at 0x000034c2! Expected=0xff,
> Found=0x78, failed byte count from 0x00000000-0x0001ffff: 0x6c52
> >> >>> >> >>
> >> >>> >> >>
> >> >>> >> >> Nyúlós Lónyál <udpsendtofailed@gmail.com> ezt írta (időpont:
> 2019. jan. 10., Cs, 12:14):
> >> >>> >> >>>
> >> >>> >> >>> Yea, tried to discharge the motherboard, taken out CMOS
> battery too, it didn't help. I don't know if this is programmer related or
> not, I have reflashed 2 types of BIOS SPI chips with it, EN25QH16 and
> W25Q32BV. But these chips are maybe different from KB9012's debug
> interface. I can't get a CH341A for now, maybe some months later. It would
> be good to recover the laptop if it's possible with the tools I have
> currently, but not very urgent. Here is the programmer's config, if it
> helps: https://github.com/flashrom/flashrom/blob/master/rayer_spi.c
> >> >>> >> >>>
> >> >>> >> >>> Mike Banon <mikebdp2@gmail.com> ezt írta (időpont: 2019.
> jan. 9., Sze, 18:59):
> >> >>> >> >>>>
> >> >>> >> >>>> Just to double-check: please discharge the motherboard
> completely by
> >> >>> >> >>>> trying to turn it on while there is no power adapter
> connected, then
> >> >>> >> >>>> unite three grounds (KB9012 / programmer / motherboard )
> and only then
> >> >>> >> >>>> connect the board's power adapter . After doing all that,
> please check
> >> >>> >> >>>> if you could read it now. Also, what if your issues are
> programmer
> >> >>> >> >>>> related? Is it possible for you to try another programmer,
> like CH341A
> >> >>> >> >>>> ? (because it costs like $2-$3 with free shipping from
> china, just
> >> >>> >> >>>> prefer to get a green PCB version because there were some
> 3.3/5V
> >> >>> >> >>>> issues with some black PCB CH341A , and blue PCB version
> costs the
> >> >>> >> >>>> same low price while having fewer pins) Or maybe you could
> get it
> >> >>> >> >>>> locally for a (hopefully) small premium if you're in hurry
> >> >>> >> >>>>
> >> >>> >> >>>> On Wed, Jan 9, 2019 at 3:20 PM Nyúlós Lónyál <
> udpsendtofailed@gmail.com> wrote:
> >> >>> >> >>>> >
> >> >>> >> >>>> > Hi Mike!
> >> >>> >> >>>> >
> >> >>> >> >>>> > I've followed the linked guide, it gave me these results.
> The grounds are united, still the same error happens. I have tried to GND
> pin 42 of KB9012 as mentioned in the guide, and tried to connect both pin
> 41 and 42 to GND, as in KBC's datasheet at EDI related part, still no
> success, flashrom doesn't detect it.
> >> >>> >> >>>> >
> >> >>> >> >>>> > Mike Banon <mikebdp2@gmail.com> ezt írta (időpont: 2019.
> jan. 8., K, 16:08):
> >> >>> >> >>>> >>
> >> >>> >> >>>> >> Hi Nyulos,
> >> >>> >> >>>> >> Have you tried following the KB9012 flashing
> instructions at
> >> >>> >> >>>> >> DangerousPrototypes wiki?
> >> >>> >> >>>> >>
> http://dangerousprototypes.com/docs/Flashing_KB9012_with_Bus_Pirate
> >> >>> >> >>>> >> Although that is for Bus Pirate / CH341A programmers and
> LA-A091P,
> >> >>> >> >>>> >> should be similar for your Rayer programmer and LA-8241P
> motherboard.
> >> >>> >> >>>> >> Most importantly, before plugging the power adapter you
> should unite
> >> >>> >> >>>> >> three grounds:
> >> >>> >> >>>> >> 1) GND of laptop's motherboard
> >> >>> >> >>>> >> 2) GND of your programmer
> >> >>> >> >>>> >> 3) GND of KB9012
> >> >>> >> >>>> >> Best regards,
> >> >>> >> >>>> >> Mike Banon
> >> >>> >> >>>> >>
> >> >>> >> >>>> >> On Tue, Jan 8, 2019 at 3:30 PM Nyúlós Lónyál <
> udpsendtofailed@gmail.com> wrote:
> >> >>> >> >>>> >> >
> >> >>> >> >>>> >> > Hi!
> >> >>> >> >>>> >> >
> >> >>> >> >>>> >> > I'm trying to flash an ENE KB9012QF A3 KBC on LA-8241P
> motherboard. The problem is flashrom can't detect the internal SPI of it,
> fails with error.
> >> >>> >> >>>> >> >
> >> >>> >> >>>> >> > flashrom p1.0-141-g9cecc7e on Linux 4.15.0-20-generic
> (x86_64)
> >> >>> >> >>>> >> > flashrom is free software, get the source code at
> https://flashrom.org
> >> >>> >> >>>> >> >
> >> >>> >> >>>> >> > flashrom was built with libpci 3.5.2, GCC 7.3.0,
> little endian
> >> >>> >> >>>> >> > Command line (5 args): ./flashrom -p rayer_spi -c
> KB9012 (EDI) -V
> >> >>> >> >>>> >> > Using clock_gettime for delay loops (clk_id: 1,
> resolution: 1ns).
> >> >>> >> >>>> >> > Initializing rayer_spi programmer
> >> >>> >> >>>> >> > Using address 0x378 as I/O base for parallel port
> access.
> >> >>> >> >>>> >> > Using RayeR SPIPGM pinout.
> >> >>> >> >>>> >> > The following protocols are supported: SPI.
> >> >>> >> >>>> >> > Probing for ENE KB9012 (EDI), 128 kB: edi_chip_probe:
> reading hwversion failed
> >> >>> >> >>>> >> > No EEPROM/flash device found.
> >> >>> >> >>>> >> > Note: flashrom can never write if the flash chip isn't
> found automatically.
> >> >>> >> >>>> >> >
> >> >>> >> >>>> >> > How to get it working? Thanks a lot for help!
> >> >>> >> >>>> >> > _______________________________________________
> >> >>> >> >>>> >> > flashrom mailing list -- flashrom@flashrom.org
> >> >>> >> >>>> >> > To unsubscribe send an email to
> flashrom-leave@flashrom.org
>
Hi Nyúlós, On 20.01.19 12:46, Nyúlós Lónyál wrote:
There are some programmer_delay values in ichspi.c, here is one which says something about frequency:
timeout = 100 * 60; /* 60 ms are 9.6 million cycles at 16 MHz. */ while ((REGREAD16(ICH7_REG_SPIS) & SPIS_SCIP) && --timeout) { programmer_delay(10);
So I just need to increase programmer_delay, for example to 20 and maybe the timeout to 200 * 60?
no, this has nothing to do with the transmission speed, it's really just a polling loop with a timeout. Generally, the ichspi (both hardware and driver) expect a perfect connection to the SPI slave... plus the hard- ware might make assumptions about the type of commands used. It's not meant to work with your setup, so you need a lot of luck.
I can try another method too as the KB9012 datasheet says "To enable EDI, it is by detecting any SPI command with EDI_CLK frequency between 1MHz to 8 MHz.",
According to its datasheet the ICH7 runs its SPI clock at 17.9MHz. It's not completely hopeless, though.
so maybe after probing with flashrom in DIP8 socket, and connecting it to rayer_spi LPT it will detect and flash KB9012 correctly with lower SPI frequency.
Sounds like a fragile procedure, make sure that you never have the ICH and Rayer connected at the same time. Also, what Mike said about the wire length applies to your setup with the Rayer, too. Nico
Hi Nico! Thanks for explaining. :) So what can I do in this case? Which programmer is the easiest to get the setup working? Rayer_SPI didn't even detect it, nor with shorter wires, this is why I went to ICH7, at least it can recognize KB9012, and read some random data from it. I will not connect both programmers at the same time, but I have a theory Rayer_SPI doesn't give SPI clock signal continuously, thus KB9012 didn't enter EDI mode. Nico Huber <nico.h@gmx.de> ezt írta (időpont: 2019. jan. 20., V, 13:39):
Hi Nyúlós,
On 20.01.19 12:46, Nyúlós Lónyál wrote:
There are some programmer_delay values in ichspi.c, here is one which says something about frequency:
timeout = 100 * 60; /* 60 ms are 9.6 million cycles at 16 MHz. */ while ((REGREAD16(ICH7_REG_SPIS) & SPIS_SCIP) && --timeout) { programmer_delay(10);
So I just need to increase programmer_delay, for example to 20 and maybe the timeout to 200 * 60?
no, this has nothing to do with the transmission speed, it's really just a polling loop with a timeout. Generally, the ichspi (both hardware and driver) expect a perfect connection to the SPI slave... plus the hard- ware might make assumptions about the type of commands used. It's not meant to work with your setup, so you need a lot of luck.
I can try another method too as the KB9012 datasheet says "To enable EDI, it is by detecting any SPI command with EDI_CLK frequency between 1MHz
to 8
MHz.",
According to its datasheet the ICH7 runs its SPI clock at 17.9MHz. It's not completely hopeless, though.
so maybe after probing with flashrom in DIP8 socket, and connecting it to rayer_spi LPT it will detect and flash KB9012 correctly with lower SPI frequency.
Sounds like a fragile procedure, make sure that you never have the ICH and Rayer connected at the same time. Also, what Mike said about the wire length applies to your setup with the Rayer, too.
Nico
participants (4)
-
awokd -
Mike Banon -
Nico Huber -
Nyúlós Lónyál