Re: [flashrom] Fwd: Intel QS77 chipet on MBA 2012

2018-10-26 Thread Angel Pons
Hello,

> 0x54: 0x FREG0: Flash Descriptor region (0x-0x0fff) is 
> read-write.
> 0x58: 0x07ff0190 FREG1: BIOS region (0x0019-0x007f) is read-write.
> 0x5C: 0x018f0001 FREG2: Management Engine region (0x1000-0x0018) is 
> read-write.

I see you made all the flash regions read-write. This means region
protections should not be a problem to use flashrom.

> 0x74: 0x866f0190 PR0: Warning: 0x0019-0x0066 is read-only.
> 0x78: 0x9fff0692 PR1: Warning: 0x00692000-0x01ff is read-only.

AFAIK, this means flashing internally a complete image may not work.
However, if you only want to restore the EFI variables region, you
should tell flashrom to only write to the EFI variables region (which
I imagine is not write-protected) using a layout file. Since you know
the rest of the firmware is working properly, it is safer to only
change what is not working.

Best regards,

Angel Pons Pons

___
flashrom mailing list
flashrom@flashrom.org
https://mail.coreboot.org/mailman/listinfo/flashrom


Re: [flashrom] Fwd: Intel QS77 chipet on MBA 2012

2018-10-26 Thread Antonio Ospite
On Thu, 25 Oct 2018 17:22:48 +0200
Nico Huber  wrote:

> Sorry, it seems this one got lost in moderation, forwarding...
>

JFYI I got both this one and what appears to be the original message.

>  Forwarded Message 
> Subject: Intel QS77 chipet on MBA 2012
> Date: Wed, 24 Oct 2018 23:18:40 +0200
> From: Laura Martín 
> To: flashrom@flashrom.org
> 
> Hi all,
> 
> I'm trying to fix a corrupted EFI on a Macbook Air 13'' of 2012. I messed
> up with efibootmgr and that's the result... It's not a locked EFI, in the
> laptop Gentoo is installed, so I can access to the OS, although I can't
> boot from USB.
> 
> So, I modified an EFI-dump for my laptop (I checked out it's not locked as
> well), I made a dump of the current EFI and replaced the serial number and
> other parameters. The size is OK, I checked out with hexdump.
> 
> The stanza to made the write is:
> 
> *# flashrom -p internal:pci=8086:1e56.0 -c "MX25L6406E/MX25L6408E" -V -w
> /home/m00n/nueva.rom*
> 
[...]
> Writes have been disabled for safety reasons. You can enforce write
> support with the ich_spi_force programmer option, but you will most likely
> harm your hardware! If you force flashrom you will get no support if
> something breaks. On a few mainboards it is possible to enable write
> access by setting a jumper (see its documentation or the board itself).

This message from flashrom suggest to use the ich_spi_force option, and
the man page states that it can be used by adding this to the command
line:

  -p internal:ich_spi_force=yes

Flashrom also says:

> Unhandled programmer parameters: pci=8086:1e56.0

I guess the "internal" programmer auto-discovers the PCI device, so
maybe that part can be removed from the -p option.

Your command line becomes:

  # flashrom -p internal:ich_spi_force=yes -c "MX25L6406E/MX25L6408E" -V -w 
/home/m00n/nueva.rom

Note that flashrom also says that it takes no responsibility for any
damage; so, before proceeding, I'd check if flashing externally is
possible/easy, just in case something goes wrong with "-p internal".
 
Ciao,
   Antonio

-- 
Antonio Ospite
https://ao2.it
https://twitter.com/ao2it

A: Because it messes up the order in which people normally read text.
   See http://en.wikipedia.org/wiki/Posting_style
Q: Why is top-posting such a bad thing?

___
flashrom mailing list
flashrom@flashrom.org
https://mail.coreboot.org/mailman/listinfo/flashrom