summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/cpu/samsung/exynos5250/update-bl1.sh26
-rwxr-xr-xsrc/vendorcode/google/chromeos/build-snow21
2 files changed, 30 insertions, 17 deletions
diff --git a/src/cpu/samsung/exynos5250/update-bl1.sh b/src/cpu/samsung/exynos5250/update-bl1.sh
new file mode 100644
index 0000000000..e47b25db9d
--- /dev/null
+++ b/src/cpu/samsung/exynos5250/update-bl1.sh
@@ -0,0 +1,26 @@
+#!/bin/sh
+
+BL1_NAME="E5250.nbl1.bin"
+BL1_PATH="3rdparty/cpu/samsung/exynos5250/"
+BL1_URL="http://commondatastorage.googleapis.com/chromeos-localmirror/distfiles/exynos-pre-boot-0.0.2-r8.tbz2"
+
+get_bl1() {
+ mkdir -p "${BL1_PATH}"
+ cd "${BL1_PATH}"
+ wget "${BL1_URL}" -O bl1.tbz2
+ tar jxvf bl1.tbz2
+ mv "exynos-pre-boot/firmware/${BL1_NAME}" .
+ rm -rf exynos-pre-boot
+ if [ ! -e "${BL1_NAME}" ]; then
+ echo "Error getting BL1"
+ fi
+}
+
+main() {
+ if [ ! -e ${BL1_PATH}/${BL1_NAME} ]; then
+ get_bl1
+ fi
+}
+
+set -e
+main "$@"
diff --git a/src/vendorcode/google/chromeos/build-snow b/src/vendorcode/google/chromeos/build-snow
index a749ba535a..da1566bf1e 100755
--- a/src/vendorcode/google/chromeos/build-snow
+++ b/src/vendorcode/google/chromeos/build-snow
@@ -44,29 +44,16 @@ get_bl1() {
fi
}
-merge_bl1() {
- local outfile="$1"
- local bl1="${BL1_PATH}/${BL1_NAME}"
-
- if [ ! -e "$bl1" ]; then
- get_bl1
- fi
-
- # use the new BL1 which supports 30KB BL2/SPL/Coreboot
- local size="$(stat -c "%s" "$outfile")"
- local bl1_size="$(stat -c "%s" "$bl1")"
-
- [ "$bl1_size" = "$((0x2000))" ] || die "Incorrect BL1 input file."
- dd if="$bl1" of=${outfile} conv=notrunc
-}
-
is_servod_ready() {
ps -C servod >/dev/null 2>&1
}
main() {
+ if [ ! -e "$bl1" ]; then
+ get_bl1
+ fi
+
make
- merge_bl1 "$OUTPUT"
create_diff_192k "$OUTPUT" "$TMP_DIFF"
echo "OK: Generated image (with BL1) in $OUTPUT"
if is_servod_ready; then