create_coreboot_config: use per-variant me.bin
For Hatch, each variant has its own version of the ME binary, see
crrev.com/c/1931038. When creating config.${VARIANT} from the
baseboard, also look for me-hatch.bin (in the CONFIG_ME_BIN_PATH)
and modify it to reference me-${VARIANT}.bin.
BUG=b:140261109
TEST=`./create_coreboot_config.sh hatch sushi`
Examine third_party/chromiumos-overlay/sys-boot/coreboot/files/configs.
The git branch should be "create_sushi_" and today's date.
The new file config.sushi, will differ from config.hatch by three
lines:
> CONFIG_BOARD_GOOGLE_SUSHI=y
> CONFIG_IFD_BIN_PATH="3rdparty/blobs/baseboard/hatch/descriptor-sushi.bin"
> CONFIG_ME_BIN_PATH="3rdparty/blobs/baseboard/hatch/me-sushi.bin"
Change-Id: Id0f6e579c8afabdc99be86f0a4f108b11f087018
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/dev-util/+/1960056
Tested-by: Paul Fagerburg <pfagerburg@chromium.org>
Auto-Submit: Paul Fagerburg <pfagerburg@chromium.org>
Reviewed-by: Justin TerAvest <teravest@chromium.org>
Commit-Queue: Paul Fagerburg <pfagerburg@chromium.org>
diff --git a/contrib/variant/create_coreboot_config.sh b/contrib/variant/create_coreboot_config.sh
index 0e69ecc..9d17366 100755
--- a/contrib/variant/create_coreboot_config.sh
+++ b/contrib/variant/create_coreboot_config.sh
@@ -3,7 +3,7 @@
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
-VERSION="1.0.1"
+VERSION="1.0.2"
SCRIPT=$(basename -- "${0}")
export LC_ALL=C
@@ -63,9 +63,15 @@
# Another possibility for the IFD is that the baseboard doesn't use a
# hyphenated name, so we also need to search for descriptor.bin, e.g.
# CONFIG_IFD_BIN_PATH="3rdparty/blobs/baseboard-octopus/descriptor.bin"
+#
+# We also need to update the me.bin name, so that each board has its own binary
+# CONFIG_ME_BIN_PATH="3rdparty/blobs/baseboard/hatch/me-hatch.bin"
+# ---
+# CONFIG_ME_BIN_PATH="3rdparty/blobs/baseboard/hatch/me-kohaku.bin"
sed -e "s/${BASE_UPPER}/${VARIANT_UPPER}/" \
-e "s/descriptor-${BASE}\.bin/descriptor-${VARIANT}.bin/" \
-e "s/descriptor\.bin/descriptor-${VARIANT}.bin/" \
+ -e "s/me-${BASE}\.bin/me-${VARIANT}.bin/" \
"config.${BASE}" > "config.${VARIANT}"
git add "config.${VARIANT}"