Difference between revisions of "Firmware"

From GalliumOS Wiki
Jump to: navigation, search
m
 
(52 intermediate revisions by 4 users not shown)
Line 1: Line 1:
 
__TOC__
 
__TOC__
 +
 +
== Stock (Factory) vs. Custom Firmware ==
 +
 +
Factory firmware for ChromeOS devices is built for booting ChromeOS, of course. Some models also include the capability of booting other OSes in factory firmware, but most do not (or have serious implementation bugs).
 +
 +
Custom firmware adds the ability to boot GalliumOS to all models, and fixes factory bugs. Some firmware types also improve other functionality. See below for details.
  
 
== Custom Firmware ==
 
== Custom Firmware ==
  
The stock/factory firmware on some Chromebooks and Chromeboxes contains a legacy boot payload (RW_LEGACY) capable of running Linux out of the box; however, many ChromeOS devices, particularly those with BayTrail/Braswell CPUs, do not include this capability stock and must use a 3rd party firmware update in order to run GalliumOS (or any other OS).
+
=== Availability Options ===
 +
 
 +
Check [[Hardware Compatibility]] and the appropriate [[Support]] page to determine the status of your model.
  
Three types of custom firmware updates are available (though not all types are available for every device):  
+
There are different custom firmware options available, depending on your Chromebook/box model class, and the features you require:
 +
 
 +
{| class="wikitable"
 +
|-
 +
! scope="col"|
 +
! scope="col"| [https://mrchromebox.tech MrChromebox]
 +
|-
 +
| ARM
 +
| style="text-align:center;background-color:#ffe8e8" | No
 +
|-
 +
| Pineview
 +
| style="text-align:center;background-color:#ffe8e8" | No
 +
|-
 +
| Sandy/Ivy Bridge
 +
| style="text-align:center;background-color:#ccffcc" | Full Firmware [UEFI] (all)<br>RW_LEGACY (LINK)
 +
|-
 +
| Haswell
 +
| style="text-align:center;background-color:#ccffcc" | Full Firmware [UEFI] (all)<br>Full Firmware [Legacy] (Chromeboxes)<br>RW_LEGACY (all)
 +
|-
 +
| Broadwell
 +
| style="text-align:center;background-color:#ccffcc" | Full Firmware [UEFI] (all)<br>Full Firmware [Legacy] (Chromeboxes)<br>RW_LEGACY (all)
 +
|-
 +
| Bay Trail
 +
| style="text-align:center;background-color:#ccffcc" | Full Firmware [UEFI] (all)<br>RW_LEGACY (all)
 +
|-
 +
| Braswell
 +
| style="text-align:center;background-color:#ccffcc" | Full Firmware [UEFI] (all)<br>RW_LEGACY (all)
 +
|-
 +
| Skylake
 +
| style="text-align:center;background-color:#ccffcc" | Full Firmware [UEFI] (all)<br>RW_LEGACY (all)
 +
|-
 +
| Apollo Lake
 +
| style="text-align:center;background-color:#ccffcc" | RW_LEGACY (all)
 +
|-
 +
| Kaby Lake
 +
| style="text-align:center;background-color:#ccffcc" | Full Firmware [UEFI] (all)<br>RW_LEGACY (all)
 +
|-
 +
| Gemini Lake
 +
| style="text-align:center;background-color:#ffe8e8" | No
 +
|-
 +
| Whiskey Lake
 +
| style="text-align:center;background-color:#ccffcc" | RW_LEGACY (all) Tianocore via AltFW
 +
|-
 +
| AMD Stoney Ridge
 +
| style="text-align:center;background-color:#ccffcc" | RW_LEGACY (all)
 +
|-
 +
| notes
 +
| • Easy Install via the [https://mrchromebox.tech/#fwscript Firmware Utility Script]<br>• Offers both UEFI and Legacy boot support for many models<br>• Fixes factory firmware bugs<br>• Built using latest upstream sources<br>• Headless boot support for servers<br>• PXE booting support (legacy only)<br>• UEFI firmware fully supports Windows as well as Linux<br>• [https://github.com/MrChromebox/coreboot Firmware source/build scripts] and payload sources ( [https://github.com/MrChromebox/SeaBIOS Legacy], [https://github.com/MrChromebox/edk2 UEFI])<br>
 +
|-
 +
! scope="col"|
 +
! scope="col"| [https://mrchromebox.tech/#fwscript Download/Install]
 +
|}
 +
 
 +
Custom firmware builds for some models were previously available from CoolStar and John Lewis. That firmware is no longer recommended nor supported (by us or them).
 +
 
 +
If you're running older firmware, you should strongly consider updating to a current build from MrChromebox. [https://mrchromebox.tech Full info], and [https://mrchromebox.tech/#fwscript Install script].
  
 
=== Types ===
 
=== Types ===
 +
 
# '''RW_LEGACY'''
 
# '''RW_LEGACY'''
#* Updates/replaces the stock legacy boot payload (SeaBIOS) included on many models; supplements the ChromeOS / secure boot payload (BOOT_STUB)
+
#* Updates/replaces the stock legacy boot payload (SeaBIOS) included on many models; supplements the ChromeOS / secure boot payload
 
#* Leaves all stock functionality intact, including the developer mode boot (white "OS verification is OFF") screen
 
#* Leaves all stock functionality intact, including the developer mode boot (white "OS verification is OFF") screen
 
#* Allows device to dual-boot GalliumOS alongside ChromeOS
 
#* Allows device to dual-boot GalliumOS alongside ChromeOS
Line 15: Line 79:
 
#* Carries zero risk of bricking the device
 
#* Carries zero risk of bricking the device
 
#* On some models, includes bugfixes and enables additional functionality
 
#* On some models, includes bugfixes and enables additional functionality
# '''BOOT_STUB'''
 
#* Replaces the ChromeOS verified boot payload with a legacy boot payload (SeaBIOS)
 
#* Removes the developer mode boot (white "OS verification is OFF") screen
 
#* Requires the firmware write-protect screw to be removed
 
#* Removes the ability to run ChromeOS, creating a small risk of bricking your device
 
#* Leaves the recovery mode (ESC + REFRESH + POWER) functionality of the stock ROM intact
 
#** If you engage this key sequence, device will reboot and try to run ChromeOS Recovery (which will fail)
 
#** This process will repeat on every boot until you disassemble the device and briefly disconnect the battery
 
 
# '''Full Firmware / ROM'''
 
# '''Full Firmware / ROM'''
#* A complete firmware image which replaces the hardware init component (coreboot) and payload components (BOOT_STUB, RW_LEGACY) of the stock firmware with updated and/or customized versions of coreboot and SeaBIOS
+
#* A complete firmware image which replaces the hardware init component (coreboot) and payload components of the stock firmware with updated and/or customized versions of coreboot and SeaBIOS (legacy) or Tianocore (UEFI)
 
#* Removes the developer mode boot (white "OS verification is OFF") screen
 
#* Removes the developer mode boot (white "OS verification is OFF") screen
 
#* Removes the ability to run ChromeOS, creating a small risk of bricking your device
 
#* Removes the ability to run ChromeOS, creating a small risk of bricking your device
 
#* Offers the best support for booting all OSes besides ChromeOS (including Windows).
 
#* Offers the best support for booting all OSes besides ChromeOS (including Windows).
#* On many models, adds full hardware support for virtualization (vmx / VT-x)
+
#* On all models, enables full hardware support for virtualization (vmx / VT-x)
 
#* Fixes many bugs and/or idiosyncrasies associated with the stock firmware (but could potentially add new ones)
 
#* Fixes many bugs and/or idiosyncrasies associated with the stock firmware (but could potentially add new ones)
 
#* Essentially turns your ChromeOS device into a "regular" PC / laptop
 
#* Essentially turns your ChromeOS device into a "regular" PC / laptop
  
=== Availability Options ===
+
== Factory Firmware ==
 +
 
 +
Factory firmware capabilities vary by model family. Haswells have good support for booting GalliumOS out of the box. Broadwells ''should'' have good support, but unfortunately the factory firmware has inconvenient video bugs. Bay Trail, Braswell, and Apollo Lake models don't include any support whatsoever. Skylake models also have video bugs in factory firmware. Kaby Lake models have OK support for eMMC devices, but fatal bugs for NVMe devices.
 +
 
 +
In all cases, custom firmware is strongly recommended. Custom RW_LEGACY firmware is available for nearly all Intel models, and is very quick, safe, and simple to update.
 +
 
 +
=== Factory Bugs ===
 +
 
 +
This is a (very) incomplete list, but includes some model-specific notes.
 +
 
 +
* '''Haswell'''
 +
** '''PANTHER, ZAKO''' USB ports non-functional in legacy boot mode / SeaBIOS
 +
*** <span style="background-color:#ccffcc;padding:0.2em">'''fixed'''</span> in custom firmware: MrChromebox (UEFI Full ROM, RW_LEGACY)
 +
** '''WOLF''' non-functional legacy boot mode / SeaBIOS
 +
*** <span style="background-color:#ccffcc;padding:0.2em">'''fixed'''</span> in custom firmware: MrChromebox (UEFI Full ROM, RW_LEGACY)
 +
 
 +
* '''Broadwell'''
 +
** '''(all models?)''' Early boot display error, can't see GRUB messages [https://github.com/GalliumOS/galliumos-distro/issues/234 (details)]
 +
*** <span style="background-color:#ccffcc;padding:0.2em">'''fixed'''</span> in custom firmware: MrChromebox (UEFI Full ROM, RW_LEGACY)
 +
 
 +
* '''Bay Trail'''
 +
** '''(all models)''' Legacy boot capability (SeaBIOS) not included
 +
*** <span style="background-color:#ccffcc;padding:0.2em">'''fixed'''</span> in custom firmware: MrChromebox (UEFI Full ROM, RW_LEGACY)
  
Check [[Hardware Compatibility]] and the appropriate [[Support]] page to determine the status of your model.
+
* '''Braswell'''
 +
** '''(all models)''' Legacy boot capability (SeaBIOS) not included
 +
*** <span style="background-color:#ccffcc;padding:0.2em">'''fixed'''</span> in custom firmware: MrChromebox (RW_LEGACY)
  
There are several custom firmware options available, depending on your Chromebook/box model class, and the features you require:  
+
* '''Skylake'''
 +
** '''CHELL, others?''': Stock Legacy boot support functional, but video resolution sub-optimal, screen redraws slow.
 +
*** <span style="background-color:#ccffcc;padding:0.2em">'''fixed'''</span> in custom firmware: MrChromebox (RW_LEGACY)
  
{| class="wikitable"
+
* '''Apollo Lake'''
|-
+
** '''(all models)''' Legacy boot capability (SeaBIOS) not included
! scope="col"| Firmware Provider / Link
+
*** <span style="background-color:#ccffcc;padding:0.2em">'''fixed'''</span> in custom firmware: MrChromebox (RW_LEGACY)
! scope="col"| ARM
 
! scope="col"| Pineview
 
! scope="col"| Sandy/Ivy Bridge
 
! scope="col"| Haswell
 
! scope="col"| Broadwell
 
! scope="col"| Bay Trail
 
! scope="col"| Braswell
 
! scope="col"| notes
 
|-
 
| style="text-align:center" | [https://www.reddit.com/r/chrultrabook/comments/3jl45k/getting_started_guide/ CoolStar]
 
| style="text-align:center;background-color:#ffe8e8" | No
 
| style="text-align:center;background-color:#ffe8e8" | No
 
| style="text-align:center;background-color:#ffe8e8" | No
 
| style="text-align:center;background-color:#ccffcc" | Full Firmware (Chromebooks)
 
| style="text-align:center;background-color:#ccffcc" | Full Firmware (Chromebooks)
 
| style="text-align:center;background-color:#ffe8e8" | No
 
| style="text-align:center;background-color:#ffe8e8" | No
 
| • Fixes factory firmware bugs<br>• Boots Linux, Mac OS X, and Windows!<br>• Install Guide: [https://docs.google.com/document/d/1yfIjx-fJXPvs6EwSdjRnokJ6ktNxeExZmVin9mamVZU/edit Haswell], [https://docs.google.com/document/d/1nFZmoRzQ03btPCGVSa4ku6JPQik-SxD__zOd1CoB2yg/edit Broadwell]<br>• Can also be installed via MattDevo's script<br>• [https://github.com/coolstar/coreboot Firmware build scripts]
 
|-
 
| style="text-align:center" | [https://johnlewis.ie/custom-chromebook-firmware/rom-download/ johnlewis.ie]
 
| style="text-align:center;background-color:#ffe8e8" | No
 
| style="text-align:center;background-color:#ffe8e8" | No
 
| style="text-align:center;background-color:#ccffcc" | Full Firmware, BOOT_STUB (all)
 
| style="text-align:center;background-color:#ccffcc" | Full Firmware, BOOT_STUB, RW_LEGACY (all)
 
| style="text-align:center;background-color:#ccffcc" | RW_LEGACY (all)
 
| style="text-align:center;background-color:#ccffcc" | BOOT_STUB (all)
 
| style="text-align:center;background-color:#ffe8e8" | No
 
| • Fixes factory firmware bugs<br>• General purpose firmware for Linux<br>• Single script works for all supported models<br>• Firmware build scripts/configs not published
 
|-
 
| style="text-align:center" | [https://github.com/MattDevo/scripts MattDevo<br>(MrChromebox)]
 
| style="text-align:center;background-color:#ffe8e8" | No
 
| style="text-align:center;background-color:#ffe8e8" | No
 
| style="text-align:center;background-color:#ccffcc" | Full Firmware (Chromeboxes)
 
| style="text-align:center;background-color:#ccffcc" | Full Firmware (Chromeboxes), RW_LEGACY (all)
 
| style="text-align:center;background-color:#ccffcc" | Full Firmware (Chromeboxes), RW_LEGACY (all)
 
| style="text-align:center;background-color:#ccffcc" | BOOT_STUB (all), RW_LEGACY (all)
 
| style="text-align:center;background-color:#ffe8e8" | No
 
| • Fixes factory firmware bugs<br>• Headless boot support for servers<br>• PXE booting support<br>• Supports integration of [http://kodi.tv/about/ Kodi Media Center]<br>• [https://github.com/MattDevo/coreboot Firmware source/build scripts] and [https://github.com/MattDevo/SeaBIOS payload source]
 
|}
 
  
Additions and corrections, '''please''' let us know: <code>contact</code>@<code>galliumos.org</code>
+
* '''Kaby Lake'''
 +
** '''EVE''': Non-functional legacy boot mode / SeaBIOS in NVMe models.
 +
*** <span style="background-color:#ccffcc;padding:0.2em">'''fixed'''</span> in custom firmware: MrChromebox (RW_LEGACY)
  
 
== Firmware and NVRAM Flags ==
 
== Firmware and NVRAM Flags ==
  
Both the crossystem and GBB flags listed below are only relevant when booting legacy mode via RW_LEGACY (CTRL+L on dev mode boot screen); they do not have any effect when using a custom BOOT_STUB firmware.
+
Both the crossystem and GBB flags listed below are only relevant when booting legacy mode via RW_LEGACY (CTRL+L on dev mode boot screen); they do not have any effect when using custom Full ROM (UEFI or legacy) firmware.
  
 
=== crossystem ===
 
=== crossystem ===
Line 99: Line 144:
 
Google Binary Block (GBB) flags are firmware level settings stored directly in the firmware flash chip itself in a read-only (RO) area, and so require the firmware write protect screw to be removed before setting.  The GBB flags are used to set the default boot mode (ChromeOS or legacy boot), developer mode boot screen timeout (2s or 30s), prevent exiting developer mode via spacebar, and to enable legacy booting regardless of crossystem setting, among other things.
 
Google Binary Block (GBB) flags are firmware level settings stored directly in the firmware flash chip itself in a read-only (RO) area, and so require the firmware write protect screw to be removed before setting.  The GBB flags are used to set the default boot mode (ChromeOS or legacy boot), developer mode boot screen timeout (2s or 30s), prevent exiting developer mode via spacebar, and to enable legacy booting regardless of crossystem setting, among other things.
  
Most users should not attempt to set these manually, but instead use MattDevo's (/u/MrChromebox) ChromeOS firmware utility script to set them based on their preferred default boot mode and boot timeout (the script automatically sets the dev mode and legacy boot mode overrides for all options except factory default).  For those curious, a full description of all the GBB flags can be [https://chromium.googlesource.com/chromiumos/platform/vboot_reference/+/master/firmware/include/gbb_header.h found in the Google source code here]
+
Most users should not attempt to set these manually, but instead use MrChromebox's [https://mrchromebox.tech/#fwscript ChromeOS firmware utility script] to set them based on their preferred default boot mode and boot timeout (the script automatically sets the dev mode and legacy boot mode overrides for all options except factory default).  For those curious, a full description of all the GBB flags can be [https://chromium.googlesource.com/chromiumos/platform/vboot/+/master/_vboot_reference/firmware/include/gbb_header.h found in the Google source code here]

Latest revision as of 23:03, 11 November 2020

Stock (Factory) vs. Custom Firmware

Factory firmware for ChromeOS devices is built for booting ChromeOS, of course. Some models also include the capability of booting other OSes in factory firmware, but most do not (or have serious implementation bugs).

Custom firmware adds the ability to boot GalliumOS to all models, and fixes factory bugs. Some firmware types also improve other functionality. See below for details.

Custom Firmware

Availability Options

Check Hardware Compatibility and the appropriate Support page to determine the status of your model.

There are different custom firmware options available, depending on your Chromebook/box model class, and the features you require:

MrChromebox
ARM No
Pineview No
Sandy/Ivy Bridge Full Firmware [UEFI] (all)
RW_LEGACY (LINK)
Haswell Full Firmware [UEFI] (all)
Full Firmware [Legacy] (Chromeboxes)
RW_LEGACY (all)
Broadwell Full Firmware [UEFI] (all)
Full Firmware [Legacy] (Chromeboxes)
RW_LEGACY (all)
Bay Trail Full Firmware [UEFI] (all)
RW_LEGACY (all)
Braswell Full Firmware [UEFI] (all)
RW_LEGACY (all)
Skylake Full Firmware [UEFI] (all)
RW_LEGACY (all)
Apollo Lake RW_LEGACY (all)
Kaby Lake Full Firmware [UEFI] (all)
RW_LEGACY (all)
Gemini Lake No
Whiskey Lake RW_LEGACY (all) Tianocore via AltFW
AMD Stoney Ridge RW_LEGACY (all)
notes • Easy Install via the Firmware Utility Script
• Offers both UEFI and Legacy boot support for many models
• Fixes factory firmware bugs
• Built using latest upstream sources
• Headless boot support for servers
• PXE booting support (legacy only)
• UEFI firmware fully supports Windows as well as Linux
Firmware source/build scripts and payload sources ( Legacy, UEFI)
Download/Install

Custom firmware builds for some models were previously available from CoolStar and John Lewis. That firmware is no longer recommended nor supported (by us or them).

If you're running older firmware, you should strongly consider updating to a current build from MrChromebox. Full info, and Install script.

Types

  1. RW_LEGACY
    • Updates/replaces the stock legacy boot payload (SeaBIOS) included on many models; supplements the ChromeOS / secure boot payload
    • Leaves all stock functionality intact, including the developer mode boot (white "OS verification is OFF") screen
    • Allows device to dual-boot GalliumOS alongside ChromeOS
    • Does not require disabling the firmware write-protect
    • Carries zero risk of bricking the device
    • On some models, includes bugfixes and enables additional functionality
  2. Full Firmware / ROM
    • A complete firmware image which replaces the hardware init component (coreboot) and payload components of the stock firmware with updated and/or customized versions of coreboot and SeaBIOS (legacy) or Tianocore (UEFI)
    • Removes the developer mode boot (white "OS verification is OFF") screen
    • Removes the ability to run ChromeOS, creating a small risk of bricking your device
    • Offers the best support for booting all OSes besides ChromeOS (including Windows).
    • On all models, enables full hardware support for virtualization (vmx / VT-x)
    • Fixes many bugs and/or idiosyncrasies associated with the stock firmware (but could potentially add new ones)
    • Essentially turns your ChromeOS device into a "regular" PC / laptop

Factory Firmware

Factory firmware capabilities vary by model family. Haswells have good support for booting GalliumOS out of the box. Broadwells should have good support, but unfortunately the factory firmware has inconvenient video bugs. Bay Trail, Braswell, and Apollo Lake models don't include any support whatsoever. Skylake models also have video bugs in factory firmware. Kaby Lake models have OK support for eMMC devices, but fatal bugs for NVMe devices.

In all cases, custom firmware is strongly recommended. Custom RW_LEGACY firmware is available for nearly all Intel models, and is very quick, safe, and simple to update.

Factory Bugs

This is a (very) incomplete list, but includes some model-specific notes.

  • Haswell
    • PANTHER, ZAKO USB ports non-functional in legacy boot mode / SeaBIOS
      • fixed in custom firmware: MrChromebox (UEFI Full ROM, RW_LEGACY)
    • WOLF non-functional legacy boot mode / SeaBIOS
      • fixed in custom firmware: MrChromebox (UEFI Full ROM, RW_LEGACY)
  • Broadwell
    • (all models?) Early boot display error, can't see GRUB messages (details)
      • fixed in custom firmware: MrChromebox (UEFI Full ROM, RW_LEGACY)
  • Bay Trail
    • (all models) Legacy boot capability (SeaBIOS) not included
      • fixed in custom firmware: MrChromebox (UEFI Full ROM, RW_LEGACY)
  • Braswell
    • (all models) Legacy boot capability (SeaBIOS) not included
      • fixed in custom firmware: MrChromebox (RW_LEGACY)
  • Skylake
    • CHELL, others?: Stock Legacy boot support functional, but video resolution sub-optimal, screen redraws slow.
      • fixed in custom firmware: MrChromebox (RW_LEGACY)
  • Apollo Lake
    • (all models) Legacy boot capability (SeaBIOS) not included
      • fixed in custom firmware: MrChromebox (RW_LEGACY)
  • Kaby Lake
    • EVE: Non-functional legacy boot mode / SeaBIOS in NVMe models.
      • fixed in custom firmware: MrChromebox (RW_LEGACY)

Firmware and NVRAM Flags

Both the crossystem and GBB flags listed below are only relevant when booting legacy mode via RW_LEGACY (CTRL+L on dev mode boot screen); they do not have any effect when using custom Full ROM (UEFI or legacy) firmware.

crossystem

ChromeOS System (crossystem) flags are firmware level settings which are stored in volatile memory, and are therefore lost/reset if the battery on your Chromebook is fully drained or disconnected; they do not require firmware write protect to be disabled in order to set/unset them.

The dev_boot_legacy flag needs to be set (=1) in order to enable legacy booting (and installation/booting of GalliumOS). Most users do not need to set this manually, as it is set automatically when installing a RW_LEGACY firmware payload, but should be aware that it can be unset via battery drain/disconnect. This can be problematic if GalliumOS is the only OS installed on the system (as it would require the user to restore ChromeOS to re-enable legacy booting), and so it is recommended that users who are not dual-booting set the GBB flags below to ensure legacy boot capability is not "turned off" if battery power is lost.

Note: many other sources mistakenly insist that dev_boot_usb needs to be set as well, but it does not - that flag only enables booting ChromeOS (or an OS with a ChromeOS-signed kernel) via CTRL+U on the developer mode boot screen; it has nothing to do with booting from USB in legacy boot mode (CTRL+L).

GBB Flags

Google Binary Block (GBB) flags are firmware level settings stored directly in the firmware flash chip itself in a read-only (RO) area, and so require the firmware write protect screw to be removed before setting. The GBB flags are used to set the default boot mode (ChromeOS or legacy boot), developer mode boot screen timeout (2s or 30s), prevent exiting developer mode via spacebar, and to enable legacy booting regardless of crossystem setting, among other things.

Most users should not attempt to set these manually, but instead use MrChromebox's ChromeOS firmware utility script to set them based on their preferred default boot mode and boot timeout (the script automatically sets the dev mode and legacy boot mode overrides for all options except factory default). For those curious, a full description of all the GBB flags can be found in the Google source code here