target/rockchip: r66s r68s combined
This commit is contained in:
parent
4280e3c663
commit
74d1e0a7f8
@ -20,6 +20,21 @@ define Build/boot-common
|
||||
$(CP) $(IMAGE_KERNEL) $@.boot/kernel.img
|
||||
endef
|
||||
|
||||
define Build/boot-combined
|
||||
# This creates a new folder copies the dtbs (as rockchip*.dtb)
|
||||
# and the kernel image (as kernel.img)
|
||||
rm -fR $@.boot
|
||||
mkdir -p $@.boot
|
||||
|
||||
i=0; \
|
||||
for dts in $(DEVICE_DTS); do \
|
||||
$(CP) $(KDIR)/image-$${dts}.dtb $@.boot/rockchip$$(perl -e 'printf "%b\n",'$$i).dtb; \
|
||||
let i+=1; \
|
||||
done
|
||||
$(LN) rockchip0.dtb $@.boot/rockchip.dtb
|
||||
$(CP) $(IMAGE_KERNEL) $@.boot/kernel.img
|
||||
endef
|
||||
|
||||
define Build/boot-script
|
||||
# Make an U-boot image and copy it to the boot partition
|
||||
mkimage -A arm -O linux -T script -C none -a 0 -e 0 -d $(if $(1),$(1),mmc).bootscript $@.boot/boot.scr
|
||||
|
||||
20
target/linux/rockchip/image/rk3568-cb.bootscript
Normal file
20
target/linux/rockchip/image/rk3568-cb.bootscript
Normal file
@ -0,0 +1,20 @@
|
||||
# rk3568 combined image
|
||||
|
||||
env delete hwflag
|
||||
|
||||
# using gpio 84 (GPIO2_C4, GMAC0_MDIO) to detect gmac0
|
||||
if gpio input 84; then
|
||||
echo nogmac
|
||||
else
|
||||
echo hasgmac
|
||||
setenv hwflag 1
|
||||
fi
|
||||
|
||||
part uuid mmc ${devnum}:2 uuid
|
||||
|
||||
setenv bootargs "earlycon=uart8250,mmio32,0xfe660000 console=ttyFIQ0 root=PARTUUID=${uuid} rw rootwait"
|
||||
|
||||
load mmc ${devnum}:1 ${fdt_addr_r} rockchip${hwflag}.dtb
|
||||
load mmc ${devnum}:1 ${kernel_addr_r} kernel.img
|
||||
|
||||
booti ${kernel_addr_r} - ${fdt_addr_r}
|
||||
@ -24,6 +24,15 @@ $(call Device/fastrhino_common)
|
||||
endef
|
||||
TARGET_DEVICES += fastrhino_r68s
|
||||
|
||||
define Device/fastrhino_r6xs
|
||||
$(call Device/fastrhino_common)
|
||||
DEVICE_MODEL := R68s/R66s combined
|
||||
SUPPORTED_DEVICES += fastrhino,r66s fastrhino,r68s
|
||||
DEVICE_DTS := rk3568-r66s rk3568-r68s
|
||||
IMAGE/sysupgrade.img.gz := boot-combined | boot-script rk3568-cb | pine64-img | gzip | append-metadata
|
||||
endef
|
||||
TARGET_DEVICES += fastrhino_r6xs
|
||||
|
||||
define Device/hinlink_opc-h68k
|
||||
$(call Device/rk3568)
|
||||
DEVICE_VENDOR := HINLINK
|
||||
|
||||
Loading…
Reference in New Issue
Block a user