| 1 | # Flashing coreboot using SMC IPMI (BMC) firmware |
| 2 | |
| 3 | ## Metadata |
| 4 | In order to flash anything to the "BIOS" IC, it needs to contain a valid |
| 5 | BIOSINFO struct. |
| 6 | |
| 7 | The BIOSINFO struct contains a `$FID` marker at the beginning and is |
| 8 | 128 bytes in total. Besides the *BoardID* it contains the *firmware version* |
| 9 | and *build date*. The BMC verifies that the BoardID is correct and refuses to |
| 10 | flash if it's not. |
| 11 | |
| 12 | The struct has no checksum or cryptographic protection. |
| 13 | |
| 14 | ## The smcinfobios tool |
| 15 | |
| 16 | The smcbiosinfo tool can be found in `util/supermicro/smcbiosinfo`. |
| 17 | |
| 18 | It parses the `build/build.h` header to get the current coreboot version and |
| 19 | build timestamp. |
| 20 | The *board ID* is passed as command line argument. |
| 21 | |
| 22 | It will place a file in CBFS called `smcbiosinfo.bin`, which is then found |
| 23 | by the vendor tools. The file contains the struct described above. |
| 24 | |
| 25 | ## Flashing using SMCIPMItool |
| 26 | |
| 27 | You can use the *SMCIPMITool* to remotely flash the BIOS: |
| 28 | |
| 29 | `SMCIPMITool <remote BMC IP> <user> <password> bios update build/coreboot.rom` |
| 30 | |
| 31 | Make sure that the ME isn't in recovery mode, otherwise you get an error |
| 32 | message on updating the BIOS. |
| 33 | |
| 34 | ## Flashing with disabled ME |
| 35 | |
| 36 | If ME is disabled via `me_cleaner` or the ME recovery jumper, it is still |
| 37 | possible to flash remotely with the [`Supermicro Update Manager`][SUM] (`SUM`). |
| 38 | |
| 39 | ```sh |
| 40 | ./sum -i <remote BMC IP> -u <user> -p <password> -c UpdateBios --reboot \ |
| 41 | --force_update --file build/coreboot.rom |
| 42 | ``` |
| 43 | |
| 44 | [SUM]: https://www.supermicro.com/SwDownload/SwSelect_Free.aspx?cat=SUM |