Oct 282012
 

“Updating your BIOS” has a tendency to be a bit of a white-knuckle chore. Fraught with opportunity to use lots of non-free legacy tools and even if you make an effort to use all free software the actual flashing tool (not to mention the code in the BIOS firmware that you are flashing.) is historically non-free software. owflash32.exe? Sounds like something that would make me want to install clamav 🙂

Well, my free software loving friends, that doesn’t have to be the case! You can use
Flashrom

Developed by the same crowd that brought you coreboot; flashrom’s a tool that can read, write and erase flash chips like the ones that typically hold the BIOS image on a motherboard. Sort of like that brikflash32.exe that you used to download from your motherboard vendor, except instead of needing to find that 15 year old bootable floppy disk, it’s just an apt-get away. And you don’t even need to reboot. When things go well it’s as easy as:

#flashrom -p internal -w newbios.rom

You do still want to pay attention, as of course if you do manage to improperly flash the chip, it can be difficult or even impossible to recover. But flashrom is pretty good about keeping you out of that situation. While the software has no mechanism to verify that the image you’re trying to flash is appropriate for your board; it does automatically verify that your source file and the chip’s image match exactly and gives very clear feedback if anything goes wrong.

Uh oh. Erase/write failed. Checking if anything changed.
Your flash chip is in an unknown state.
Get help on IRC at chat.freenode.net (channel #flashrom) or
mail flashrom@flashrom.org with the subject "FAILED: "!
-------------------------------------------------------------------------------
DO NOT REBOOT OR POWEROFF!

Just Kidding! that _never_ happens. (Or at least not often, unless you use the “–programmer internal:laptop=force_I_want_a_brick” option (not kidding that time.)

Unfortunately flashrom will refuse to flash most laptops, as the extra bit of hardware that laptops have, the “Embedded Controller” that handles battery charging and blinkenlights is often intermingled with the BIOS in undocumented and crash-prone ways.
You may have seen, that I’m excited to get coreboot running on some laptops. And that flashrom needs it’s hand held a bit to work in that situation. I’ll tell you that story some time too. (spoiler: it’s working)

But the next time you’re flashing a Desktop BIOS; or did I mention it also works great for updating the firmware on things like RAID controllers or updating the bootrom on your NIC? Give it a try; or haul that machine to the next glug meeting, and we’ll lend some cheerful and wreckless encouragement.

Aug 162012
 

Coreboot (formerly known as LinuxBIOS) is a free software project aimed at replacing the proprietary BIOS firmware with a free system for loading and running the operating system.
There are very few laptops available that are able to run properly when flashed with coreboot. Sam has found a lenovo x60 6365CTO tablet and will attempt to use a program called flashrom to put Coreboot (with a SeaBIOS payload) on this machine.
Unfortunately due to limitations of the IBM/Lenovo factory BIOS, flashrom can not detect which of the many flash chips that were used in the various revisions of these machines is present. At least not with enough specificity to be confident that the flash will be correct. So the solution is to disassembble the laptop and identify the chip visually!

At tonights meeting we worked taking apart the x60 tablet. Sam and Rob (Jason helped some too) dug into the tablet and stripped it all the way down to the motherboard. It was even harder to find the actual bios chip, as we did not know where it would be located on the board. We did know that it would be a SOIC8 chip (8 pins connecting to the motherboard) with extremely small writing on it.

Eventually we found a likely part, but after scraping off a sticker (we’ll assume it had a factory bios revision level or some such on it.) Sam declared; “That’s not it, it is supposed to have some writing on it.” The markings are that feint.
After lots of straining with a magnifier we deciphered “SST25VF016B”.

Hurray, a known part supported by flashrom!