Initial Commit
- initial default booting image
This commit is contained in:
5
board/khadas/vim3/extlinux.conf
Normal file
5
board/khadas/vim3/extlinux.conf
Normal file
@@ -0,0 +1,5 @@
|
||||
default buildroot
|
||||
label buildroot
|
||||
kernel /Image
|
||||
devicetree /meson-g12b-a311d-khadas-vim3.dtb
|
||||
append root=/dev/mmcblk0p2 rootwait console=ttyAML0,115200
|
||||
32
board/khadas/vim3/genimage.cfg
Normal file
32
board/khadas/vim3/genimage.cfg
Normal file
@@ -0,0 +1,32 @@
|
||||
image boot.vfat {
|
||||
vfat {
|
||||
files = {
|
||||
"Image",
|
||||
"meson-g12b-a311d-khadas-vim3.dtb",
|
||||
"extlinux"
|
||||
}
|
||||
|
||||
label = "boot"
|
||||
}
|
||||
|
||||
size = 64M
|
||||
}
|
||||
|
||||
image sdcard.img {
|
||||
hdimage {
|
||||
}
|
||||
|
||||
partition boot {
|
||||
partition-type = 0xC
|
||||
bootable = "true"
|
||||
image="boot.vfat"
|
||||
size = 64M
|
||||
offset = 2M
|
||||
}
|
||||
|
||||
partition rootfs {
|
||||
partition-type = 0x83
|
||||
image = "rootfs.ext2"
|
||||
offset = 0
|
||||
}
|
||||
}
|
||||
2
board/khadas/vim3/patches/linux/linux.hash
Normal file
2
board/khadas/vim3/patches/linux/linux.hash
Normal file
@@ -0,0 +1,2 @@
|
||||
# From https://www.kernel.org/pub/linux/kernel/v6.x/sha256sums.asc
|
||||
sha256 7c716216c3c4134ed0de69195701e677577bbcdd3979f331c182acd06bf2f170 linux-6.18.15.tar.xz
|
||||
2
board/khadas/vim3/patches/uboot/uboot.hash
Normal file
2
board/khadas/vim3/patches/uboot/uboot.hash
Normal file
@@ -0,0 +1,2 @@
|
||||
# Locally calculated
|
||||
sha256 b60d5865cefdbc75da8da4156c56c458e00de75a49b80c1a2e58a96e30ad0d54 u-boot-2026.01.tar.bz2
|
||||
5
board/khadas/vim3/post-build.sh
Executable file
5
board/khadas/vim3/post-build.sh
Executable file
@@ -0,0 +1,5 @@
|
||||
#!/bin/sh
|
||||
|
||||
BOARD_DIR="$(dirname "$0")"
|
||||
|
||||
install -m 0644 -D "$BOARD_DIR"/extlinux.conf "$BINARIES_DIR"/extlinux/extlinux.conf
|
||||
23
board/khadas/vim3/post-image.sh
Executable file
23
board/khadas/vim3/post-image.sh
Executable file
@@ -0,0 +1,23 @@
|
||||
#!/bin/sh
|
||||
|
||||
BOARD_DIR="$(dirname "$0")"
|
||||
|
||||
support/scripts/genimage.sh -c "${BOARD_DIR}/genimage.cfg"
|
||||
|
||||
AMLOGIC_DIR=${BINARIES_DIR}/amlogic-boot-fip
|
||||
FIP_DIR=${BINARIES_DIR}/fip
|
||||
|
||||
mkdir -p "${FIP_DIR}"
|
||||
|
||||
(cd "${AMLOGIC_DIR}" && \
|
||||
./build-fip.sh khadas-vim3 \
|
||||
"${BINARIES_DIR}"/u-boot.bin \
|
||||
"${FIP_DIR}")
|
||||
|
||||
dd if="${FIP_DIR}"/u-boot.bin.sd.bin \
|
||||
of="${BINARIES_DIR}"/sdcard.img \
|
||||
conv=fsync,notrunc bs=1 count=444
|
||||
|
||||
dd if="${FIP_DIR}"/u-boot.bin.sd.bin \
|
||||
of="${BINARIES_DIR}"/sdcard.img \
|
||||
conv=fsync,notrunc bs=512 skip=1 seek=1
|
||||
71
board/khadas/vim3/readme.txt
Normal file
71
board/khadas/vim3/readme.txt
Normal file
@@ -0,0 +1,71 @@
|
||||
Khadas VIM3
|
||||
|
||||
Description
|
||||
===========
|
||||
|
||||
This configuration builds a complete image for the Khadas VIM3 to be flashed
|
||||
on an SD-card.
|
||||
|
||||
How to build it
|
||||
===============
|
||||
|
||||
Select the default configuration for the target:
|
||||
$ make khadas_vim3_defconfig
|
||||
|
||||
Optional: modify the configuration:
|
||||
$ make menuconfig
|
||||
|
||||
Build:
|
||||
$ make
|
||||
|
||||
Result of the build
|
||||
===================
|
||||
output/images/
|
||||
+-- amlogic-boot-fip
|
||||
+ +-- build-fip.sh
|
||||
+ +-- g12a.inc
|
||||
+ `-- khadas-vim3
|
||||
+ +-- acs.bin
|
||||
+ +-- acs_tool.py
|
||||
+ +-- aml_ddr.fw
|
||||
+ +-- aml_encrypt_g12b
|
||||
+ +-- bl2.bin
|
||||
+ +-- bl301.bin
|
||||
+ +-- bl30.bin
|
||||
+ +-- bl31.bin
|
||||
+ +-- bl31.img
|
||||
+ +-- blx_fix.sh
|
||||
+ +-- ddr3_1d.fw
|
||||
+ +-- ddr4_1d.fw
|
||||
+ +-- ddr4_2d.fw
|
||||
+ +-- diag_lpddr4.fw
|
||||
+ +-- lpddr3_1d.fw
|
||||
+ +-- lpddr4_1d.fw
|
||||
+ +-- lpddr4_2d.fw
|
||||
+ +-- Makefile
|
||||
+ `-- piei.fw
|
||||
+-- boot.vfat
|
||||
+-- extlinux
|
||||
+ `-- extlinux.conf
|
||||
+-- fip
|
||||
+ +-- u-boot.bin
|
||||
+ +-- u-boot.bin.sd.bin
|
||||
+ +-- u-boot.bin.usb.bl2
|
||||
+ `-- u-boot.bin.usb.tpl
|
||||
+-- Image
|
||||
+-- meson-g12b-a311d-khadas-vim3.dtb
|
||||
+-- rootfs.ext2
|
||||
+-- rootfs.ext4 -> rootfs.ext2
|
||||
+-- rootfs.tar
|
||||
+-- sdcard.img
|
||||
`-- u-boot.bin
|
||||
|
||||
The post-image script uses the files in the amlogic-boot-fip folder to sign
|
||||
the bootloader image before integrating it into the sdcard image.
|
||||
|
||||
To copy the image file to the sdcard use dd:
|
||||
$ dd if=output/images/sdcard.img of=/dev/sdX
|
||||
|
||||
Tested hardware
|
||||
===============
|
||||
Khadas vim3 (rev. 14)
|
||||
Reference in New Issue
Block a user