lbwww/site/docs/install/e6430.md

6.8 KiB

NOTE (15 October 2023): The util is now called dell-flash-unlock, but it was previously called e6400-flash-unlock. Links have been updated.

BSD boots and works properly on these machines, but take note:

Nicholas's dell-flash-unlock utility has been ported to OpenBSD, but other BSDs are assumed unsupported for now.

NOTE: Libreboot standardises on flashprog now, as of 27 January 2024, which is a fork of flashrom.

NOTE: BSD is mentioned above, but the only BSD tested for dell-flash-unlock is OpenBSD, as of 15 October 2023.

Flashing from Linux

MAKE SURE you boot with this Linux kernel parameter: iomem=relaxed - this disables memory protections, permitting /dev/mem access needed by flashprog. The flash is memory mapped and flashprog accesses it via /dev/mem.

You can flash Libreboot directly from the vendor (Dell) BIOS, without taking the machine apart. It can be done entirely from Linux. It will probably also work on BSD systems, but it has only been testing on Linux thus far.

NOTE (15 October 2023): The util is now called dell-flash-unlock, but it was previously called e6400-flash-unlock. Links have been updated.

Check util/dell-flash-unlock in the lbmk.git repository, or in release archives for Libreboot releases from 20230423 onwards.

Go in there:

cd util/dell-flash-unlock
make

With this program, you can unlock the flash in such a way where everything is writeable. Information about how to use it is in the README.md file which is included in that program's directory, or you can read it online here:

https://browse.libreboot.org/lbmk.git/plain/util/dell-flash-unlock/README.md

Literally just run that program, and do what it says. You run it once, shut down, and then power on the machine. Then run it again to confirm that the flash is unlocked. The source code is intuitive enough that you can easily get the gist of it; it's writing some EC commands and changing some chipset config bits. The EC on this machine is hooked up to the HDA_SDO signal, also known as the Flash Descriptor Override (FDO), which disables any flash protection by the IFD. When booted with the FDO set, the original Dell firmware disables all other BIOS write protections such as SMM BIOS lock bits.

Make sure to make a backup of the original firmware before proceeding to flash; see the instructions below.

When you flash it, you can use this command:

flashprog -p internal -w libreboot.rom

Where libreboot.rom is your E6430 ROM. Make sure it's the right one. If flashprog complains about multiple flash chips detected, just pick one of them (doesn't matter which one), with the -C flag as directed; just pick one, and if it doesn't work, try the next.

When you see flashprog say VERIFIED at the end, that means the flash was successful. If you don't see that, or you're unsure, please contact the Libreboot project via IRC.

BACK UP THE FACTORY BIOS

The -w option flashes libreboot.rom. You may consider backing up the original Dell BIOS first, using the -r option:

flashprog -p internal -r backup.rom

AGAIN: make sure to use -C accordingly, if you need to pick a chip (where flashprog has detected multiple chip definitions). Just pick one, any of them will probably work, if not try the next.

Do this while in a flashable state, after the 2nd run of dell-flash-unlock.

Make sure the backup.rom file gets backed up to an external storage media, not the E6430 itself.

With this method, you can probably flash it within 5 minutes. Again, zero disassembly required!

How to flash externally

Refer to spi.md as a guide for external re-flashing.

The SPI flash chip shares a voltage rail with the chipset, which is not isolated using a diode. As a result, powering the flash chip externally may cause the QM77 chipset to partially power up and drive the SPI pins, which can interfere with programmers such as the Raspberry Pi. See RPi Drive Strength for a workaround.

Have a look online for videos showing how to disassemble, if you wish to externally re-flash.