summaryrefslogtreecommitdiff
path: root/include/mrc.sh
diff options
context:
space:
mode:
authorLeah Rowe <leah@libreboot.org>2026-07-30 11:58:11 +0100
committerLeah Rowe <leah@libreboot.org>2026-07-30 11:58:11 +0100
commit1b65e8914c4ad1e140b573fa6bc8feead14542ad (patch)
treeeb2039c59c0d99ff39f9a548fc7c3efc61dfe87e /include/mrc.sh
parent72238d22b508013c0d158746e82456c67ca96166 (diff)
xbmk: general code cleanupHEADmaster
make the code much easier to read i also cleaned up the recent git identity check Signed-off-by: Leah Rowe <leah@libreboot.org>
Diffstat (limited to 'include/mrc.sh')
-rw-r--r--include/mrc.sh9
1 files changed, 8 insertions, 1 deletions
diff --git a/include/mrc.sh b/include/mrc.sh
index 9c50af5c..1f3a1c9d 100644
--- a/include/mrc.sh
+++ b/include/mrc.sh
@@ -19,6 +19,7 @@ extract_refcode()
# cbfstool from coreboot 4.11_branch, the tree used by ASUS KGPE-D16:
if [ -z "$cbfstoolref" ]; then
+
err "cbfstoolref not set" "extract_refcode" "$@"
fi
@@ -27,8 +28,10 @@ extract_refcode()
x_ "$cbfstoolref" "$appdir/bios.bin" extract \
-m x86 -n fallback/refcode -f "$appdir/ref" -r RO_SECTION
- # enable the Intel GbE device, if told by offset MRC_refcode_gbe
+ # enable the Intel GbE device, if told by offset MRC_refcode_gbe:
+
if [ -n "$MRC_refcode_gbe" ]; then
+
x_ dd if="config/ifd/hp820g2/1.bin" of="$appdir/ref" bs=1 \
seek=$MRC_refcode_gbe count=1 conv=notrunc; :
fi
@@ -39,8 +42,11 @@ extract_refcode()
extract_mrc()
{
if [ -z "$MRC_board" ]; then
+
err "MRC_board unset" "extract_mrc" "$@"
+
elif [ -z "$CONFIG_MRC_FILE" ]; then
+
err "CONFIG_MRC_FILE unset" "extract_mrc" "$@"
fi
@@ -48,6 +54,7 @@ extract_mrc()
(
x_ cd "$appdir"
+
extract_partition "${MRC_url##*/}"
extract_archive "$SHELLBALL" .