| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,168 @@ | ||
| # ASUS P8Z77-M Pro | ||
|
|
||
| This page describes how to run coreboot on the [ASUS P8Z77-M Pro] | ||
|
|
||
| ## Flashing coreboot | ||
|
|
||
| ```eval_rst | ||
| +---------------------+----------------+ | ||
| | Type | Value | | ||
| +=====================+================+ | ||
| | Socketed flash | yes | | ||
| +---------------------+----------------+ | ||
| | Model | W25Q64FVA1Q | | ||
| +---------------------+----------------+ | ||
| | Size | 8 MiB | | ||
| +---------------------+----------------+ | ||
| | Package | DIP-8 | | ||
| +---------------------+----------------+ | ||
| | Write protection | yes | | ||
| +---------------------+----------------+ | ||
| | Dual BIOS feature | no | | ||
| +---------------------+----------------+ | ||
| | Internal flashing | yes | | ||
| +---------------------+----------------+ | ||
| ``` | ||
|
|
||
| The flash IC is located right next to one of the SATA ports: | ||
|  | ||
|
|
||
| ### Internal programming | ||
|
|
||
| The main SPI flash cannot be written because Asus disables BIOSWE and | ||
| enables BLE/SMM_BWP flags in BIOS_CNTL for their latest bioses. | ||
| An external programmer is required. You must flash standalone, | ||
| flashing in-circuit doesn't work. The flash chip is socketed, so it's | ||
| easy to remove and reflash. | ||
|
|
||
| ## Working | ||
|
|
||
| - PS/2 keyboard with SeaBIOS & Tianocore (in Mint 18.3/19.1) | ||
|
|
||
| - Rear/front headphones connector audio & mic | ||
|
|
||
| - S3 Suspend to RAM (tested with OS installed in a HDD/SSD and also with a | ||
| Mint 18.3/19.1 LiveUSB pendrive connected to USB3/USB2), but please | ||
| see [Known issues] | ||
|
|
||
| - USB2 on rear (tested mouse/keyboard plugged there. Also, booting with | ||
| a Mint 18./19.1 LiveUSB works ok) | ||
|
|
||
| - USB3 (Z77's and Asmedia's works, but please see [Known issues]) | ||
|
|
||
| - Gigabit Ethernet (RTL8111F) | ||
|
|
||
| - SATA3, SATA2 and eSATA (tested on all ports, hot-swap and TCG OPAL working) | ||
| (Blue SATA2) (Blue SATA2) (White SATA3) (Red eSATA SATA3 rear) | ||
| port 3 port 5 port 1 port 8 | ||
| port 4 port 6 port 2 port 7 | ||
|
|
||
| - NVME SSD boot on PCIe-x16/x8/4x slot using Tianocore | ||
| (tested with M.2-to-PCIe adapter and a M.2 Samsung EVO 970 SSD) | ||
|
|
||
| - CPU Temp sensors (tested PSensor on linux + HWINFO64 on Win10) | ||
|
|
||
| - TPM on TPM-header (tested tpm-tools with Asus TPM 1.2 Infineon SLB9635TT12) | ||
|
|
||
| - Native raminit and also MRC.bin(systemagent-r6.bin) memory initialization | ||
| (please see [Native raminit compatibility] and [MRC memory compatibility]) | ||
|
|
||
| - Integrated graphics with both libgfxinit and the Intel Video BIOS OpROM | ||
| (VGA/DVI-D/HDMI tested and working) | ||
|
|
||
| - 1x PCIe GPU in PCIe-16x/8x/4x slots (tested using Zotac GeForce GTX | ||
| 750Ti and FirePro W5100 under Mint 18.3/19.1) | ||
|
|
||
| ## Known issues | ||
|
|
||
| - The rear's USB3s on bottom (closest to the PCB) have problems booting or | ||
| being used before the OS loads. For better compatibility, please use | ||
| the Z77's ones above the Ethernet connector or the Asmedia's top one | ||
|
|
||
| - After S3 suspend, some USB3 connectors on rear seem not to work | ||
|
|
||
| - At the moment, the power led does not blink when entering S3 state | ||
|
|
||
| - Currently, we have not setup the SuperIO's Hardware Monitor (HWM), | ||
| so only the CPU sensors are reported | ||
|
|
||
| - If you use the MRC.bin, the NVRAM variable gfx_uma_size may be ignored | ||
| as IGP's UMA could be reconfigured by the blob | ||
|
|
||
| - Using TianoCore + a PCIe GPU under Windows crashes with an | ||
| ACPI_BIOS_ERROR fatal code, not sure why. Using just the IGP | ||
| works perfectly | ||
|
|
||
| - Under Windows 10, if you experiment problems with PS/2 devices, change | ||
| HKLM\SYSTEM\CurrentControlSet\Services\i8042prt->Start from '3' to '1' | ||
|
|
||
| ## Untested | ||
|
|
||
| - EHCI debugging | ||
| - S/PDIF audio | ||
| - Wake-on-LAN | ||
| - Serial port | ||
|
|
||
| ## Not working | ||
|
|
||
| - PS/2 keyboard in Win10 using Tianocore (please see [Known issues]) | ||
| - PS/2 mouse using Tianocore | ||
| - PCIe graphics card on Windows and Tianocore (throws critical ACPI_BIOS_ERROR) | ||
|
|
||
| ## Native raminit compatibility | ||
|
|
||
| - GSkill F3-2133C10D-16GAB(XMP,1.60v) 2x8GB kit works at 1333Mhz instead | ||
| of XMP 2133Mhz | ||
|
|
||
| - Team Xtreem TXD38G2133HC9NDC01(XMP,1.50v) 2x4GB kit works at 1600Mhz | ||
| instead of XMP 2133Mhz | ||
|
|
||
| - Kingston KVR1066D3N7K2/4G(JEDEC,1.50v) 2x4GB kit works at 1066Mhz | ||
| but the board only detects half its RAM, because those DIMMs have | ||
| Double Sided(DS) chips and seems only Single Sided(SS) ones are | ||
| fully detected | ||
|
|
||
| - GSkill F3-10666CL9T2-24GBRL(JEDEC,1.50v) 6x4GB kit (4 DIMMs used) | ||
| works perfectly at full speed (1333Mhz) | ||
|
|
||
| ## MRC memory compatibility | ||
|
|
||
| - GSkill F3-2133C10D-16GAB(XMP,1.60v) 2x8GB kit works at 1333Mhz | ||
| instead of XMP 2133Mhz | ||
|
|
||
| - Team Xtreem TXD38G2133HC9NDC01(XMP,1.50v) 2x4GB kit works at | ||
| 1600Mhz instead of XMP 2133Mhz | ||
|
|
||
| - Kingston KVR1066D3N7K2/4G(JEDEC,1.50v) 2x4GB kit works at 1066Mhz | ||
| but the board only detects half its RAM, as those DIMMs have | ||
| Double Sided(DS) chips and seems only Single Sided(SS) ones are | ||
| fully detected | ||
|
|
||
| - GSkill F3-10666CL9T2-24GBRL(JEDEC,1.50v) 6x4GB kit (4 DIMMs used) | ||
| works perfectly at full speed (1333Mhz) | ||
|
|
||
| ## Technology | ||
|
|
||
| ```eval_rst | ||
| +------------------+--------------------------------------------------+ | ||
| | Northbridge | :doc:`../../northbridge/intel/sandybridge/index` | | ||
| +------------------+--------------------------------------------------+ | ||
| | Southbridge | bd82x6x | | ||
| +------------------+--------------------------------------------------+ | ||
| | CPU | model_206ax | | ||
| +------------------+--------------------------------------------------+ | ||
| | Super I/O | Nuvoton NCT6779D | | ||
| +------------------+--------------------------------------------------+ | ||
| | EC | None | | ||
| +------------------+--------------------------------------------------+ | ||
| | Coprocessor | Intel Management Engine | | ||
| +------------------+--------------------------------------------------+ | ||
| ``` | ||
|
|
||
| ## Extra resources | ||
|
|
||
| - [Flash chip datasheet][W25Q64FVA1Q] | ||
|
|
||
| [ASUS P8Z88-M Pro]: https://www.asus.com/Motherboards/P8Z77M_PRO/ | ||
| [W25Q64FVA1Q]: https://www.winbond.com/resource-files/w25q64fv%20revs%2007182017.pdf | ||
| [flashrom]: https://flashrom.org/Flashrom |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,83 @@ | ||
| # Facebook FBG-1701 | ||
|
|
||
| This page describes how to run coreboot on the Facebook FBG1701. | ||
|
|
||
| FBG1701 are assembled with different onboard memory modules: | ||
| Rev 1.0 Onboard Samsung K4B8G1646D-MYKO memory | ||
| Rev 1.1 and 1.2 Onboard Micron MT41K512M16HA-125A memory | ||
|
|
||
| Use make menuconfig to configure `onboard memory manufacturer` in Mainboard | ||
| menu. | ||
|
|
||
| ## Required blobs | ||
|
|
||
| This board currently requires: | ||
| fsp blob 3rdparty/fsp/BraswellFspBinPkg/FspBin/BSWFSP.fd | ||
| Microcode Intel Braswell cpuid 1046C4 version 410 | ||
| (Used pre-build binary retrieved from Intel site) | ||
|
|
||
| ## Flashing coreboot | ||
|
|
||
| ### Internal programming | ||
|
|
||
| The main SPI flash can be accessed using [flashrom]. | ||
|
|
||
| ### External programming | ||
|
|
||
| The system has an internal flash chip which is a 8 MiB soldered SOIC-8 chip. | ||
| This chip is located to the top middle side of the board. It's located | ||
| between SoC and Q7 connector. Use clip (or solder wires) to program | ||
| the chip. | ||
| Specifically, it's a Winbond W25Q64FW (1.8V), whose datasheet can be found | ||
| [here][W25Q64FW]. | ||
|
|
||
| The system has an external flash chip which is a 8 MiB soldered SOIC-8 chip. | ||
| This chip is located in the middle of carrier board close to the flex cable | ||
| connection. | ||
| Specifically, it's a Winbond W25Q64FV (3.3V), whose datasheet can be found | ||
| [here][W25Q64FV]. | ||
|
|
||
| ## Known issues | ||
|
|
||
| - None | ||
|
|
||
| ## Untested | ||
|
|
||
| - hardware monitor | ||
| - SDIO | ||
| - Full Embedded Controller support | ||
|
|
||
| ## Working | ||
|
|
||
| - USB | ||
| - Gigabit Ethernet | ||
| - integrated graphics | ||
| - flashrom | ||
| - external graphics | ||
| - PCIe | ||
| - eMMC | ||
| - SATA | ||
| - serial port | ||
| - SMBus | ||
| - HDA | ||
| - initialization with FSP MR2 | ||
| - SeaBIOS payload | ||
| - Embedded Linux (Ubuntu 4.15+) | ||
|
|
||
| ## Technology | ||
|
|
||
| ```eval_rst | ||
| +------------------+--------------------------------------------------+ | ||
| | SoC | Intel Atom Processor N3710 | | ||
| +------------------+--------------------------------------------------+ | ||
| | CPU | Intel Braswell (N3710) | | ||
| +------------------+--------------------------------------------------+ | ||
| | Super I/O, EC | ITE8256 | | ||
| +------------------+--------------------------------------------------+ | ||
| | Coprocessor | Intel Management Engine | | ||
| +------------------+--------------------------------------------------+ | ||
| ``` | ||
|
|
||
| [W25Q64FW]: https://www.winbond.com/resource-files/w25q64fw%20revn%2005182017%20sfdp.pdf | ||
| [W25Q64FV]: https://www.winbond.com/resource-files/w25q64fv%20revs%2007182017.pdf | ||
| [flashrom]: https://flashrom.org/Flashrom |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,70 @@ | ||
| # HP Z220 SFF Workstation | ||
|
|
||
| This page describes how to run coreboot on the [HP Z220 SFF Workstation] desktop | ||
| from [HP]. | ||
|
|
||
| ## TODO | ||
|
|
||
| The following things are still missing from this coreboot port: | ||
|
|
||
| - Extended HWM reporting | ||
| - Advanced LED control | ||
| - Advanced power configuration in S3 | ||
|
|
||
| ## Flashing coreboot | ||
|
|
||
| ```eval_rst | ||
| +---------------------+-------------+ | ||
| | Type | Value | | ||
| +=====================+=============+ | ||
| | Socketed flash | no | | ||
| +---------------------+-------------+ | ||
| | Model | N25Q128..3E | | ||
| +---------------------+-------------+ | ||
| | Size | 16 MiB | | ||
| +---------------------+-------------+ | ||
| | In circuit flashing | yes | | ||
| +---------------------+-------------+ | ||
| | Package | SOIC-16 | | ||
| +---------------------+-------------+ | ||
| | Write protection | No | | ||
| +---------------------+-------------+ | ||
| | Dual BIOS feature | No | | ||
| +---------------------+-------------+ | ||
| | Internal flashing | yes | | ||
| +---------------------+-------------+ | ||
| ``` | ||
|
|
||
| ### Internal programming | ||
|
|
||
| The SPI flash can be accessed using [flashrom]. | ||
|
|
||
| ### External programming | ||
|
|
||
| External programming with an SPI adapter and [flashrom] does work, but it powers the | ||
| whole southbridge complex. You need to supply enough current through the programming adapter. | ||
|
|
||
| If you want to use a SOIC pomona test clip, you have to cut the 2nd DRAM DIMM holder, | ||
| as otherwise there's not enough space near the flash. | ||
|
|
||
| ## Technology | ||
|
|
||
| ```eval_rst | ||
| +------------------+--------------------------------------------------+ | ||
| | Northbridge | :doc:`../../northbridge/intel/sandybridge/index` | | ||
| +------------------+--------------------------------------------------+ | ||
| | Southbridge | bd82x6x | | ||
| +------------------+--------------------------------------------------+ | ||
| | CPU | model_206ax | | ||
| +------------------+--------------------------------------------------+ | ||
| | SuperIO | :doc:`../../superio/nuvoton/npcd378` | | ||
| +------------------+--------------------------------------------------+ | ||
| | EC | | | ||
| +------------------+--------------------------------------------------+ | ||
| | Coprocessor | Intel ME | | ||
| +------------------+--------------------------------------------------+ | ||
| ``` | ||
|
|
||
| [HP Z220 SFF Workstation]: https://support.hp.com/za-en/document/c03386950 | ||
| [HP]: https://www.hp.com/ | ||
| [flashrom]: https://flashrom.org/Flashrom |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,97 @@ | ||
| # PC Engines APU1 | ||
|
|
||
| This page describes how to run coreboot on PC Engines APU1 platform. | ||
|
|
||
| ## Technology | ||
|
|
||
| ```eval_rst | ||
| +------------+--------------------------------------------------------+ | ||
| | CPU | AMD G series T40E APU | | ||
| +------------+--------------------------------------------------------+ | ||
| | CPU core | 1 GHz dual core (Bobcat core) with 64 bit support | | ||
| | | 32K data + 32K instruction + 512KB L2 cache per core | | ||
| +------------+--------------------------------------------------------+ | ||
| | DRAM | 2 or 4 GB DDR3-1066 DRAM | | ||
| +------------+--------------------------------------------------------+ | ||
| | Boot | From SD card, USB, mSATA, SATA | | ||
| +------------+--------------------------------------------------------+ | ||
| | Power | 6 to 12W of 12V power | | ||
| +------------+--------------------------------------------------------+ | ||
| | Firmware | coreboot with support for iPXE and USB boot | | ||
| +------------+--------------------------------------------------------+ | ||
| ``` | ||
|
|
||
| ## Flashing coreboot | ||
|
|
||
| ```eval_rst | ||
| +---------------------+--------------------------+ | ||
| | Type | Value | | ||
| +=====================+==========================+ | ||
| | Socketed flash | no | | ||
| +---------------------+--------------------------+ | ||
| | Model | MX25L1606E | | ||
| +---------------------+--------------------------+ | ||
| | Size | 2 MiB | | ||
| +---------------------+--------------------------+ | ||
| | Package | SOP-8 | | ||
| +---------------------+--------------------------+ | ||
| | Write protection | jumper on WP# pin | | ||
| +---------------------+--------------------------+ | ||
| | Dual BIOS feature | no | | ||
| +---------------------+--------------------------+ | ||
| | Internal flashing | yes | | ||
| +---------------------+--------------------------+ | ||
| ``` | ||
|
|
||
| ### Internal programming | ||
|
|
||
| The SPI flash can be accessed using [flashrom]. It is important to execute | ||
| command with a `-c <chipname>` argument: | ||
|
|
||
| flashrom -p internal -c "MX25L1606E" -w coreboot.rom | ||
|
|
||
| ### External programming | ||
|
|
||
| **IMPORTANT**: When programming SPI flash, first you need to enter apu1 in S5 | ||
| (Soft-off) power state. S5 state can be forced by shorting power button pin on | ||
| J2 header. | ||
|
|
||
| The external access to flash chip is available through standard SOP-8 clip or | ||
| SOP-8 header next to the flash chip on the board. Notice that not all boards | ||
| have a header soldered down originally. Hence, there could be an empty slot with | ||
| 8 eyelets, so you can solder down a header on your own. The SPI flash chip and | ||
| SPI header are marked in the picture below. Also there is SPI header pin layout | ||
| included. Notice, that signatures at the schematic can be ambiguous: | ||
| - J12 SPIDI = U35 SO = MISO | ||
| - J12 SPIDO = U35 SI = MOSI | ||
|
|
||
| There is no restrictions as to the programmer device. It is only recommended to | ||
| flash firmware without supplying power. External programming can be performed, | ||
| for example using OrangePi and Armbian. You can exploit linux_spi driver which | ||
| provide communication with SPI devices. Example command to program SPI flash | ||
| with OrangePi using linux_spi: | ||
|
|
||
| flashrom -w coreboot.rom -p linux_spi:dev=/dev/spidev1.0,spispeed=16000 -c | ||
| "MX25L1606E" | ||
|
|
||
|
|
||
| **apu1 platform with marked in SPI header and SPI flash chip** | ||
|
|
||
| ![][apu1c1_flash] | ||
|
|
||
| **SPI header pin layout** | ||
|
|
||
| ![][spi_header] | ||
|
|
||
|
|
||
| ### Schematics | ||
|
|
||
| PC Engines APU platform schematics are available for free on PC Engines official | ||
| site. Depending on the configuration: | ||
| [apu1c](https://www.pcengines.ch/schema/apu1c.pdf) and | ||
| [apu1d](https://www.pcengines.ch/schema/apu1d.pdf). | ||
|
|
||
|
|
||
| [apu1c1_flash]: apu1c1.jpg | ||
| [spi_header]: apu1_spi.jpg | ||
| [flashrom]: https://flashrom.org/Flashrom |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,116 @@ | ||
| # PC Engines APU2 | ||
|
|
||
| This page describes how to run coreboot on PC Engines APU2 platform. | ||
|
|
||
| ## Technology | ||
|
|
||
| ```eval_rst | ||
| +------------+---------------------------------------------------------------+ | ||
| | CPU | AMD G series GX-412TC | | ||
| +------------+---------------------------------------------------------------+ | ||
| | CPU core | 1 GHz quad Puma core with 64 bit support | | ||
| | | 32K data + 32K instruction cache per core, shared 2MB L2 cache| | ||
| +------------+---------------------------------------------------------------+ | ||
| | DRAM | 2 or 4 GB DDR3-1333 DRAM | | ||
| +------------+---------------------------------------------------------------+ | ||
| | Boot | From SD card, USB, mSATA SSD, SATA | | ||
| +------------+---------------------------------------------------------------+ | ||
| | Power | 6 to 12W of 12V power | | ||
| +------------+---------------------------------------------------------------+ | ||
| | Firmware | coreboot with support for iPXE and USB boot | | ||
| +------------+---------------------------------------------------------------+ | ||
| ``` | ||
|
|
||
| ## Required proprietary blobs | ||
|
|
||
| To build working coreboot image some blobs are needed. | ||
|
|
||
| ```eval_rst | ||
| +-----------------+---------------------------------+---------------------+ | ||
| | Binary file | Apply | Required / Optional | | ||
| +=================+=================================+=====================+ | ||
| | amdfw.rom* | AMD Platform Security Processor | Required | | ||
| +-----------------+---------------------------------+---------------------+ | ||
| | AGESA.bin | AGESA Platform Initialization | Required | | ||
| +-----------------+---------------------------------+---------------------+ | ||
| | xhci.bin | AMD XHCI controller | Optional | | ||
| +-----------------+---------------------------------+---------------------+ | ||
| ``` | ||
| (\*) - package containing all required blobs for PSP. Directory, in which all | ||
| blobs are listed and available is: *3rdparty/southbridge/amd/avalon/PSP* | ||
|
|
||
| ## Flashing coreboot | ||
|
|
||
| ```eval_rst | ||
| +---------------------+--------------------------+ | ||
| | Type | Value | | ||
| +=====================+==========================+ | ||
| | Socketed flash | no | | ||
| +---------------------+--------------------------+ | ||
| | Model | W25Q64 | | ||
| +---------------------+--------------------------+ | ||
| | Size | 8 MiB | | ||
| +---------------------+--------------------------+ | ||
| | Package | SOIC-8 | | ||
| +---------------------+--------------------------+ | ||
| | Write protection | jumper on WP# pin* | | ||
| +---------------------+--------------------------+ | ||
| | Dual BIOS feature | no | | ||
| +---------------------+--------------------------+ | ||
| | Internal flashing | yes | | ||
| +---------------------+--------------------------+ | ||
| ``` | ||
| (\*) - It is used in normal SPI mode, but can be dangerous when using Quad SPI | ||
| Flash. Then, pull-down resistors should be considered rather than jumper. | ||
|
|
||
| ### Internal programming | ||
|
|
||
| The SPI flash can be accessed using [flashrom]. | ||
|
|
||
| flashrom -p internal -w coreboot.rom | ||
|
|
||
| ### External programming | ||
|
|
||
| **IMPORTANT**: When programming SPI flash, first you need to enter apu2 in S5 | ||
| (Soft-off) power state. S5 state can be forced by shorting power button pin on | ||
| J2 header. | ||
|
|
||
| The external access to flash chip is available through standard SOP-8 clip or | ||
| SOP-8 header next to the flash chip on the board. Notice that not all boards | ||
| have a header soldered down originally. Hence, there could be an empty slot with | ||
| 8 eyelets, so you can solder down a header on your own. The SPI flash chip and | ||
| SPI header are marked in the picture below. Also there is SPI header and SPI | ||
| flash pin layout included. Depend on using header or clip there are important | ||
| rules: | ||
| - using header J6 - don't connect 1,7,8 pins | ||
| - using clip U23 - don't connect 3,7,8 pins | ||
|
|
||
| Also signatures at the schematic can be ambiguous: | ||
| - J6 SPIDI = U23 SO = MISO | ||
| - J6 SPIDO = U23 SI = MOSI | ||
|
|
||
| There is no restrictions as to the programmer device. It is only recommended to | ||
| flash firmware without supplying power. External programming can be performed, | ||
| for example using OrangePi and Armbian. You can exploit linux_spi driver which | ||
| provides communication with SPI devices. Example command to program SPI flash | ||
| with OrangePi using linux_spi: | ||
|
|
||
| flashrom -f -w coreboot.rom -p linux_spi:dev=/dev/spidev1.0,spispeed=16000 | ||
|
|
||
| **apu2 platform with marked in SPI header and SPI flash chip** | ||
|
|
||
| ![][apu2_flash] | ||
|
|
||
| **SPI header pin layout** | ||
|
|
||
| ![][spi_header] | ||
|
|
||
| ## Schematics | ||
|
|
||
| PC Engines APU2 [platform schematics](https://pcengines.ch/schema/apu2d.pdf) | ||
| are available for free on PC Engines official site. Both configurations | ||
| (2GB/4GB) have the same PCB and schematic. | ||
|
|
||
| [apu2_flash]: apu2.jpg | ||
| [spi_header]: apu2_spi.jpg | ||
| [flashrom]: https://flashrom.org/Flashrom |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,23 @@ | ||
| Roda RK9 Flash Header | ||
| ===================== | ||
|
|
||
| There is a 5x2 pin, 1.27mm pitch header *J1* south of the BIOS flash. It | ||
| follows the pinout of the Dediprog adaptor board: | ||
|
|
||
| +------+ | ||
| | 1 2 | 1: HOLD 2 2: CS 2 | ||
| | 3 4 | 3: CS 1 4: VCC | ||
| | 5 6 | 5: MISO 6: HOLD 1 | ||
| | 7 8 | 7: 8: CLK | ||
| | 9 10 | 9: GND 10: MOSI | ||
| +------+ | ||
|
|
||
| Pins 3 to 10 directly map to the regular SPI flash pinout. | ||
|
|
||
| There is also a *JP17* around. Ideally, it should be closed during | ||
| programming (isolates the SPI bus from the southbridge): | ||
|
|
||
| +---+ | ||
| | 1 | 1: SF100-I/O3 | ||
| | 2 | 2: GND | ||
| +---+ |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,20 @@ | ||
| # ME Cleaner | ||
| It's possible to 'clean' the ME partition within the flash medium as part | ||
| of the build process. While cleaning as much code as possible is removed | ||
| from the ME firmware partition. In this state the ME errors out and doesn't | ||
| operate any more. | ||
|
|
||
| **Using a 'cleaned' ME partition may lead to issues and its use should be | ||
| carefully evaulated.** | ||
|
|
||
| ## Observations with 'cleaned' ME | ||
|
|
||
| * Instable LPC bus | ||
| * SuperIO is malfunctioning | ||
| * TPM is malfunctioning | ||
| * Random system shutdowns on high bus activity | ||
|
|
||
| ## Filing bug reports | ||
|
|
||
| Always test with unmodified IFD and ME section before reporting bugs to the | ||
| coreboot project. |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,48 @@ | ||
| # Memory clearing | ||
|
|
||
| The main memory on computer platforms in high security environments contains | ||
| sensible data. On unexpected reboot the data might persist and could be | ||
| read by a malicious application in the bootflow or userspace. | ||
|
|
||
| In order to prevent leaking information from pre-reset, the boot firmware can | ||
| clear the main system memory on boot, wiping all information. | ||
|
|
||
| A common API indicates if the main memory has to be cleared. That could be | ||
| on user request or by a Trusted Execution Environment indicating that secrets | ||
| are in memory. | ||
|
|
||
| As every platform has different bring-up mechanisms and memory-layouts, every | ||
| The device must indicate support for memory clearing as part of the boot | ||
| process. | ||
|
|
||
| ## Requirements | ||
|
|
||
| 1. The platform must clear all platform memory (DRAM) if requested | ||
| 2. Code that is placed in DRAM might be skipped (as workaround) | ||
| 3. Stack that is placed in DRAM might be skipped (as workaround) | ||
| 4. All DRAM is cleared with zeros | ||
|
|
||
| ## Implementation | ||
|
|
||
| A platform that supports memory clearing selects Kconfig | ||
| ``PLATFORM_HAS_DRAM_CLEAR`` and calls | ||
|
|
||
| ```C | ||
| bool security_clear_dram_request(void); | ||
| ``` | ||
| to detect if memory should be cleared. | ||
| The memory is cleared in ramstage as part of `DEV_INIT` stage. It's possible to | ||
| clear it earlier on some platforms, but on x86 MTRRs needs to be programmed | ||
| first, which happens in `DEV_INIT`. | ||
| Without MTRRs (and caches enabled) clearing memory takes multiple seconds. | ||
| ## Exceptions | ||
| As some platforms place code and stack in DRAM (FSP1.0), the regions can be | ||
| skipped. | ||
| ## Architecture specific implementations | ||
| * [x86 PAE](../arch/x86/pae.md) |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,224 @@ | ||
| # AMD Family 17h in coreboot | ||
|
|
||
| ## Abstract | ||
|
|
||
| Beginning with Family 17h products (a.k.a. “Zen” cores), AMD | ||
| changed their paradigm for initializing the system and this requires | ||
| major modifications to the execution flow of coreboot. This file | ||
| discusses the new boot flow, and challenges, and the tradeoffs of the | ||
| initial port into coreboot. | ||
|
|
||
| ## Introduction | ||
|
|
||
| Family 17h products are x86-based designs. This documentation assumes | ||
| familiarity with x86, its reset state and its early initialization | ||
| requirements. | ||
|
|
||
| To the extent necessary, the role of the Platform Security Processor | ||
| (a.k.a. PSP) in system initialization is addressed here. AMD has | ||
| historically required an NDA for access to the PSP | ||
| specification<sup>1</sup>. coreboot relies on util/amdfwtool to build | ||
| the structures and add various other firmware to the final image. The | ||
| Family 17h PSP design guide adds a new BIOS Directory Table, similar to | ||
| the PSP Directory Table. | ||
|
|
||
| Support in coreboot for modern AMD products is based on AMD’s | ||
| reference code: AMD Generic Encapsulated Software Architecture | ||
| (AGESA<sup>TM</sup>). AGESA contains the technology for enabling DRAM, | ||
| configuring proprietary core logic, assistance with generating ACPI | ||
| tables, and other features. | ||
|
|
||
| AGESA for products earlier than Family 17h is known as v5 or | ||
| Arch2008<sup>2</sup>. Also note that coreboot currently contains both | ||
| open source AGESA and closed source implementations (binaryPI) compiled | ||
| from AGESA. | ||
|
|
||
| The first AMD Family 17h device ported to coreboot is codenamed | ||
| “Picasso”<sup>3</sup>, and will be added to soc/amd/picasso. | ||
|
|
||
| ## Additional Definitions | ||
|
|
||
| * PSP, Platform Security Processor: Onboard ARM processor that runs | ||
| alongside the main x86 processor; may be viewed as analogous to the | ||
| Intel<sup>R</sup> Management Engine | ||
| * FCH, Fusion Control Hub, the logical southbridge within the SOC | ||
| * ABL - AGESA Bootloader - Processor initialization code that runs on | ||
| the PSP | ||
| * PSP Directory Table - A structured list of pointers to PSP firmware | ||
| and other controller binaries | ||
| * BIOS Directory Table - A structured list of pointers to BIOS | ||
| related firmware images | ||
| * Embedded Firmware Structure - Signature and pointers used by the | ||
| PSP to locate the PSP Directory Table and BIOS Directory Table; these | ||
| items are generated during coreboot build and are located in the SPI ROM | ||
| * Verstage - The code to verify the firmware contained in the | ||
| writable section of the SPI ROM | ||
| * APCB - AMD PSP Customization Block - A binary containing PSP and | ||
| system configuration preferences (analogous to v5 BUILDOPT_ options), | ||
| and generated by APCBTool to be added to coreboot/utils later | ||
| * APOB - AGESA PSP Output Buffer - A buffer in main memory for | ||
| storing AGESA BootLoader output. There are no plans for this to be | ||
| parsed by coreboot | ||
|
|
||
| ## Problem Statements | ||
|
|
||
| AMD has ported early AGESA features to the PSP, which now discovers, | ||
| enables and trains DRAM. Unlike any other x86 device in coreboot, a | ||
| Picasso system has DRAM online prior to the first instruction fetch. | ||
|
|
||
| Cache-as-RAM (CAR) is no longer a supportable feature in AMD hardware. | ||
| Early code expecting CAR behavior <span | ||
| style="text-decoration:underline;">must</span> account for writes | ||
| escaping the L2 cache and going to DRAM. | ||
|
|
||
| Without any practical need for CAR, or DRAM initialization, coreboot | ||
| should arguably skip bootblock and romstage, and possibly use ramstage | ||
| as the BIOS image. This approach presents a number of challenges: | ||
|
|
||
| * At the entry of ramstage, x86 processors are in flat protected | ||
| mode. Picasso’s initial state is nearly identical to any other x86 | ||
| at reset, except its CS shadow register’s base and limit put its | ||
| execution within DRAM, not at 0xfffffff0. Picasso requires initial | ||
| programming and entry into protected mode prior to ramstage. | ||
| * coreboot expects cbmem initialization during romstage. | ||
|
|
||
| AGESA supporting Picasso is now at v9. Unlike Arch2008, which defines | ||
| granular entry points for easy inclusion to a legacy BIOS, v9 is | ||
| rewritten for compilation into a UEFI. The source follows UEFI | ||
| standards, i.e. assumes the presence of UEFI phases, implements | ||
| dependency expressions, much functionality is rewritten as libraries, | ||
| etc. It would, in no way, fit into the v5 model used in coreboot. | ||
|
|
||
| * For the foreseeable future, AGESA source will distributed only | ||
| under NDA. | ||
|
|
||
| ## Basic Pre-x86 Boot Flow | ||
|
|
||
| The following steps occur prior to x86 processor operation. | ||
|
|
||
| * System power on | ||
| * PSP executes immutable on-chip boot ROM | ||
| * PSP locates the Embedded Firmware Table and PSP Directory Table in | ||
| the SPI ROM | ||
| * PSP verifies and executes the PSP off-chip bootloader | ||
| * ChromeOS systems: | ||
| * Off-chip bootloader attempts to locate verstage via the RO BIOS | ||
| Directory Table | ||
| * If verstage is not found, booting continues with ABLs below | ||
| * Verstage initializes, setting up GPIOs, UART if needed, | ||
| communication path to the EC, and the SPI controller for direct access | ||
| to the flash device. | ||
| * Verstage verifies the RW sections (as is typically performed by | ||
| the main processor) | ||
| * Verstage locates the Embedded Firmware Directory within the | ||
| verified FMAP section and passes a pointer to the PSP bootloader. If | ||
| the verification fails, it passes a pointer to the RO header to the | ||
| bootloader. | ||
| * PSP parses the PSP Directory Table to find the ABLs and executes | ||
| them | ||
| * An ABL parses the APCB for system configuration preferences | ||
| * An ABL initializes system main memory, locates the compressed BIOS | ||
| image in the SPI ROM, and decompresses it into DRAM | ||
| * An ABL writes the APOB to DRAM for consumption by the x86-based | ||
| AGESA | ||
| * PSP releases the x86 processor from reset. The x86 core fetches | ||
| and executes instructions from the reset vector | ||
|
|
||
| ## Picasso Reset Vector and First Instructions | ||
|
|
||
| As mentioned above, prior to releasing the x86 main core from reset, | ||
| the PSP decompresses a BIOS image into DRAM. The PSP uses a specific | ||
| BIOS Directory Table entry type to determine the source address (in | ||
| flash), the destination address (in DRAM), and the destination size. | ||
| The decompressed image is at the top of the destination region. The | ||
| PSP then | ||
|
|
||
| Calculates the x86 reset vector as | ||
|
|
||
| reset_vector = dest_addr + dest_size - 0x10 | ||
|
|
||
| Sets x86 CS descriptor shadow register to | ||
|
|
||
| base = dest_addr + dest_size - 0x10000 | ||
| limit = 0xffff | ||
|
|
||
| Like all x86 devices, the main core is allowed to begin executing | ||
| instructions with | ||
|
|
||
| CS:IP = 0xf000:0xfff0 | ||
|
|
||
| For example, assume the BIOS Directory Table indicates | ||
|
|
||
| destination = 0x9b00000 | ||
| size = 0x300000 | ||
|
|
||
| … then the BIOS image is placed at the topmost position the region | ||
| 0x9b00000-0x9dfffff and | ||
|
|
||
| reset_vector = 0x9dffff0 | ||
| CS_shdw_base = 0x9df0000 | ||
| CS:IP = 0xf000:0xfff0 | ||
|
|
||
| Although the x86 behaves as though it began executing at 0xfffffff0 | ||
| i.e. 0xf000:0xfff0, the initial GDT load must use the physical address | ||
| of the table and not the typical CS-centric address. And, the first | ||
| jump to protected mode must jump to the physical address in DRAM. Any | ||
| code that is position-dependent must be linked to run at the final | ||
| destination. | ||
|
|
||
| ## Initial coreboot Implementation | ||
|
|
||
| Supporting Picasso doesn’t fit well with many of the coreboot | ||
| assumptions. Initial porting shall attempt to fit within existing | ||
| coreboot paradigms and make minimal changes to common code. | ||
|
|
||
| ### CAR and bootblock | ||
|
|
||
| The coreboot bootblock contains features Picasso doesn’t require or | ||
| can’t use, and is assumed to execute in an unusable location. | ||
| Picasso’s requirement for bootblock in coreboot will be eliminated. | ||
|
|
||
| ### Hybrid romstage | ||
|
|
||
| Picasso’s x86 reset state doesn’t meet the coreboot expectations | ||
| for jumping directly to ramstage. The primary feature of romstage is | ||
| also not needed, however there are other important features that are | ||
| typically in romstage that Picasso does need. | ||
|
|
||
| The romstage architecture is designed around the presence of CAR. | ||
| Several features implement ROMSTAGE_CBMEM_INIT_HOOK, expecting to move | ||
| data from CAR to cbmem. The hybrid romstage consumes DRAM for the | ||
| purpose of implementing the expected CAR storage. This region as well | ||
| as the DRAM where romstage is decompressed must be reserved and | ||
| unavailable to the OS. | ||
|
|
||
| The initial Picasso port implements a hybrid romstage that contains the | ||
| first instruction fetched at the reset vector. It minimally configures | ||
| flat protected mode, initializes cbmem, then loads the next stage. | ||
| Future work will consider breaking the dependencies mentioned above | ||
| and/or potentially loading ramstage directly from the PSP. | ||
|
|
||
| ## AGESA v9 on Picasso | ||
|
|
||
| Due to the current inability to publish AGESA source, a pre-built | ||
| binary solution remains a requirement. The rewrite from v5 to v9 for | ||
| direct inclusion into UEFI source makes modifying it for conforming to | ||
| the existing v5 interface impractical. | ||
|
|
||
| Given the UEFI nature of modern AGESA, and the existing open source | ||
| work from Intel, Picasso shall support AGESA via an FSP-like prebuilt | ||
| image. The Intel Firmware Support Package<sup>4</sup> combines | ||
| reference code with EDK II source to create a modular image with | ||
| discoverable entry points. coreboot source already contains knowledge | ||
| of FSP, how to parse it, integrate it, and how to communicate with it. | ||
|
|
||
| ## Footnotes | ||
|
|
||
| 1. “AMD Platform Security Processor BIOS Architecture Design Guide | ||
| for AMD Family 17h Processors” (PID #55758) and “AMD Platform | ||
| Security Processor BIOS Architecture Design Guide” (PID #54267) for | ||
| earlier products | ||
| 2. [https://www.amd.com/system/files/TechDocs/44065_Arch2008.pdf](https://www.amd.com/system/files/TechDocs/44065_Arch2008.pdf) | ||
| 3. [https://en.wikichip.org/wiki/amd/cores/picasso](https://en.wikichip.org/wiki/amd/cores/picasso) | ||
| 4. [https://www.intel.com/content/www/us/en/intelligent-systems/intel-firmware-support-package/intel-fsp-overview.html](https://www.intel.com/content/www/us/en/intelligent-systems/intel-firmware-support-package/intel-fsp-overview.html) | ||
|
|
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,8 @@ | ||
| # AMD SOC-specific documentation | ||
|
|
||
| This section contains documentation about coreboot on specific AMD SOCs. | ||
|
|
||
| ## Technology | ||
|
|
||
| - [Family 17h](family17h.md) | ||
|
|
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,17 @@ | ||
| # Apollolake | ||
| ## SPI flash layout | ||
|
|
||
| ![][apl_flash_layout] | ||
|
|
||
| With Apollolake Intel invented another flash layout for x86 firmware called IFWI (Intel FirmWare Image). | ||
|
|
||
| Usually on x86 platforms the bootblock is stored at the end of the bios region | ||
| and the Intel ME / TXE has its own IFD region. On Apollolake both have been | ||
| moved into the IFWI region, which is a subregion of "BIOS", since it allows to | ||
| store multiple firmware components. | ||
|
|
||
| The IFWI region can be manipulated by `ifwitool`. | ||
|
|
||
| [apl_flash_layout]: flash_layout.svg | ||
|
|
||
|
|
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,8 @@ | ||
| # Eltan vendorcode-specific documentation | ||
|
|
||
| This section contains documentation about coreboot on Eltan specific | ||
| vendorcode. | ||
|
|
||
| ## Sections | ||
|
|
||
| - [Security](security.md) |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,39 @@ | ||
| # Eltan Security | ||
|
|
||
| ## Security | ||
| This code enables measured boot and verified boot support. | ||
| Verified boot is available in coreboot, but based on ChromeOS. This vendorcode | ||
| uses a small encryption library and leave much more space in flash for the | ||
| payload. | ||
|
|
||
| ## Hashing Library | ||
| The library suppports SHA-1, SHA-256 and SHA-512. The required routines of | ||
| `3rdparty/vboot/firmware/2lib` are used. | ||
|
|
||
| ## Measured boot | ||
| measured boot support will use TPM2 device if available. The items specified | ||
| in `mb_log_list[]` will be measured. | ||
|
|
||
| ## Verified boot | ||
| verified boot support will use TPM2 device if available. The items specified | ||
| in the next table will be verified: | ||
| * `bootblock_verify_list[]` | ||
| * `verify_item_t romstage_verify_list[]` | ||
| * `ram_stage_additional_list[]` | ||
| * `ramstage_verify_list[]` | ||
| * `payload_verify_list[]` | ||
| * `oprom_verify_list[]` | ||
|
|
||
| ## Enabling support | ||
|
|
||
| * Measured boot can be enabled using **CONFIG_MBOOT** | ||
| * Create mb_log_list table with list of item to measure | ||
| * Create tables bootblock_verify_list[], verify_item_t romstage_verify_list[], | ||
| ram_stage_additional_list[], ramstage_verify_list[], payload_verify_list[], | ||
| oprom_verify_list[] | ||
| * Verified boot can be enabled using **CONFIG_VERIFIED_BOOT** | ||
| * Added Kconfig values for verbose console output | ||
|
|
||
| ## Debugging | ||
|
|
||
| You can enable verbose console output in *menuconfig*. |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,16 +1,18 @@ | ||
| CONFIG_LOCALVERSION="v4.9.0.7" | ||
| CONFIG_VENDOR_PCENGINES=y | ||
| CONFIG_PAYLOAD_CONFIGFILE="$(top)/src/mainboard/$(MAINBOARDDIR)/seabios_config" | ||
| CONFIG_NO_GFX_INIT=y | ||
| CONFIG_USER_TPM2=y | ||
| CONFIG_DEFAULT_CONSOLE_LOGLEVEL_1=y | ||
| CONFIG_SEABIOS_REVISION=y | ||
| CONFIG_SEABIOS_REVISION_ID="rel-1.12.1.3" | ||
| CONFIG_SEABIOS_BOOTORDER_FILE="$(top)/src/mainboard/$(MAINBOARDDIR)/bootorder" | ||
| CONFIG_SEABIOS_DEBUG_LEVEL=0 | ||
| CONFIG_PXE=y | ||
| CONFIG_BUILD_IPXE=y | ||
| # CONFIG_PXE_SERIAL_CONSOLE is not set | ||
| CONFIG_PXE_CUSTOM_BUILD_ID="12345678" | ||
| CONFIG_PXE_ADD_SCRIPT=y | ||
| CONFIG_PXE_SCRIPT="payloads/external/iPXE/menu.ipxe" | ||
| CONFIG_MEMTEST_SECONDARY_PAYLOAD=y | ||
| CONFIG_SORTBOOTORDER_SECONDARY_PAYLOAD=y |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,6 @@ | ||
| CONFIG_LP_ARCH_ARM=y | ||
| CONFIG_LP_STACK_SIZE=64000 | ||
| CONFIG_LP_BASE_ADDRESS=0x62030000 | ||
| CONFIG_LP_TINYCURSES=y | ||
| CONFIG_LP_8250_SERIAL_CONSOLE=y | ||
| CONFIG_LP_TIMER_GENERIC_HZ=1000000 |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,3 +1,8 @@ | ||
| CONFIG_LP_CHROMEOS=y | ||
| CONFIG_LP_ARCH_ARM64=y | ||
| CONFIG_LP_TIMER_ARM64_ARCH=y | ||
| CONFIG_LP_SERIAL_CONSOLE=y | ||
| CONFIG_LP_QCS405_SERIAL_CONSOLE=y | ||
| CONFIG_LP_USB=y | ||
| CONFIG_LP_USB_EHCI=y | ||
| CONFIG_LP_USB_XHCI=y |