Okay, so, why would you want to do this? Well, in a nutshell, so your Chromebook pretty much behaves like a normal laptop i.e. no secure boot, will boot from any USB key, no more signing kernels and dd’ing them to obscure partitions, etc, etc. Before you start: It’s important to note this comes without any warranty, express or implied. If something goes wrong you will end up with a bricked Chromebook. If that happens you can purchase a Bus Pirate, Bus Pirate probe cable, and Pomona 5250 SOIC clip and get unbricking, as per my previous post. This will also make ChromeOS unbootable, so if you want to use ChromeOS at all, then don’t do this. The impatient and ill-resourced among you can scroll to the end for instructions on how to download and flash my Coreboot build, which again comes without any warranty and could bring hell and damnation upon your souls. There is now a patch which allows all 4 GB of RAM to be recognised, but it takes 5 seconds to reach the SeaBIOS prompt on a cold boot. First of all you need to make sure the Chromebook is in developer mode as per http://www.chromium.org/chromium-os/developer-information-for-chrome-os-devices/samsung-sandy-bridge and you also need to disable the BIOS write protect jumper which this picture shows you. For reference, I carefully placed a small watch screwdriver in between the 2 pins to make a circuit. Worked for me anyway. ;) On your Chromebook, make a copy of your existing ROM with
sudo flashrom -r bios.bin
Copy it to USB or use SFTP to get it onto your other PC/Laptop. This is extremely important because you may need something to recover from later. Now we have to download the Coreboot sourcecode onto a laptop with a suitable Linux distro, using Git. Obviously we need Git installed, as well as GCC, Ncurses development, and iasl. From your home directory on this machine.
git clone http://review.coreboot.org/p/coreboot
Then go into menuconfig.
Now we need to check and uncheck some options. I don’t list categories here for brevity. Just go into each section to find the options mentioned.
- Uncheck Compress ramstage with LZMA
- Uncheck Include the coreboot .config file into the ROM image
- Check Allow use of binary-only repository
- Change Mainboard Vendor to Samsung, which should automatically change the mainboard to “Lumpy”
- Check Mark graphics memory as write-combining.
- Check Enable VMX for virtualization
- Check Allow for caching system ROM.
- Check Add a System Agent binary
- Check Add a VGA BIOS image.
- Change the binary path to 3rdparty/mainboard/$(MAINBOARDDIR)/snm_2130_coreboot.bin
- Uncheck Serial port console output
- Check Use onboard VGA as primary video device
- Change SeaBIOS version to “master”
- Uncheck Use LZMA compression for payloads
Next we need to make a trivial change to the SeaBIOS source to change the bootmenu key from F12 (because Chromebook’s don’t have F12) From the coreboot directory vim build/seabios/src/boot.c and change the following section like so:
int menukey = romfile_loadint("etc/boot-menu-key", 0x86); printf("%s", bootmsg ?: "\nPress F12 for boot menu.\n\n"); free(bootmsg);
int menukey = romfile_loadint("etc/boot-menu-key", 0x44); printf("%s", bootmsg ?: "\nPress F10 for boot menu.\n\n"); free(bootmsg);
We change the “F12” to “F10” and “0x86” to “0x44”.
The cbfstool printout at the end should look something like this:
Name Offset Type Size cmos_layout.bin 0x400000 cmos_layout 1120 pci8086,0106.rom 0x4004c0 optionrom 65536 cpu_microcode_blob.bin 0x410500 microcode 20544 fallback/romstage 0x4155c0 stage 28660 fallback/coreboot_ram 0x41c600 stage 287464 fallback/payload 0x462940 payload 106916 (empty) 0x47cb40 null 3159128 mrc.cache 0x77ffc0 (unknown) 65536 (empty) 0x790000 null 65432 mrc.bin 0x79ffc0 (unknown) 195732 (empty) 0x7cfcc0 null 49880 spd.bin 0x7dbfc0 (unknown) 1536 (empty) 0x7dc600 null 144216
Copy the coreboot.rom file in build to your Chromebook and write the file to your ROM!
sudo flashrom -w coreboot.rom
Alternatively, as mentioned at the beginning of the post, you can download a prebuilt coreboot from my website, and flash it without much bother. See https://johnlewis.ie/custom-chromebook-firmware/rom-download/
Many thanks to Ron Minnich, Aaron Durbin, Stefan Reinauer and Kyösti Mälkki, on the Coreboot mailing list.