Add wic support for sunxi 64 boards

Signed-off-by: Marek Belisko <marek.belisko@open-nandra.com>
Signed-off-by: ludiazv <ldiaz@atloideas.com>
This commit is contained in:
ludiazv 2023-05-08 22:42:36 +02:00 committed by Marek Belisko
parent 27aadbc9bf
commit 5723c27da1

View File

@ -10,7 +10,7 @@ PREFERRED_PROVIDER_virtual/bootloader ?= "u-boot"
KERNEL_IMAGETYPE ?= "Image" KERNEL_IMAGETYPE ?= "Image"
IMAGE_CLASSES += "sdcard_image-sunxi" IMAGE_CLASSES += "sdcard_image-sunxi"
IMAGE_FSTYPES += "ext4 tar.gz sunxi-sdimg" IMAGE_FSTYPES += "ext4 tar.gz wic.gz wic.bmap"
MACHINE_EXTRA_RRECOMMENDS = "kernel-modules" MACHINE_EXTRA_RRECOMMENDS = "kernel-modules"
@ -20,7 +20,33 @@ UBOOT_ENTRYPOINT ?= "0x40008000"
UBOOT_LOADADDRESS ?= "0x400080OB00" UBOOT_LOADADDRESS ?= "0x400080OB00"
#UBOOT_BINARY ?= "u-boot.itb" #UBOOT_BINARY ?= "u-boot.itb"
SPL_BINARY ?= "spl/sunxi-spl.bin" SPL_BINARY ?= "u-boot-sunxi-with-spl.bin"
SERIAL_CONSOLE ?= "115200 ttyS0" SERIAL_CONSOLE ?= "115200 ttyS0"
MACHINE_FEATURES ?= "alsa apm keyboard rtc serial screen usbgadget usbhost vfat" MACHINE_FEATURES ?= "alsa apm keyboard rtc serial screen usbgadget usbhost vfat"
# arm64 dbts are under <vendor>/dts but is deployed under DEPLOYDIR
do_fix_device_tree_location() {
for kdt in ${KERNEL_DEVICETREE}
do
local dbt_dir=$(dirname ${kdt})
if [ "." != "${dbt_dir}" ] ; then
local dbt=$(basename ${kdt})
local dst=${DEPLOY_DIR_IMAGE}/${dbt_dir}/${dbt}
if [ ! -f ${dst} ] ; then
mkdir -p ${DEPLOY_DIR_IMAGE}/$dbt_dir
ln -s ${DEPLOY_DIR_IMAGE}/${dbt} ${dst}
fi
fi
done
}
addtask do_fix_device_tree_location after do_write_wks_template before do_image_wic
SUNXI_BOOT_SPACE ?= "40"
IMAGE_BOOT_FILES ?= "${KERNEL_IMAGETYPE} boot.scr"
WKS_FILES ?= "sunxi-sdcard-image.wks.in"
WKS_FILE_DEPENDS ?= "virtual/kernel u-boot"