mirror of
git://git.yoctoproject.org/poky.git
synced 2025-07-19 21:09:03 +02:00
meta: introduce UBOOT_MKIMAGE_KERNEL_TYPE
Sometimes an end user might want to choose another kernel type argument for uboot-mkimage other than "kernel", for instance: "kernel_noload". Let's introduce a variable UBOOT_MKIMAGE_KERNEL_TYPE to support that, and it could be used by BSP layers as well. (From OE-Core rev: e288686e97de1265eeeaf452141e1473867efb1b) (From OE-Core rev: 4eb7bbcc2f08b25387a15b7e4a89ef199783c973) Signed-off-by: Ming Liu <liu.ming50@gmail.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
parent
a508d0cf1b
commit
e116ad7c69
|
@ -148,7 +148,7 @@ fitimage_emit_section_kernel() {
|
|||
kernel-$2 {
|
||||
description = "Linux kernel";
|
||||
data = /incbin/("$3");
|
||||
type = "kernel";
|
||||
type = "${UBOOT_MKIMAGE_KERNEL_TYPE}";
|
||||
arch = "${UBOOT_ARCH}";
|
||||
os = "linux";
|
||||
compression = "$4";
|
||||
|
|
|
@ -2,6 +2,9 @@
|
|||
FIT_KERNEL_COMP_ALG ?= "gzip"
|
||||
FIT_KERNEL_COMP_ALG_EXTENSION ?= ".gz"
|
||||
|
||||
# Kernel image type passed to mkimage (i.e. kernel kernel_noload...)
|
||||
UBOOT_MKIMAGE_KERNEL_TYPE ?= "kernel"
|
||||
|
||||
uboot_prep_kimage() {
|
||||
if [ -e arch/${ARCH}/boot/compressed/vmlinux ]; then
|
||||
vmlinux_path="arch/${ARCH}/boot/compressed/vmlinux"
|
||||
|
|
|
@ -30,6 +30,6 @@ do_uboot_mkimage() {
|
|||
awk '$3=="${UBOOT_ENTRYSYMBOL}" {print "0x"$1;exit}'`
|
||||
fi
|
||||
|
||||
uboot-mkimage -A ${UBOOT_ARCH} -O linux -T kernel -C "${linux_comp}" -a ${UBOOT_LOADADDRESS} -e $ENTRYPOINT -n "${DISTRO_NAME}/${PV}/${MACHINE}" -d linux.bin ${B}/arch/${ARCH}/boot/uImage
|
||||
uboot-mkimage -A ${UBOOT_ARCH} -O linux -T ${UBOOT_MKIMAGE_KERNEL_TYPE} -C "${linux_comp}" -a ${UBOOT_LOADADDRESS} -e $ENTRYPOINT -n "${DISTRO_NAME}/${PV}/${MACHINE}" -d linux.bin ${B}/arch/${ARCH}/boot/uImage
|
||||
rm -f linux.bin
|
||||
}
|
||||
|
|
|
@ -738,6 +738,7 @@ UBOOT_LOADADDRESS = "0x80000000"
|
|||
UBOOT_DTB_LOADADDRESS = "0x82000000"
|
||||
UBOOT_ARCH = "arm"
|
||||
UBOOT_MKIMAGE_DTCOPTS = "-I dts -O dtb -p 2000"
|
||||
UBOOT_MKIMAGE_KERNEL_TYPE = "kernel"
|
||||
UBOOT_EXTLINUX = "0"
|
||||
FIT_GENERATE_KEYS = "1"
|
||||
KERNEL_IMAGETYPE_REPLACEMENT = "zImage"
|
||||
|
@ -763,6 +764,7 @@ FIT_HASH_ALG = "sha256"
|
|||
|
||||
kernel_load = str(get_bb_var('UBOOT_LOADADDRESS'))
|
||||
kernel_entry = str(get_bb_var('UBOOT_ENTRYPOINT'))
|
||||
kernel_type = str(get_bb_var('UBOOT_MKIMAGE_KERNEL_TYPE'))
|
||||
kernel_compression = str(get_bb_var('FIT_KERNEL_COMP_ALG'))
|
||||
uboot_arch = str(get_bb_var('UBOOT_ARCH'))
|
||||
fit_hash_alg = str(get_bb_var('FIT_HASH_ALG'))
|
||||
|
@ -775,7 +777,7 @@ FIT_HASH_ALG = "sha256"
|
|||
'kernel-1 {',
|
||||
'description = "Linux kernel";',
|
||||
'data = /incbin/("linux.bin");',
|
||||
'type = "kernel";',
|
||||
'type = "' + kernel_type + '";',
|
||||
'arch = "' + uboot_arch + '";',
|
||||
'os = "linux";',
|
||||
'compression = "' + kernel_compression + '";',
|
||||
|
|
Loading…
Reference in New Issue
Block a user