2 # Copyright 2018-2020 NXP
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
10 FILESYSTEMS
:= squashfs
11 IMAGES
:= firmware.bin sysupgrade.bin
12 KERNEL
:= kernel-bin | uImage none
13 KERNEL_INITRAMFS
= kernel-bin | gzip | fit gzip
$$(DTS_DIR
)/$$(DEVICE_DTS
).dtb
15 KERNEL_LOADADDR
:= 0x80008000
16 KERNEL_ENTRY_POINT
:= 0x80008000
17 DEVICE_DTS
= $(lastword
$(subst _
, ,$(1)))
18 SUPPORTED_DEVICES
= $(subst _
,$(comma
),$(1))
20 IMAGE
/sysupgrade.bin
= \
21 ls-append-dtb
$$(DEVICE_DTS
) | pad-to
1M | \
22 append-kernel | pad-to
17M | \
23 append-rootfs | pad-rootfs | \
24 check-size
$(LS_SYSUPGRADE_IMAGE_SIZE
) | append-metadata
27 define Device
/fsl-sdboot
28 $(Device
/rework-sdcard-images
)
29 KERNEL
= kernel-bin | gzip | fit gzip
$$(DTS_DIR
)/$$(DEVICE_DTS
).dtb
30 IMAGES
:= sdcard.img.gz sysupgrade.bin
31 IMAGE
/sysupgrade.bin
:= sysupgrade-tar | append-metadata
34 define Device
/fsl_ls1021a-twr
35 $(Device
/fix-sysupgrade
)
37 DEVICE_MODEL
:= TWR-LS1021A
38 DEVICE_VARIANT
:= Default
39 DEVICE_PACKAGES
+= layerscape-rcw
40 IMAGE
/firmware.bin
:= \
42 ls-append
$(1)-rcw.bin | pad-to
1M | \
43 ls-append
$(1)-uboot.bin | pad-to
3M | \
44 ls-append
$(1)-uboot-env.bin | pad-to
15M | \
45 ls-append-dtb
$$(DEVICE_DTS
) | pad-to
16M | \
46 append-kernel | pad-to
32M | \
47 append-rootfs | pad-rootfs | check-size
49 TARGET_DEVICES
+= fsl_ls1021a-twr
51 define Device
/fsl_ls1021a-twr-sdboot
54 DEVICE_MODEL
:= TWR-LS1021A
55 DEVICE_VARIANT
:= SD Card Boot
56 DEVICE_DTS
:= ls1021a-twr
57 IMAGE
/sdcard.img.gz
:= \
59 ls-append-sdhead
$(1) | pad-to
4K | \
60 ls-append
$(1)-uboot.bin | pad-to
3M | \
61 ls-append
$(1)-uboot-env.bin | pad-to
16M | \
62 ls-append-kernel | pad-to
$(LS_SD_ROOTFSPART_OFFSET
)M | \
63 append-rootfs | pad-to
$(LS_SD_IMAGE_SIZE
)M | gzip
65 TARGET_DEVICES
+= fsl_ls1021a-twr-sdboot
67 define Device
/fsl_ls1021a-iot-sdboot
70 DEVICE_MODEL
:= LS1021A-IoT
71 DEVICE_VARIANT
:= SD Card Boot
72 DEVICE_DTS
:= ls1021a-iot
74 IMAGE
/sdcard.img.gz
:= \
76 ls-append-sdhead
$(1) | pad-to
4K | \
77 ls-append
$(1)-uboot.bin | pad-to
1M | \
78 ls-append
$(1)-uboot-env.bin | pad-to
16M | \
79 ls-append-kernel | pad-to
$(LS_SD_ROOTFSPART_OFFSET
)M | \
80 append-rootfs | pad-to
$(LS_SD_IMAGE_SIZE
)M | gzip
82 TARGET_DEVICES
+= fsl_ls1021a-iot-sdboot