summaryrefslogtreecommitdiffstats
path: root/meta/classes/kernel-uimage.bbclass
Commit message (Collapse)AuthorAgeFilesLines
* classes: Update classes to match new bitbake class scope functionalityRichard Purdie2022-08-121-41/+0
| | | | | | | | | Move classes to classes-global or classes-recipe as appropriate to take advantage of new bitbake functionality to check class scope/usage. (From OE-Core rev: f5c128008365e141082c129417eb72d2751e8045) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* classes: Add SPDX license identifiersRichard Purdie2022-08-121-0/+2
| | | | | | | | | | | | As stated in our top level license files, the license is MIT unless otherwise stated. Add SPDX identifers accordingly. Replace older license statementa with the standardised syntax. Also drop "All Rights Reserved" expression as it isn't used now, doesn't mean anything and is confusing. (From OE-Core rev: 081a391fe09a21265881e39a2a496e4e10b4f80b) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* classes: Add copyright statements to files without oneRichard Purdie2022-08-121-0/+4
| | | | | | | | | Where there isn't a copyright statement, add one to make it explicit. Also drop editor config lines where they were present. (From OE-Core rev: 880c1ea3edc8edef974e65b2d424fc36809ea034) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* meta: introduce UBOOT_MKIMAGE_KERNEL_TYPEMing Liu2022-07-151-1/+1
| | | | | | | | | | | | | | | | 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>
* u-boot: Add mkenvimage toolAlexey Brodkin2018-11-231-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | This utility is used for creation of images containing usable in run-time U-Boot environment. As of today this utility is added per-board like here [1] for Intel Edison board. [1] http://git.yoctoproject.org/cgit/cgit.cgi/meta-intel-edison/tree/meta-intel-edison-bsp/recipes-bsp/u-boot/u-boot-tools_2014.04.bb Given there're quite some U-Boot tools that we may want to add later this recipe name switch from "u-boot-mkimage" to generic "u-boot-tools" still for compatibility we provide "u-boot-mkimage" with help of PROVIDES as well as proposed "u-boot-mkenvimage". (From OE-Core rev: 314885b16e5d26d27d46a4bfb0d581b27a03b8fe) Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com> Cc: Richard Purdie <richard.purdie@linuxfoundation.org> Cc: Otavio Salvador <otavio@ossystems.com.br> Cc: Martin Jansa <martin.jansa@gmail.com> Cc: Ross Burton <ross.burton@intel.com> Cc: Marek Vasut <marex@denx.de> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* kernel-uimage.bbclass: Dependency on u-boot-mkimage-native for all uImagesReto Schneider2018-09-221-1/+1
| | | | | | | | | | | | | | | | | u-boot-mkimage-native is needed to build any type of uImages, be it the uImage target itself or for example uImage.lzma. The dependency however gets only added when at least one of KERNEL_IMAGETYPE and KERNEL_ALT_IMAGETYPE is exactly uImage. Building uImage.bin and uImage.lzma is not possible this way. This patch adds a dependency to u-boot-mkimage-native for all imagetypes which contains the string uImage. (From OE-Core rev: ac4ce0b07b2742c64d44f988ecb27e7200b5a0bc) Signed-off-by: Reto Schneider <code@reto-schneider.ch> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* kernel-uimage: optimise UBOOT_ENTRYSYMBOL supportAndré Draszik2017-09-251-1/+1
| | | | | | | | | | | | | | | This is the remaining local change to a fix similar to commit e0b4f018d1c2 ("kernel-uimage.bbclass: Fix up generation of uImage from vmlinux"): Make awk exit on match to save a few CPU cycles so as to make this similar to kernel-fitimage.bbclass (From OE-Core rev: 614e8be7a89a2f2113fa40b11e7a05b9e8155f6a) Signed-off-by: André Draszik <adraszik@tycoint.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* kernel-uimage.bbclass: Fix up generation of uImage from vmlinuxNathan Rossi2017-06-231-14/+12
| | | | | | | | | | | | | | | | | | | | | | Fix up the generation of uImage from vmlinux when KEEPUIMAGE != 'yes'. This fixes up the working directory that do_uboot_mkimage is run from, such that it is run from the ${B} directory to access built artefacts. Simplify the logic in the task so that the parse step either adds the task or not if the conditions are met. This reduces the need for the task to run in cases when it is not used. The task is also changed to depend on the kernel_link_images task as arch/<arch>/boot/* is not available until after kernel_link_images in certain cases (e.g. vmlinux/uImage only KERNEL_IMAGETYPES). Fix up the use of ${S}/vmlinux when pulling the entry symbols address so that it accesses the vmlinux in ${B}. (From OE-Core rev: e0b4f018d1c2a65e66c81e5be1da8894e9a6c132) Signed-off-by: Nathan Rossi <nathan@nathanrossi.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* meta: classes: Add building dir to uImage creationMylène Josserand2017-04-131-1/+1
| | | | | | | | | | | | | | On the do_uboot_mkimage task from kernel-uimage.bbclass, in case KEEPUIMAGE is different than the default "yes" value, the uboot-mkimage command fails because the path of the created uImage does not exist. On this task, we are under the BUILDDIR so there is no folder arch/<ARCH>/boot. Add the ${B} (for kernel build directory) as prefix to this folder fixes the problem. (From OE-Core rev: e5a6ee0d0655827d06a6030380277ee61a6db0ef) Signed-off-by: Mylène Josserand <mylene.josserand@free-electrons.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* classes: Replace "if test" file tests with POSIX file testsuninative-1.6Robert P. J. Day2017-03-271-1/+1
| | | | | | | | | | In entire meta/classes/ directory, replace shell tests of the form "if test -? ..." with POSIX tests of the form "if [ -? ... (From OE-Core rev: 78928016f4cf38cf6751cb089200bf950d07ae93) Signed-off-by: Robert P. J. Day <rpjday@crashcourse.ca> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* meta: remove True option to getVar callsJoshua Lock2016-12-161-4/+4
| | | | | | | | | | | | | getVar() now defaults to expanding by default, thus remove the True option from getVar() calls with a regex search and replace. Search made with the following regex: getVar ?\(( ?[^,()]*), True\) (From OE-Core rev: 7c552996597faaee2fbee185b250c0ee30ea3b5f) Signed-off-by: Joshua Lock <joshua.g.lock@intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* kernel-uimage.bbclass: indeed update var KERNEL_IMAGETYPE_FOR_MAKEKai Kang2016-07-261-2/+1
| | | | | | | | | | | | The replace() method of the python string class doesn't replace in-place, then the var KERNEL_IMAGETYPE_FOR_MAKE doesn't be updated as design. (From OE-Core rev: 392fc3cd276d5029314c7158245bc65dd82279cd) Signed-off-by: Kai Kang <kai.kang@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* kernel: Add KERNEL_IMAGETYPES to build multi types kernel at one timeHe Zhe2016-05-301-4/+6
| | | | | | | | | | | | | Add KERNEL_IMAGETYPES to support building packaging and installing multi types of kernel images, such as zImage uImage, at one time. KERNEL_IMAGETYPE and KERNEL_ALT_IMAGETYPE work as before. (From OE-Core rev: 849b67b2e4820564b5e5c9bd4bb293c44351c5f3) Signed-off-by: He Zhe <zhe.he@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* kernel-uimage: Fix python indentationRichard Purdie2016-05-211-6/+6
| | | | | | | | Use spaces, not tabs for python functions. (From OE-Core rev: 96ed92aded49fc47c7e407d36ba4f03dafee28cd) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* kernel-uimage: change target image to vmlinuxRuslan Bilovol2016-04-291-1/+1
| | | | | | | | | | | | | | | | | | | | | | | Commit e69525: "kernel: Build uImage only when really needed" hardcoded target kernel image to zImage for case if uImage is generated by OpenEmbedded buildsystem. However not all kernel architectures support zImage target, for example AArch64 doesn't, so building of kernel is failing on this step. So instead of building zImage target that may not exist for many architectures, build vmlinux target that exists for all architectures. Since kernel-uboot.bbclass uses vmlinux anyway for creating image, there is no side effect on this change. (From OE-Core rev: ac5d4d42a5903cbcafd7247c282df1cb98f79f08) Signed-off-by: Ruslan Bilovol <rbilovol@cisco.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* kernel: Build uImage only when really neededMarek Vasut2015-05-261-0/+8
| | | | | | | | | | | | | | | | | Build the uImage file using the kernel build system only when it is really required, which is only in case KEEPUIMAGE == yes. Otherwise, just build zImage, since the Yocto build system will handle the uImage generation for us. (From OE-Core rev: e6952593d810636f26af541b12126848483e619a) Signed-off-by: Marek Vasut <marex@denx.de> Cc: Richard Purdie <richard.purdie@linuxfoundation.org> Cc: Koen Kooi <koen@dominion.thruhere.net> Cc: Paul Eggleton <paul.eggleton@linux.intel.com> Cc: Ross Burton <ross.burton@intel.com> Cc: Bruce Ashfield <bruce.ashfield@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* kernel: Separate out uboot_prep_kimageMarek Vasut2015-05-261-22/+2
| | | | | | | | | | | | | | | | Separate the function which prepares the kernel for packing into uImage into separate class, so this function can be reused by the fitImage class. (From OE-Core rev: 2d1f700ad098c942834524891ccc90e3a391a09f) Signed-off-by: Marek Vasut <marex@denx.de> Cc: Richard Purdie <richard.purdie@linuxfoundation.org> Cc: Koen Kooi <koen@dominion.thruhere.net> Cc: Paul Eggleton <paul.eggleton@linux.intel.com> Cc: Ross Burton <ross.burton@intel.com> Cc: Bruce Ashfield <bruce.ashfield@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* kernel: Pull uImage generation into separate classMarek Vasut2015-05-261-0/+48
Pull the uImage image format generation from kernel.bbclass into a separate kernel-uimage.bbclass. Introduce new KERNEL_CLASSES variable, which allows registration of additional classes which implement new kernel image types. The default value of is to register kernel-uimage to preserve the original behavior. (From OE-Core rev: 086536ac84fcc9350802c09166f600becd52a1f8) Signed-off-by: Marek Vasut <marex@denx.de> Cc: Richard Purdie <richard.purdie@linuxfoundation.org> Cc: Koen Kooi <koen@dominion.thruhere.net> Cc: Paul Eggleton <paul.eggleton@linux.intel.com> Cc: Ross Burton <ross.burton@intel.com> Cc: Bruce Ashfield <bruce.ashfield@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>