330ac8e6d2
Chromebook Snow (Samsung XE303C12) is an Exynos 5 board with a keyboard, an 11 inch screen and a battery attached. It is relatively developer-friendly and can run mainline Linux kernels with little to no effort. There is barely anything special about this target as far as toolchain is concerned, but its bootloader only accepts signed kernel images in a Chromium OS specific format, and is not controllable otherwise. This config provides a script for building the proper kernel blobs, and a short manual for booting Buildroot images on this device. In-tree exynos_defconfig is used for the kernel, with a fragment to change mwifiex into a module. When built statically, mwifiex attempts to load its firmware before rootfs is mounted and fails. [Peter: use BR2_KERNEL_HEADERS_AS_KERNEL=y, lock kernel version, enable fit support in u-boot mkimage] Signed-off-by: Alex Suykov <alex.suykov@gmail.com> Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
42 lines
1.4 KiB
Bash
Executable File
42 lines
1.4 KiB
Bash
Executable File
#!/bin/sh
|
|
|
|
# This script creates u-boot FIT image containing the kernel and the DT,
|
|
# then signs it using futility from vboot-utils.
|
|
# The resulting file is called uImage.kpart.
|
|
|
|
BOARD_DIR=$(dirname $0)
|
|
mkimage=$HOST_DIR/usr/bin/mkimage
|
|
futility=$HOST_DIR/usr/bin/futility
|
|
devkeys=$HOST_DIR/usr/share/vboot/devkeys
|
|
|
|
run() { echo "$@"; "$@"; }
|
|
die() { echo "$@" >&2; exit 1; }
|
|
test -f $BINARIES_DIR/zImage || \
|
|
die "No kernel image found"
|
|
test -x $mkimage || \
|
|
die "No mkimage found (host-uboot-tools has not been built?)"
|
|
test -x $futility || \
|
|
die "No futility found (host-vboot-utils has not been built?)"
|
|
|
|
# kernel.its references zImage and exynos5250-snow.dtb, and all three
|
|
# files must be in current directory for mkimage.
|
|
run cp $BOARD_DIR/kernel.its $BINARIES_DIR/kernel.its || exit 1
|
|
echo "# entering $BINARIES_DIR for the next command"
|
|
(cd $BINARIES_DIR && run $mkimage -f kernel.its uImage.itb) || exit 1
|
|
|
|
# futility requires non-empty file to be supplied with --bootloader
|
|
# even if it does not make sense for the target platform.
|
|
echo > $BINARIES_DIR/dummy.txt
|
|
|
|
run $futility vbutil_kernel \
|
|
--keyblock $devkeys/kernel.keyblock \
|
|
--signprivate $devkeys/kernel_data_key.vbprivk \
|
|
--arch arm \
|
|
--version 1 \
|
|
--config $BOARD_DIR/kernel.args \
|
|
--vmlinuz $BINARIES_DIR/uImage.itb \
|
|
--bootloader $BINARIES_DIR/dummy.txt \
|
|
--pack $BINARIES_DIR/uImage.kpart || exit 1
|
|
|
|
rm -f $BINARIES_DIR/kernel.its $BINARIES_DIR/dummy.txt
|