From 35fa0e5efbc1b29f49cec30031b2fe79c959af19 Mon Sep 17 00:00:00 2001 From: Leah Rowe Date: Fri, 24 Mar 2023 07:48:48 +0000 Subject: [PATCH] update --- site/news/libreboot20230319.md | 30 ++---- site/news/libreboot20230319_update.md | 149 ++++++++++++++------------ 2 files changed, 89 insertions(+), 90 deletions(-) diff --git a/site/news/libreboot20230319.md b/site/news/libreboot20230319.md index 6e8b5fd..938611c 100644 --- a/site/news/libreboot20230319.md +++ b/site/news/libreboot20230319.md @@ -2,27 +2,17 @@ % Leah Rowe % 19 March 2023 -**UPDATE: I think I fixed the issue mentioned in the update below. As I write -this note, I need to wait until I can access my flashing gear. Will re-add -t440pmrc/w541mrc to rsync if i'm right. on irc last night i discovered mrc -needs to be in a fixed offset, after looking at coreboot src. i replicated -that offset using `-b` switch in cbfstool. what i need to know is whether it's -always the same offse tfor anyone who compiles it, then i can adjust in the -blobtool script** +**UPDATE ON 24 MARCH 2023: +T440p/W541 ROM images using blob `mrc.bin` for raminit, were deleted +from the rsync mirrors for this release. The ones with libre MRC are still +available. This was due to a bug that has now been fixed. For more information, +see: [libreboot20230319_update.md](libreboot20230319_update.md) - you should +build from `lbmk.git` directly if you want to use those images, or use the ones +with the libre MRC code in it, for which ROM images (as stated) are still +available. Thanks.** -Original update announcement below: - -**UPDATE: `t440pmrc_12mb` and `w541mrc_12mb` images were deleted from the -release; PLEASE DO NOT USE THEM AS THEY DO NOT BOOT.** - -**The images of target `t440p_12mb` and `w541_12mb` boot just fine, and these -use the libre MRC replacement for raminit. The `t440pmrc_12mb` -and `w541mrc_12mb` images use blob MRC. More info about that is below, and -you can read this follow-up news article about the retroactive deletion, see:** - -^ The notes above will be updated once this is cleared up. - -**[libreboot20230319_update.md](libreboot20230319_update.md)** +Introduction +============ Libreboot provides boot firmware for supported x86/ARM machines, starting a bootloader that then loads your operating system. It replaces proprietary diff --git a/site/news/libreboot20230319_update.md b/site/news/libreboot20230319_update.md index 3a36f3e..8bf71eb 100644 --- a/site/news/libreboot20230319_update.md +++ b/site/news/libreboot20230319_update.md @@ -1,93 +1,102 @@ -% T440p ROMs using mrc.bin deleted (libre MRC setups retained) +% 20230319 W541/T440p ROMs using mrc.bin deleted % Leah Rowe -% 23 March 2023 +% 23 March 2023 (UPDATED on 24 March 2023) -**UPDATE: I think I fixed the issue mentioned in the update below. As I write -this note, I need to wait until I can access my flashing gear. Will re-add -t440pmrc/w541mrc to rsync if i'm right. on irc last night i discovered mrc -needs to be in a fixed offset, after looking at coreboot src. i replicated -that offset using `-b` switch in cbfstool. what i need to know is whether it's -always the same offse tfor anyone who compiles it, then i can adjust in the -blobtool script** +This was reported last night, but the issue it reports has been fixed as +of this morning, on 24 March 2023. News article ammended, and date updated +to the 24th instead of 23rd. -note above and/or this page will be amended/deleted if fix works, and then i -will just re-add mrc-based images to rsync. sorry for inconvenience. +Introduction +============ -Introduction, and warning -========================= +From the rsync mirrors for Libreboot 20230319, the following images have +been *deleted* retroactively: -Haswell machines (T440p/W541 ThinkPads) have the following targets in lbmk, -and these were available in as ROM images pre-compiled in the recent -Libreboot 20230319 release. They are: +* `t440pmrc_12mb` +* `w541mrc_12mb` -* `t440pmrc_12mb`: uses `mrc.bin` for raminit / peripherals (binary blob) -* `w541mrc_12mb`: uses `mrc.bin` for raminit / peripherals (binary blob!) -* `t440p_12mb`: uses Angel Pon's experimental libre replacement of `mrc.bin` -* `w541_12mb`: ditto (uses Angel's code) +Those images listed above use the proprietary `mrc.bin` blob for raminit and +peripherals. -The `t440p_12mb` and `w541_12mb` images are *still available*, in the -Libreboot 20230319 release images. HOWEVER: +Libreboot *also* has these images: -The `t440pmrc_12mb` and `w541mrc_12mb` images have been *deleted* from rsync, -for the Libreboot 20230319 release. The previous 20221214 release also had -these as `t440p_12mb` and `w541_12mb` because in that release, only the blob -MRC was available (Angel's libre replacement appeared in the 20230319 release), -and they've been deleted there aswell. +* `t440p_12mb` +* `w541_12mb` -If you downloaded pre-built `t440pmrc_12mb` or `w541mrc_12mb`, please DO NOT -USE THEM AS THEY DO NOT BOOT. The cause is being investigated. +These ones, the ones without `mrc` in the name, use experiment source code from +Angel Pons of coreboot (`hell` on IRC), removing the need for `mrc.bin` +entirely. *These* ROM images are still available, in the rsync mirrors, for the +Libreboot 20230319 release. -Essentially, we believe that there are differences between these two things, -in terms of the resulting image after MRC blob insertion: +Why were the MRC-based images deleted? +-------------------------------------- -* Coreboot's own build system logic, for inserting MRC blobs. This is what - Libreboot uses when compiling these images, on those targets. **This boots - just fine.** -* Libreboot's own `blobutil` which is used to re-insert MRC blobs on release - images (which have the MRC blobs scrubbed, prior to release). **Does not - boot, resulting in a brick.** +The ROM images themselves were *correct*, but there is a bug in the `blobutil` +insert script, for inserting `mrc.bin` into these images. The `mrc.bin` file +must be inserted at a specific offset, and no offset was declared explicitly +by `blobutil`. -So it is these differences being investigated first. If you want to reliably -boot and use `t440pmrc_12mb` or `w541mrc_12mb`, please compile them yourself -using the [Libreboot build instructions](../docs/build/) - otherwise, if you -want the libre MRC version, using `t440p_12mb` or `w541_12mb` images, then -that's OK and you can use the pre-compiled images from Libreboot 20230319. +In the Libreboot 20230319 release source archive, the `blobutil` program runs +this command for inserting `mrc.bin` when necessary: -Context -------- + ./coreboot/default/util/cbfstool/cbfstool ${rom} add -f mrc/haswell/mrc.bin -n mrc.bin -t mrc -When building T440p or W541 ROM images directly, from `lbmk` (Libreboot's -automated build system), MRC images are inserted if required (depending on -the build target). These images are scrubbed from release images, and a script -is provided (documented) to re-download and re-insert these into the image. +This is **wrong**, because it's missing the following arguments at the the end: -**Scenario one, compile from lbmk (using `mrc.bin`) - BOOTS FINE:** + -b 0x78fe00 -Booting T440p/W541 images generated by running lbmk directly (or using source -tarballs from releases to build them), on an image that uses the `mrc.bin` -blob, will boot perfectly and work just fine. +This, the correct command for those images would be: -**Scenario two, release roms (using `mrc.bin`) - DOES NOT BOOT:** + ./coreboot/default/util/cbfstool/cbfstool ${rom} add -f mrc/haswell/mrc.bin -n mrc.bin -t mrc -b 0x78fe00 -However, it was discovered that when inserting these blobs into the ROM images -on release images, using Libreboot's `blobutil`, the resulting ROM would not -boot when flashed, resulting in a brick. +This command is *unnecessary* when building the ROM images yourself, from +lbmk directly, because the same download script is used and then coreboot's +build system inserts it, at the correct offset. -**THEREFORE, if you downloaded Libreboot images that require `mrc.bin`, please -do NOT use them, please instead compile from source using `lbmk`, or use the -release images from 20230319 of target `t440p_12mb` or `w541_12mb`; these -versions will work, but the blob MRC ones named `t440pmrc_12mb` -and `w541mrc_12mb` are currently BROKEN, in the release.** +However, Libreboot's build system scrubs `mrc.bin` when creating release +archives, which means they must be re-added by the user when downloading +such pre-compiled ROMs, using a script available in Libreboot; it is *this* +script that was broken, in the Libreboot 20230319 release. -For the time being, Libreboot will *not* provide Haswell images that -use the *blob* `mrc.bin`. It will *only* provide the images that use libre MRC. +The position of MRC is to be fixed, and it is hardcoded in coreboot master. +Based on that, the MRC file is always added at the same location in CBFS, and +the number above is based on that. The number is correct, on Haswell configs +supported by Libreboot. -If you want to use a setup with the blob `mrc.bin`, please compile Libreboot -yourself. +FIX AVAILABLE +============= -I apologise to anyone who flashed using `blobutil` to insert `mrc.bin`. This -was reported online but I initially shrugged it off, until I tested it myself -this evening. +This bug described on this page has been fixed, in `lbmk.git`. See patch: -At the time of publishing this post, some of the rsync/https mirrors still -have the offending images, but some have already synced the deletion on my end. + + +Will not re-add images to rsync +------------------------------- + +I **could** re-add the images, and add a note to the Libreboot documentation +telling the user to patch their `blobutil` according to the commit linked +above. However, such would be un-clean. As far as I'm concerned, the images +are gone now and it's a testing release anyway. + +So there's little risk. If you want images using `mrc.bin`, you shall build +Libreboot from source using these instructions: + +[How to build from lbmk.git](../docs/build/) + +All it costs you is a bit of extra time waiting for the build process to +complete. Those wily enough to flash a T440p themselves for the first time, +will surely not mind. + +That is all. + +PS: + +If any persons bricked their T440p due to this bug, I'm very sorry. This is +precisely *why* I'm not re-adding the images, even though they're OK - a lot +of people as I said, won't patch their blobutil even when told to, to correct +that offset, but they can't brick their machine with such ROM images if they +don't exist. So they no longer exist, on mirrors providing Libreboot releases. + +The irony would be if Angel finished the libre MRC code before the next +Libreboot release, making this fix pointless (because in that situation, I +would simply exclude images using `mrc.bin` at that point).