summaryrefslogtreecommitdiffstats
path: root/meta/classes/kernel-arch.bbclass
Commit message (Collapse)AuthorAgeFilesLines
* siteinfo: add aarch64_illp32 decodeArmin Kuster2018-02-241-0/+2
| | | | | | | | (From OE-Core rev: 8f9d6f92edb5682a7f2012af6466dbcd19e2e422) Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* kernel: Fix QA buildpaths warning for kernel modulesHe Zhe2018-02-161-1/+1
| | | | | | | | | | | | | | | CFLAGS is unset during kernel_do_compile and thus the default build path substitutions in DEBUG_PREFIX_MAP are missing. To enhance reproducible build for kernel modules, such as lttng-modules and cryptodev-module, this patch appends them, plus substitution of STAGING_KERNEL_DIR, to KERNEL_CC. (From OE-Core rev: ef7dac8511fc1647bc481c0e2ffa19e08e06f007) 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-arch.bbclass: Add riscv to kernel arch mapKhem Raj2017-11-051-1/+2
| | | | | | | | (From OE-Core rev: ac254fcc57cb044974445d89ce28a412c656e527) Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* kernel-arch.bbclass: conditional error messageJuro Bystricky2017-04-201-0/+2
| | | | | | | | | | | | | | | | | | | | The single purpose of "map_kernel_arch" is to set export ARCH = "some-arch" The case when "some-arch" is not a valid Linux architecture results in an error. This makes sense if the TARGET_OS is Linux, but that is not always the case. kernel-arch is also inherited by toolchain-script, which may be used to build toolchains for architectures not supported by Linux. Rather than modifying toolchain-script to provide its own version of "map_arch" this patch bypasses the error if the TARGET_OS is not linux. (From OE-Core rev: 0b931e983b1f663d5d7dc65f1db7687334dd3ef2) Signed-off-by: Juro Bystricky <juro.bystricky@intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* kernel-arch: Lock the toolchain to use gcc compilerKhem Raj2017-03-081-0/+1
| | | | | | | | | | kernel and external modules are still using gcc to build (From OE-Core rev: 75cf0f0690c9c192e4cbffb71015866f967c2e1f) Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* meta: remove True option to getVar callsJoshua Lock2016-12-161-3/+3
| | | | | | | | | | | | | 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-arch.bbclass: Add xtensa and arc into valid_archs tableJuro Bystricky2016-10-151-1/+1
| | | | | | | | | | | Both "arc" and "xtensa" are valid Linux architectures, add them into valid_archs table. (From OE-Core rev: 20d511cd1b7fe4891f7842be12f13a92da433c46) Signed-off-by: Juro Bystricky <juro.bystricky@intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* kernel-arch.bbclass: Add mipsisa{32, 64}r6{el, } supportZubair Lutfullah Kakakhel2016-10-071-1/+1
| | | | | | | | | Add support for MIPS Release 6 ISA (From OE-Core rev: aecb57f2fd65a1bfbc2e9a23fba4984d44055c4c) Signed-off-by: Zubair Lutfullah Kakakhel <Zubair.Kakakhel@imgtec.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* Revert "kernel/kernel-arch: Explicitly mapping between i386/x86_64 and x86 ↵Ioan-Adrian Ratiu2016-02-041-3/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | for kernel ARCH" This reverts commit 8d310b24927d0f348fb431895f0583733db2aad0. That commit completely breaks KBUILD_DEFCONFIG because it relies on $ARCH to match between the target OE arch and the kernel subdirectory containing the defconfigs. In the kernel all defconfigs for everything x86-based (including x86_64) is stored in dir arch/x86/configs/ kernel-yocto.bbclass correctly searches for all the defconfigs inside ${S}/arch/${ARCH}/configs/${KBUILD_DEFCONFIG} Commit 8d310b249 makes it search in wrong places and _only_ if you define TARGET_ARCH = "athlon" will it search x86 which is nonsensical. The commit further adds an if clause to hack the mungled kernel arches back to their original values (ugh) in do_shared_workdir which is run after do compile, but of course the build breaks before that in do_kernel_metadata because of the KBUILD_DEFCONFIG mentioned above (so that hack is useless). Please fix that corner case bug in another way which does not completely screw up the kernel arch mapping & defconfig logic. If 64bit configs are generated in the kernel for 32bit machines because the host is asked, then it it a bug in the kernel, it is of no use to hack around it in OE. (From OE-Core rev: bc02a478a5d4a5de7b3943ed809d5c22711f5b1f) Signed-off-by: Ioan-Adrian Ratiu <adrian.ratiu@ni.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* kernel/kernel-arch: Explicitly mapping between i386/x86_64 and x86 for ↵Jianxun Zhang2016-01-151-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | kernel ARCH For a bare-bone kernel recipe which specifies 32 bit x86 target, a 64 bit .config will be generated from do_configure task when building 32-bit qemux86, once all of these conditions are true: * arch of host is x86_64 * kernel source tree used in build has commit ffee0de41 which actually chooses i386 or x86_64 defconfig by asking host when ARCH is "x86" (arch/x86/Makefile) * bare-bone kernel recipe inherits directly from kernel without other special treatments. Build will fail because of the mismatched kernel architecture. The patch sets ARCH i386 or x86_64 explicitly to configure task to avoid this host contamination. Kernel artifact is also changed so that it can map i386 and x64 back to arch/x86 when needed. (From OE-Core rev: 8d310b24927d0f348fb431895f0583733db2aad0) Signed-off-by: Jianxun Zhang <jianxun.zhang@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* kernel-arch: Add nios2 to valid archsMarek Vasut2015-09-231-1/+2
| | | | | | | | | | | | | | Add nios2 target to valid arch list definition. Based on previous work by Walter Goossens <waltergoossens@home.nl> at https://github.com/wgoossens/meta-nios2 . (From OE-Core rev: f0af7d0d9316a6eeacc0686b8c4640491f255883) Signed-off-by: Marek Vasut <marex@denx.de> Cc: Walter Goossens <waltergoossens@home.nl> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* kernel-arch: Force BFD kernel when using gcc for linkingKhem Raj2015-08-241-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | We redefine LD to point to ld.bfd when building kernel, which works in most cases since kbuild system calls out for bare LD most of the time, however some of newer kernels e.g. 4.1+ have some code added which can call gcc directly to do the linking job e.g. arm vdso code This causes build failures when we have configured the default cross toolchain to use gold linker as default. Errors like BFD: arch/arm/vdso/vdso.so: Not enough room for program headers, try linking with -N | arm-angstrom-linux-gnueabi-objcopy:arch/arm/vdso/vdso.so[.hash]: Bad value start happening. With this patch we force gcc to choose bfd linker as well (From OE-Core rev: 5724e4d245f142ac6fb1ea211503fd220683354d) Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* kernel-arch: Update mapping for MicroBlaze architecturesNathan Rossi2015-05-051-1/+1
| | | | | | | | | | * Add pattern matching for the 'microblazeeb' architecture which maps to 'microblaze' in the same way as 'microblazeel' (From OE-Core rev: c2f488f629b3dd604db171772b762d46a28c2895) Signed-off-by: Nathan Rossi <nathan.rossi@xilinx.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* Revert "kernel-arch.bbclass: add arm64 support to U-Boot architecture map"Nathan Rossi2015-02-211-1/+0
| | | | | | | | | | | | | | | | This reverts commit 0b891265716c414ade29d587fc1a3c4ea7beadbe. U-Boot does support AArch64, this however was only added to newer versions of U-Boot and at the time of this original commit the U-Boot in OE-Core did not support the 'arm64' architecture. OE-Core now has a newer version of U-Boot for the mkimage recipe and thus supports the 'arm64' architecture. (From OE-Core rev: fd8158134f3d7a7c795c818cc50eb2858a6cae06) Signed-off-by: Nathan Rossi <nathan.rossi@xilinx.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* kernel-arch.bbclass: add arm64 support to U-Boot architecture mapFathi Boudra2014-03-211-0/+1
| | | | | | | | | | | | to define UBOOT_ARCH, we map kernel architectures to U-Boot architectures. In the case of arm64 kernel, we should map to arm U-boot architecture. This patch add the exception rule to the map_uboot_arch function. (From OE-Core rev: 0b891265716c414ade29d587fc1a3c4ea7beadbe) Signed-off-by: Fathi Boudra <fathi.boudra@linaro.org> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* classes: add aarch64_be targetVictor Kamensky2013-10-141-0/+1
| | | | | | | | | | Add big endian ARMv8 target to OE infrastructure (From OE-Core rev: 570ae1afecc88b12a11e62a4341069c125d18403) Signed-off-by: Victor Kamensky <victor.kamensky@linaro.org> Signed-off-by: Koen Kooi <koen.kooi@linaro.org> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* kernel-arch: Always use ld.bfd to link the kernelPhil Blundell2013-04-281-1/+1
| | | | | | | | | | | | The kernel's penchant for custom linker scripts means that it doesn't generally get on very well with gold. Make sure we are using the BFD linker here no matter what the distro default is set to. (From OE-Core rev: 5c8277610ae84740e0724b27f10dba3895d40c05) Signed-off-by: Phil Blundell <philb@gnu.org> Signed-off-by: Saul Wold <sgw@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* kernel-arch.bbclass: don't pass extra args to KERNEL_{CC, LD, AR}Matthew McClintock2013-03-051-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Commit a3ca06c3b45c791dd38dbf154ad0fc62b4063475 added extra args to KERNEL_CC, these revert that bit while maintaining machine additions in TARGET_??_KERNEL_ARCH Producing incorrect instructions and generating the following errors: CC arch/powerpc/kernel/init_task.o | {standard input}: Assembler messages: | {standard input}:384: Error: junk at end of line: `1' | {standard input}:949: Error: junk at end of line: `1' | {standard input}:1428: Error: junk at end of line: `1' | {standard input}:1526: Error: junk at end of line: `1' | {standard input}:1626: Error: junk at end of line: `1' | {standard input}:1685: Error: junk at end of line: `1' | {standard input}:1973: Error: junk at end of line: `1' | {standard input}:2001: Error: junk at end of line: `1' | {standard input}:2100: Error: junk at end of line: `1' | {standard input}:2168: Error: junk at end of line: `1' | {standard input}:2520: Error: junk at end of line: `1' | CC arch/powerpc/lib/locks.o (From OE-Core rev: 6ed278ab93e9c3bb291dd37837c27e120954afc7) Signed-off-by: Matthew McClintock <msm@freescale.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* kernel.bbclass, module-base.bbclass: Use CC to form KERNEL_CCKhem Raj2013-01-201-0/+13
| | | | | | | | | | | | | | | | | | | kernel compiler is not special and we currently have it so we want to pass -march and -mtune options as CFLAGS to kernel build so that compiler picks the right subarch flags when compiling assembly files in particular. Otherwise defaults are chosen which may not be right in many case e.g. when compiling kernel for collie machine we should use arch=armv4 but it uses toolchain/as defaults which is armv5te in some case e.g. thumb1 we know that kernel can not be compiled in thumb1 mode so we can provide that information e.g. -marm option through KERNEL_HOST_CC_ARCH variable as we do now (From OE-Core rev: c49f967384ccbfe131bbb33ee518014f3fc4b38f) Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* kernel-arch.bblass: add AArch64 supportMarcin Juszkiewicz2012-10-181-1/+2
| | | | | | | | (From OE-Core rev: 9583a46221580ba46ebfd6d561d3a4d6b0d42eea) Signed-off-by: Marcin Juszkiewicz <marcin.juszkiewicz@linaro.org> Signed-off-by: Saul Wold <sgw@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* Convert tab indentation in python functions into four-spaceRichard Purdie2012-07-191-21/+21
| | | | | | (From OE-Core rev: 604d46c686d06d62d5a07b9c7f4fa170f99307d8) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* kernel-arch: Remove test for long-dead arm26 architecture.Robert P. J. Day2012-07-021-2/+1
| | | | | | | (From OE-Core rev: ff3f912eed0270afa14d706fc1e57f8a1de2614b) Signed-off-by: Robert P. J. Day <rpjday@crashcourse.ca> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* kernel-arch.bbclass: Map mips64{el} to mips KARCHKhem Raj2012-05-211-1/+1
| | | | | | | (From OE-Core rev: 22ce249a814f750bc47ead9ce281fcbd63c775c8) Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* meta: Convert getVar/getVarFlag(xxx, 1) -> (xxx, True)Richard Purdie2012-03-051-3/+3
| | | | | | | | | | | | Using "1" with getVar is bad coding style and "True" is preferred. This patch is a sed over the meta directory of the form: sed \ -e 's:\(\.getVar([^,()]*, \)1 *):\1True):g' \ -e 's:\(\.getVarFlag([^,()]*, [^,()]*, \)1 *):\1True):g' \ -i `grep -ril getVar *` Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* Convert to use direct access to the data store (instead of bb.data.*Var*())Richard Purdie2011-11-101-3/+3
| | | | | | | | | | | | | | | | | This is the result of running the following over the metadata: sed \ -e 's:bb.data.\(setVar([^,()]*,[^,()]*\), *\([^ )]*\) *):\2.\1):g' \ -e 's:bb.data.\(setVarFlag([^,()]*,[^,()]*,[^,()]*\), *\([^) ]*\) *):\2.\1):g' \ -e 's:bb.data.\(getVar([^,()]*\), *\([^(), ]*\) *,\([^)]*\)):\2.\1,\3):g' \ -e 's:bb.data.\(getVarFlag([^,()]*,[^,()]*\), *\([^(), ]*\) *,\([^)]*\)):\2.\1,\3):g' \ -e 's:bb.data.\(getVarFlag([^,()]*,[^,()]*\), *\([^() ]*\) *):\2.\1):g' \ -e 's:bb.data.\(getVar([^,()]*\), *\([^) ]*\) *):\2.\1):g' \ -i `grep -ril bb.data *` (From OE-Core rev: b22831fd63164c4db9c0b72934d7d734a6585251) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* kernel-arch: Add handling of powerpc64Kumar Gala2011-07-221-2/+3
| | | | | | | (From OE-Core rev: ed6b9934b33cff3173d327b09e05ee02aa3a68c8) Signed-off-by: Kumar Gala <galak@kernel.crashing.org> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* kernel-arch: microblaze little endian fix kernel archAdrian Alonso2011-07-071-0/+1
| | | | | | | | | | | * In map_kernel_arch function return valid arch for microblazeel target arch. if TARGET_ARCH = "microblazeel" return "microblaze" (From OE-Core rev: 86e36055dc61279c9c3616ad4bc47695f83bad06) Signed-off-by: Adrian Alonso <aalonso@secretlab.ca> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* kernel-arch: add microblaze to valid archsAdrian Alonso2011-05-101-1/+2
| | | | | | | | | * Add Microblaze target to valid arch list definition (From OE-Core rev: 709a199bd18478b5d7af6bf6130e5210793c7ad2) Signed-off-by: Adrian Alonso <aalonso@secretlab.ca> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* kernel-arch: x86-64 is no longer a valid architecture, map it to x86Joshua Lock2010-08-131-8/+8
| | | | | | | Also use the exported (and re-mapped) ARCH rather than TARGET_ARCH in the linux-wrs recipe. Signed-off-by: Joshua Lock <josh@linux.intel.com>
* qemu: update kernel mapping to return x86 for i586 TARGET_ARCHBruce Ashfield2010-07-191-1/+1
| | | | Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
* kernel-arch.bbclass: merge improved arch detection from OE.devJoshua Lock2010-05-201-2/+4
| | | | Signed-off-by: Joshua Lock <josh@linux.intel.com>
* classes: Remove and sanitise import statementsRichard Purdie2009-11-131-1/+1
| | | | Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
* kernel-arch.bbclass: Sync with OE.devRichard Purdie2008-04-081-1/+9
| | | | git-svn-id: https://svn.o-hand.com/repos/poky/trunk@4210 311d38ba-8fff-0310-9ca6-ca027cbcb966
* classes: Sync various classes with OE for various bugfixesRichard Purdie2007-08-081-6/+11
| | | | git-svn-id: https://svn.o-hand.com/repos/poky/trunk@2407 311d38ba-8fff-0310-9ca6-ca027cbcb966
* classes: Sync with OERichard Purdie2006-08-271-0/+1
| | | | git-svn-id: https://svn.o-hand.com/repos/poky/trunk@651 311d38ba-8fff-0310-9ca6-ca027cbcb966
* Rename /openembedded/ -> /meta/Richard Purdie2006-07-211-0/+26
git-svn-id: https://svn.o-hand.com/repos/poky/trunk@530 311d38ba-8fff-0310-9ca6-ca027cbcb966