Re: bitbake controlling memory use
I use
BUILDHISTORY_COMMIT_forcevariable = "1" PARALLEL_MAKE = "-j 11" BB_NUMBER_THREADS = "11" INHERIT += "rm_work" XZ_DEFAULTS = "--threads=8" On Tue, Apr 13, 2021 at 6:15 PM Randy MacLeod <randy.macleod@...> wrote:
|
|
Re: [qa-build-notification] QA notification for completed autobuilder build (yocto-3.1.7.rc1)
Sangeeta Jain
Hi all,
toggle quoted messageShow quoted text
Intel and WR YP QA is planning for QA execution for YP build yocto-3.1.7.rc1 We are planning to execute following tests for this cycle: OEQA-manual tests for following module: 1. OE-Core 2. BSP-hw Runtime auto test for following platforms: 1. MinnowTurbot 32-bit 2. Coffee Lake 3. NUC 7 4. NUC 6 5. Edgerouter 6. Beaglebone ETA for completion is next Monday, April 19 Thanks, Sangeeta
-----Original Message-----
|
|
[meta-mingw] [PATCH] mingw-w64: Check for __builtin_ia32_rdtsc
Signed-off-by: Khem Raj <raj.khem@...>
--- ...rincs-Check-for-__builtin_ia32_rdtsc.patch | 33 +++++++++++++++++++ .../nativesdk-mingw-w64-runtime_7.0.0.bb | 2 ++ 2 files changed, 35 insertions(+) create mode 100644 recipes-devtools/mingw-w64/files/0001-intrincs-Check-for-__builtin_ia32_rdtsc.patch diff --git a/recipes-devtools/mingw-w64/files/0001-intrincs-Check-for-__builtin_ia32_rdtsc.patch b/recipes-devtools/mingw-w64/files/0001-intrincs-Check-for-__builtin_ia32_rdtsc.patch new file mode 100644 index 0000000..ce4ba81 --- /dev/null +++ b/recipes-devtools/mingw-w64/files/0001-intrincs-Check-for-__builtin_ia32_rdtsc.patch @@ -0,0 +1,33 @@ +From 346de7591f58015d111f4d4f3b001382c04d5557 Mon Sep 17 00:00:00 2001 +From: Khem Raj <raj.khem@...> +Date: Tue, 13 Apr 2021 18:44:25 -0700 +Subject: [PATCH] intrincs: Check for __builtin_ia32_rdtsc + +on modern gcc ( >=4.6 ) __rdtsc function is implemented using +special builtin function called __builtin_ia32_rdtsc, its actually +a define in gcc, so __has_builtin check fails for __rdtsc even +though it is defined to imply __builtin_ia32_rdtsc(), therefore +check for existence of __builtin_ia32_rdtsc as well + +Upstream-Status: Pending +Signed-off-by: Khem Raj <raj.khem@...> +--- + mingw-w64-crt/intrincs/rdtsc.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/mingw-w64-crt/intrincs/rdtsc.c b/mingw-w64-crt/intrincs/rdtsc.c +index bf9c03b..df04711 100644 +--- a/mingw-w64-crt/intrincs/rdtsc.c ++++ b/mingw-w64-crt/intrincs/rdtsc.c +@@ -11,7 +11,7 @@ + #define __has_builtin(x) 0 + #endif + +-#if !__has_builtin(__rdtsc) ++#if !__has_builtin(__rdtsc) && !__has_builtin(__builtin_ia32_rdtsc) + unsigned __int64 __rdtsc(void) + { + #ifdef _WIN64 +-- +2.31.1 + diff --git a/recipes-devtools/mingw-w64/nativesdk-mingw-w64-runtime_7.0.0.bb b/recipes-devtools/mingw-w64/nativesdk-mingw-w64-runtime_7.0.0.bb index 9f79ffe..0368841 100644 --- a/recipes-devtools/mingw-w64/nativesdk-mingw-w64-runtime_7.0.0.bb +++ b/recipes-devtools/mingw-w64/nativesdk-mingw-w64-runtime_7.0.0.bb @@ -2,6 +2,8 @@ DESCRIPTION = "Runtime libraries from MinGW-w64 project" require mingw-w64.inc +SRC_URI += "file://0001-intrincs-Check-for-__builtin_ia32_rdtsc.patch;striplevel=2" + S = "${WORKDIR}/mingw-w64-v${PV}/mingw-w64-crt" B = "${WORKDIR}/build-${TARGET_SYS}" -- 2.31.1
|
|
[meta-security][PATCH 2/2] lkrg-module: Add Linux Kernel Runtime Guard
For more info see: https://github.com/openwall/lkrg
Add to local.conf: IMAGE_INSTALL_append = " kernel-module-lkrg" Need these kconfig options enabled: CONFIG_KALLSYMS_ALL=y CONFIG_JUMP_LABEL=y CONFIG_DEBUG_KERNEL=y To invoke module: sudo insmod {path-to-modules}/p_lkrg.ko kint_enforce=1 Signed-off-by: Armin Kuster <akuster808@...> --- .../lkrg/files/makefile_cleanup.patch | 73 +++++++++++++++++++ recipes-kernel/lkrg/lkrg-module_0.9.0.bb | 33 +++++++++ 2 files changed, 106 insertions(+) create mode 100644 recipes-kernel/lkrg/files/makefile_cleanup.patch create mode 100644 recipes-kernel/lkrg/lkrg-module_0.9.0.bb diff --git a/recipes-kernel/lkrg/files/makefile_cleanup.patch b/recipes-kernel/lkrg/files/makefile_cleanup.patch new file mode 100644 index 0000000..106dc3f --- /dev/null +++ b/recipes-kernel/lkrg/files/makefile_cleanup.patch @@ -0,0 +1,73 @@ +Upstream-Status: Pending + +This needs more work. Its my starting point. + +Signed-off-by: Armin Kuster <akuster808@...> + +Index: lkrg-0.9.0/Makefile +=================================================================== +--- lkrg-0.9.0.orig/Makefile ++++ lkrg-0.9.0/Makefile +@@ -4,28 +4,10 @@ + # Author: + # - Adam 'pi3' Zabrocki (http://pi3.com.pl) + ## +- +-P_OUTPUT = output + P_PWD ?= $(shell pwd) +-P_KVER ?= $(shell uname -r) +-P_BOOTUP_SCRIPT ?= scripts/bootup/lkrg-bootup.sh +-TARGET := p_lkrg +-ifneq ($(KERNELRELEASE),) +- KERNEL := /lib/modules/$(KERNELRELEASE)/build +-else +- ## KERNELRELEASE not set. +- KERNEL := /lib/modules/$(P_KVER)/build +-endif +- +-# +-# Uncomment for debug compilation +-# +-# ccflags-m := -ggdb -DP_LKRG_DEBUG_BUILD -finstrument-functions +-# ccflags-y := ${ccflags-m} +-# p_lkrg-objs += src/modules/print_log/p_lkrg_debug_log.o + +-obj-m += $(TARGET).o +-$(TARGET)-objs += src/modules/ksyms/p_resolve_ksym.o \ ++obj-m := p_lkrg.o ++p_lkrg-y := src/modules/ksyms/p_resolve_ksym.o \ + src/modules/hashing/p_lkrg_fast_hash.o \ + src/modules/comm_channel/p_comm_channel.o \ + src/modules/integrity_timer/p_integrity_timer.o \ +@@ -91,23 +73,14 @@ $(TARGET)-objs += src/modules/ksyms/p_re + src/p_lkrg_main.o + + +-all: +-# $(MAKE) -C $(KERNEL) M=$(P_PWD) modules CONFIG_DEBUG_SECTION_MISMATCH=y +- $(MAKE) -C $(KERNEL) M=$(P_PWD) modules +- mkdir -p $(P_OUTPUT) +- cp $(P_PWD)/$(TARGET).ko $(P_OUTPUT) +- +-install: +- $(MAKE) -C $(KERNEL) M=$(P_PWD) modules_install +- depmod -a +- $(P_PWD)/$(P_BOOTUP_SCRIPT) install + +-uninstall: +- $(P_PWD)/$(P_BOOTUP_SCRIPT) uninstall ++modules: ++ $(MAKE) -C $(KERNEL_SRC) M=$(P_PWD) modules ++ ++modules_install: ++ $(MAKE) -C $(KERNEL_SRC) M=$(P_PWD) modules_install + + clean: +- $(MAKE) -C $(KERNEL) M=$(P_PWD) clean +- $(RM) Module.markers modules.order +- $(RM) $(P_PWD)/src/modules/kmod/client/kmod/Module.markers +- $(RM) $(P_PWD)/src/modules/kmod/client/kmod/modules.order +- $(RM) -rf $(P_OUTPUT) ++ rm -f *.o *~ core .depend .*.cmd *.ko *.mod.c ++ rm -f Module.markers Module.symvers modules.order ++ rm -rf .tmp_versions Modules.symvers diff --git a/recipes-kernel/lkrg/lkrg-module_0.9.0.bb b/recipes-kernel/lkrg/lkrg-module_0.9.0.bb new file mode 100644 index 0000000..dbc195d --- /dev/null +++ b/recipes-kernel/lkrg/lkrg-module_0.9.0.bb @@ -0,0 +1,33 @@ +SUMMARY = "Linux Kernel Runtime Guard" +DESCRIPTION="LKRG performs runtime integrity checking of the Linux \ +kernel and detection of security vulnerability exploits against the kernel." +SECTION = "security" +HOMEPAGE = "https://www.openwall.com/lkrg/" +LICENSE = "GPLv2" + +LIC_FILES_CHKSUM = "file://LICENSE;md5=d931f44a1f4be309bcdac742d7ed92f9" + +DEPENDS = "virtual/kernel elfutils" + +SRC_URI = "https://www.openwall.com/lkrg/lkrg-${PV}.tar.gz \ + file://makefile_cleanup.patch " + +SRC_URI[sha256sum] = "a997e4d98962c359f3af163bbcfa38a736d2a50bfe35c15065b74cb57f8742bf" + +S = "${WORKDIR}/lkrg-${PV}" + +inherit module kernel-module-split + +MAKE_TARGETS = "modules" + +MODULE_NAME = "p_lkrg" + +module_do_install() { + install -d ${D}${nonarch_base_libdir}/modules/${KERNEL_VERSION}/kernel/${MODULE_NAME} + install -m 0644 ${MODULE_NAME}.ko \ + ${D}${nonarch_base_libdir}/modules/${KERNEL_VERSION}/kernel/${MODULE_NAME}/${MODULE_NAME}.ko +} + +RPROVIDES_${PN} += "kernel-module-lkrg" + +COMPATIBLE_HOST = "(i.86|x86_64|arm|aarch64).*-linux" -- 2.25.1
|
|
[meta-security][PATCH 1/2] clamav: remove rest of mirror.dat ref
Signed-off-by: Armin Kuster <akuster808@...>
--- recipes-scanners/clamav/clamav_0.104.0.bb | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/recipes-scanners/clamav/clamav_0.104.0.bb b/recipes-scanners/clamav/clamav_0.104.0.bb index ba036b0..36e498d 100644 --- a/recipes-scanners/clamav/clamav_0.104.0.bb +++ b/recipes-scanners/clamav/clamav_0.104.0.bb @@ -31,7 +31,7 @@ inherit cmake chrpath pkgconfig useradd systemd multilib_header multilib_script CLAMAV_UID ?= "clamav" CLAMAV_GID ?= "clamav" -MULTILIB_SCRIPTS = "${PN}-dev:${bindir}/clamav-config ${PN}-cvd:${localstatedir}/lib/clamav/mirrors.dat" +MULTILIB_SCRIPTS = "${PN}-dev:${bindir}/clamav-config" EXTRA_OECMAKE = " -DCMAKE_BUILD_TYPE=Release -DOPTIMIZE=ON -DENABLE_JSON_SHARED=OFF \ -DCLAMAV_GROUP=${CLAMAV_GID} -DCLAMAV_USER=${CLAMAV_UID} \ @@ -85,7 +85,7 @@ pkg_postinst_ontarget_${PN} () { } -PACKAGES = "${PN} ${PN}-dev ${PN}-dbg ${PN}-daemon ${PN}-doc ${PN}-cvd \ +PACKAGES = "${PN} ${PN}-dev ${PN}-dbg ${PN}-daemon ${PN}-doc \ ${PN}-clamdscan ${PN}-freshclam ${PN}-libclamav ${PN}-staticdev" FILES_${PN} = "${bindir}/clambc ${bindir}/clamscan ${bindir}/clamsubmit ${sbindir}/clamonacc \ @@ -134,8 +134,6 @@ FILES_${PN}-doc = "${mandir}/man/* \ ${datadir}/man/* \ ${docdir}/* " -FILES_${PN}-cvd = "${localstatedir}/lib/clamav/*.cvd ${localstatedir}/lib/clamav/*.dat" - USERADD_PACKAGES = "${PN}" GROUPADD_PARAM_${PN} = "--system ${CLAMAV_UID}" USERADD_PARAM_${PN} = "--system -g ${CLAMAV_GID} --home-dir \ -- 2.25.1
|
|
Re: bitbake controlling memory use
On 2021-04-11 12:19 p.m., Alexander Kanavin wrote:
make already has -l option for limiting new instances if load average is too high, so it's only natural to add a RAM limiter too.During today's Yocto technical call (1), we talked about approaches to limiting the system load and avoiding swap and/or OOM events. Here's what (little!) i recall from the discussion, 9 busy hours later. In the short run, instead of independently maintaining changes to configurations to limit parallelism or xz memory usage, etc, we could develop an optional common include file where such limits are shared across the community. In the longer run, changes to how bitbake schedules work may be needed. Richard says that there was a make/build server idea and maybe even a patch from a while ago. It may be in one of his poky-contrib branches. I took a few minutes to look but nothing popped up. A set of keywords to search for might help me find it. Someone mentioned that while ninja has not been open to accepting any patches that would complicate and potentially slow down builds, there is a fork of ninja calls 'samurai' that does seem to be open to some improvements that we could benefit from. It was also suggested that there were existing defects in the YP BZ (2) but I didn't find any earlier and it's too late in my day to start looking now! If no one replies with a relevant BZ ID, I'll create one. I'm sure I missed some things that were mentioned but Trevor Woerner sometimes takes notes so I'll check on them once / if they are sent out. ../Randy 1) https://www.yoctoproject.org/public-virtual-meetings/ 2) https://bugzilla.yoctoproject.org/ Alex -- # Randy MacLeod # Wind River Linux
|
|
QA notification for completed autobuilder build (yocto-3.1.7.rc1)
Pokybuild User <pokybuild@...>
A build flagged for QA (yocto-3.1.7.rc1) was completed on the autobuilder and is available at:
https://autobuilder.yocto.io/pub/releases/yocto-3.1.7.rc1 Build hash information: bitbake: 017a39ed05d065bf28fd38f91bcde8a098300551 meta-arm: 1cf8b975e1c40bf8e8c0bf315db5d4cddcb01a7b meta-gplv2: 60b251c25ba87e946a0ca4cdc8d17b1cb09292ac meta-intel: 4bd62a7e154b8c9e8a114f452d3b062d8d058118 meta-kernel: 29329d7cacc71595cecfdd05a455a0cfb164564d meta-mingw: 524de686205b5d6736661d4532f5f98fee8589b7 oecore: a3de6239e98efafe3668396e69133ffee3d9b27f poky: 13f4ddf50eccaeed96a40a5f1a1d4173e677e98a This is an automated message from the Yocto Project Autobuilder Git: git://git.yoctoproject.org/yocto-autobuilder2 Email: richard.purdie@...
|
|
[PATCH yocto-autobuilder-helper 4/4] generate-testresult-index.py: publish host data collected by collect-data template
sakib.sajal@...
Add a column "Host Data" to publish the host data collected.
Signed-off-by: Sakib Sajal <sakib.sajal@...> Signed-off-by: Randy MacLeod <Randy.MacLeod@...> --- scripts/generate-testresult-index.py | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/scripts/generate-testresult-index.py b/scripts/generate-testresult-index.py index d9d577e..7fdc17c 100755 --- a/scripts/generate-testresult-index.py +++ b/scripts/generate-testresult-index.py @@ -33,6 +33,7 @@ index_templpate = """ <th>Performance Reports</th> <th>ptest Logs</th> <th>Buildhistory</th> + <th>Host Data</th> </tr> </thead> <tdata> @@ -57,6 +58,11 @@ index_templpate = """ <a href="{{bh[0]}}">{{bh[1]}}</a> {% endfor %} </td> + <td> + {% for hd in entry[8] %} + <a href="{{hd[0]}}">{{hd[1]}}</a> + {% endfor %} + </td> </tr> {% endfor %} </tdata> @@ -145,9 +151,19 @@ for build in sorted(os.listdir(path), key=keygen, reverse=True): if os.path.exists(buildpath + "/qemuarm/buildhistory.txt"): buildhistory.append((reldir + "testresults/qemuarm/buildhistory.txt", "qemuarm")) + hd = [] + counter = 0 + # do we really need the loop? + for p in glob.glob(buildpath + "/*/*/host_stats*top.txt"): + n_split = p.split(build) + res = reldir[0:-1] + n_split[1] + hd.append((res, str(counter))) + counter += 1 + + branch = get_build_branch(buildpath) - entries.append((build, reldir, btype, testreport, branch, buildhistory, perfreports, ptestlogs)) + entries.append((build, reldir, btype, testreport, branch, buildhistory, perfreports, ptestlogs, hd)) # Also ensure we have saved out log data for ptest runs to aid debugging if "ptest" in btype or btype in ["full", "quick"]: -- 2.25.1
|
|
[PATCH yocto-autobuilder-helper 3/4] collect-results: collect "host_stats" files generated by collect-data template
sakib.sajal@...
collect-data template generates host_stats files which are collected.
All files are published, file names are determined by the contents: - Files that contain "top" output are named host_stats_<number>_top.txt - host_stats_<number>.txt otherwise Signed-off-by: Sakib Sajal <sakib.sajal@...> Signed-off-by: Randy MacLeod <Randy.MacLeod@...> --- scripts/collect-results | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/scripts/collect-results b/scripts/collect-results index 5db43fb..7474e36 100755 --- a/scripts/collect-results +++ b/scripts/collect-results @@ -17,3 +17,22 @@ if [ -e $WORKDIR/buildhistory ]; then $WORKDIR/../scripts/buildhistory-diff -p $WORKDIR/buildhistory ab-fetchrev > $DEST/$target/buildhistory.txt fi fi + +HSFILE=$WORKDIR/tmp/buildstats/*/host_stats +d=`date +%Y-%m-%d--%H-%M` + +mkdir -p $DEST/$target/$d + +step=0 +for f in $HSFILE; do + if [ -e $f ]; then + cp $f $DEST/$target/$d + grep -m 1 "^top -" $f + if [ $? -eq 0 ]; then + mv $DEST/$target/$d/`basename $f` $DEST/$target/$d/`basename $f`_${step}_top.txt + else + mv $DEST/$target/$d/`basename $f` $DEST/$target/$d/`basename $f`_${step}.txt + fi + step=$((step+1)) + fi +done -- 2.25.1
|
|
[PATCH yocto-autobuilder-helper 2/4] config.json: collect data by default
sakib.sajal@...
add the variables required to collect data to "defaults"
so that data is collected on all builds. Signed-off-by: Sakib Sajal <sakib.sajal@...> Signed-off-by: Randy MacLeod <Randy.MacLeod@...> --- config.json | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/config.json b/config.json index c43d231..cd82047 100644 --- a/config.json +++ b/config.json @@ -55,7 +55,10 @@ "SDK_INCLUDE_TOOLCHAIN = '1'", "BB_DISKMON_DIRS = 'STOPTASKS,${TMPDIR},1G,100K STOPTASKS,${DL_DIR},1G STOPTASKS,${SSTATE_DIR},1G STOPTASKS,/tmp,100M,100K ABORT,${TMPDIR},100M,1K ABORT,${DL_DIR},100M ABORT,${SSTATE_DIR},100M ABORT,/tmp,10M,1K'", "BB_HASHSERVE = 'typhoon.yocto.io:8686'", - "RUNQEMU_TMPFS_DIR = '/home/pokybuild/tmp'" + "RUNQEMU_TMPFS_DIR = '/home/pokybuild/tmp'", + "BB_HEARTBEAT_EVENT = '10'", + "BB_LOG_HOST_STAT_ON_INTERVAL = '1'", + "BB_LOG_HOST_STAT_CMDS = 'oe-time-dd-test.sh 100'" ] }, "templates" : { -- 2.25.1
|
|
[PATCH yocto-autobuilder-helper 1/4] config.json: add "collect-data" template
sakib.sajal@...
collect-data template can run arbitrary commands/scripts
on a regular basis and logs the output in a file. See oe-core for more details: edb7098e9e buildstats.bbclass: add functionality to collect build system stats Signed-off-by: Sakib Sajal <sakib.sajal@...> Signed-off-by: Randy MacLeod <Randy.MacLeod@...> --- config.json | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/config.json b/config.json index 5bfa240..c43d231 100644 --- a/config.json +++ b/config.json @@ -87,6 +87,13 @@ "SANITYTARGETS" : "core-image-full-cmdline:do_testimage core-image-sato:do_testimage core-image-sato-sdk:do_testimage" } }, + "collect-data" : { + "extravars" : [ + "BB_HEARTBEAT_EVENT = '10'", + "BB_LOG_HOST_STAT_ON_INTERVAL = '1'", + "BB_LOG_HOST_STAT_CMDS = 'oe-time-dd-test.sh 100'" + ] + }, "ptest-qemu" : { "BUILDINFO" : true, "BBTARGETS" : "core-image-sato-ptest", -- 2.25.1
|
|
Re: ref-manual: reverse the order of migration guides?
Michael Opdenacker
Oops, sent to the wrong list (meant to use the "docs" list). You can
remove if this list is moderated. Apologies -- Michael Opdenacker, Bootlin Embedded Linux and Kernel engineering https://bootlin.com
|
|
ref-manual: reverse the order of migration guides?
Michael Opdenacker
Greetings,
Wouldn't it make sense to reverse the order of migration guides in the reference manual (https://www.yoctoproject.org/docs/3.0/ref-manual/ref-manual.html#migration)? I guess it would be easier to start mentioning the migration path from the most recent release, as version 1.3 looks ancient. Would it make sense? If so, it's easy to propose a patch... Thanks in advance, Michael. -- Michael Opdenacker, Bootlin Embedded Linux and Kernel engineering https://bootlin.com
|
|
Re: [meta-cgl][PATCH] pacemaker: upgrade 2.0.3 -> 2.0.5
On 2021-04-12 11:00 p.m., Jeremy Puhlman wrote:
I haven't been doing much with it lately and this got lost in my pile. Its merged to master.Thanks Jeremy. ../Randy On Mon, Apr 12, 2021 at 7:29 PM Randy MacLeod <randy.macleod@... <mailto:randy.macleod@...>> wrote: -- # Randy MacLeod # Wind River Linux
|
|
Re: need Sysvinit as system manager in Rocko Version
#rocko
rohit jadhav
Hi Khem Raj, Thanks you for your valuable feedback. I have tried with your suggestions. but observed with following error: ERROR: /home/tel/imx_yocto_bsp/sources/meta-fsl-bsp-release/imx/meta-sdk/recipes-fsl/packagegroup/packagegroup-qt5-webengine.bb: Please ensure that your setting of VIRTUAL-RUNTIME_init_manager (systemd) matches the entries enabled in DISTRO_FEATURES ERROR: /home/tel/imx_yocto_bsp/sources/meta-fsl-bsp-release/imx/meta-sdk/recipes-fsl/packagegroup/packagegroup-qt5-demos.bb: Please ensure that your setting of VIRTUAL-RUNTIME_init_manager (systemd) matches the entries enabled in DISTRO_FEATURES ERROR: /home/tel/imx_yocto_bsp/sources/meta-fsl-bsp-release/imx/meta-sdk/recipes-fsl/packagegroup/packagegroup-imx-erpc.bb: Please ensure that your setting of VIRTUAL-RUNTIME_init_manager (systemd) matches the entries enabled in DISTRO_FEATURES ERROR: /home/tel/imx_yocto_bsp/sources/meta-fsl-bsp-release/imx/meta-sdk/recipes-fsl/packagegroup/packagegroup-fsl-tools-gpu-external.bb: Please ensure that your setting of VIRTUAL-RUNTIME_init_manager (systemd) matches the entries enabled in DISTRO_FEATURES ERROR: Failed to parse recipe: /home/tel/imx_yocto_bsp/sources/meta-fsl-bsp-release/imx/meta-sdk/recipes-fsl/packagegroup/packagegroup-imx-erpc.bb ERROR: /home/tel/imx_yocto_bsp/sources/meta-fsl-bsp-release/imx/meta-sdk/recipes-fsl/packagegroup/packagegroup-fsl-optee-imx.bb: Please ensure that your setting of VIRTUAL-RUNTIME_init_manager (systemd) matches the entries enabled in DISTRO_FEATURES ERROR: /home/tel/imx_yocto_bsp/sources/meta-fsl-bsp-release/imx/meta-sdk/recipes-fsl/packagegroup/packagegroup-fsl-pulseaudio.bb: Please ensure that your setting of VIRTUAL-RUNTIME_init_manager (systemd) matches the entries enabled in DISTRO_FEATURES ERROR: /home/tel/imx_yocto_bsp/sources/meta-fsl-bsp-release/imx/meta-sdk/recipes-fsl/packagegroup/packagegroup-fsl-tools-audio.bb: Please ensure that your setting of VIRTUAL-RUNTIME_init_manager (systemd) matches the entries enabled in DISTRO_FEATURES Thanks and regards Rohit J
On Tue, Apr 13, 2021 at 8:58 PM Khem Raj <raj.khem@...> wrote:
|
|
[meta-rockchip][PATCH 5/6] WIP nanopi-m4: declare OP-TEE presence in devicetree
Yann Dirson
From: Yann Dirson <yann@...>
FIXME: - this is not specific to the board, and would indeed apply to any SoC supported by OP-TEE. - should rather be selected by "optee" in DISTRO_FEATURES, maybe using a dts overlay --- .../0001-nanopi-declare-optee-presence.patch | 30 +++++++++++++++++++ recipes-kernel/linux/linux-yocto%.bbappend | 1 + 2 files changed, 31 insertions(+) create mode 100644 recipes-kernel/linux/files/0001-nanopi-declare-optee-= presence.patch diff --git a/recipes-kernel/linux/files/0001-nanopi-declare-optee-presenc= e.patch b/recipes-kernel/linux/files/0001-nanopi-declare-optee-presence.p= atch new file mode 100644 index 0000000..aede781 --- /dev/null +++ b/recipes-kernel/linux/files/0001-nanopi-declare-optee-presence.patch @@ -0,0 +1,30 @@ +From 30cb714e717990276a5fabc50dc616c83b223ee7 Mon Sep 17 00:00:00 2001 +From: Yann Dirson <yann@...> +Date: Mon, 12 Apr 2021 15:50:26 +0200 +Subject: [PATCH] nanopi: declare optee presence + +--- + arch/arm64/boot/dts/rockchip/rk3399-nanopi-m4.dts | 7 +++++++ + 1 file changed, 7 insertions(+) + +diff --git a/arch/arm64/boot/dts/rockchip/rk3399-nanopi-m4.dts b/arch/ar= m64/boot/dts/rockchip/rk3399-nanopi-m4.dts +index 60358ab8c7df..ef11639b03f6 100644 +--- a/arch/arm64/boot/dts/rockchip/rk3399-nanopi-m4.dts ++++ b/arch/arm64/boot/dts/rockchip/rk3399-nanopi-m4.dts +@@ -16,6 +16,13 @@ / { + model =3D "FriendlyElec NanoPi M4"; + compatible =3D "friendlyarm,nanopi-m4", "rockchip,rk3399"; +=20 ++ firmware { ++ optee { ++ compatible =3D "linaro,optee-tz"; ++ method =3D "smc"; ++ }; ++ }; ++ + vdd_5v: vdd-5v { + compatible =3D "regulator-fixed"; + regulator-name =3D "vdd_5v"; +--=20 +2.30.2 + diff --git a/recipes-kernel/linux/linux-yocto%.bbappend b/recipes-kernel/= linux/linux-yocto%.bbappend index 9658681..97b3238 100644 --- a/recipes-kernel/linux/linux-yocto%.bbappend +++ b/recipes-kernel/linux/linux-yocto%.bbappend @@ -2,6 +2,7 @@ FILESEXTRAPATHS_prepend :=3D "${THISDIR}/files:" =20 SRC_URI_append =3D "\ file://bsp;type=3Dkmeta;subdir=3Dkernel-meta \ + file://0001-nanopi-declare-optee-presence.patch \ " =20 COMPATIBLE_MACHINE_marsboard-rk3066 =3D "marsboard-rk3066" --=20 2.30.2
|
|
[meta-rockchip][PATCH 6/6] WIP kernel config feature for OP-TEE activation
Yann Dirson
From: Yann Dirson <yann@...>
FIXME: - provide an .scc with proper information - maybe bundle with dts overlay - select a more suitable path in config namespace --- recipes-kernel/linux/files/bsp/tee.cfg | 2 ++ 1 file changed, 2 insertions(+) create mode 100644 recipes-kernel/linux/files/bsp/tee.cfg diff --git a/recipes-kernel/linux/files/bsp/tee.cfg b/recipes-kernel/linu= x/files/bsp/tee.cfg new file mode 100644 index 0000000..82213a5 --- /dev/null +++ b/recipes-kernel/linux/files/bsp/tee.cfg @@ -0,0 +1,2 @@ +CONFIG_TEE=3Dm +CONFIG_OPTEE=3Dm --=20 2.30.2
|
|
[meta-rockchip][PATCH 4/6] WIP optee-os: rk3399 support
Yann Dirson
From: Yann Dirson <yann@...>
This is the current state of working patches being discussed in https://github.com/OP-TEE/optee_os/issues/4542 --- conf/machine/include/rk3399.inc | 2 + ...399-enable-serial-console-by-default.patch | 46 +++++++++++++++++++ .../optee/files/rk3399-boot-fix.patch | 13 ++++++ recipes-security/optee/optee%.bbappend | 2 + recipes-security/optee/optee-os_%.bbappend | 9 ++++ 5 files changed, 72 insertions(+) create mode 100644 recipes-security/optee/files/0001-rk3399-enable-seria= l-console-by-default.patch create mode 100644 recipes-security/optee/files/rk3399-boot-fix.patch create mode 100644 recipes-security/optee/optee-os_%.bbappend diff --git a/conf/machine/include/rk3399.inc b/conf/machine/include/rk339= 9.inc index f6b7826..9ac434e 100644 --- a/conf/machine/include/rk3399.inc +++ b/conf/machine/include/rk3399.inc @@ -13,6 +13,8 @@ KBUILD_DEFCONFIG ?=3D "defconfig" KERNEL_CLASSES =3D "kernel-fitimage" KERNEL_IMAGETYPE =3D "fitImage" =20 +OPTEEMACHINE =3D "rockchip-rk3399" + TFA_PLATFORM =3D "rk3399" TFA_BUILD_TARGET =3D "bl31" =20 diff --git a/recipes-security/optee/files/0001-rk3399-enable-serial-conso= le-by-default.patch b/recipes-security/optee/files/0001-rk3399-enable-ser= ial-console-by-default.patch new file mode 100644 index 0000000..31daef7 --- /dev/null +++ b/recipes-security/optee/files/0001-rk3399-enable-serial-console-by-d= efault.patch @@ -0,0 +1,46 @@ +From 0e2cbe08532a1344aab62f21b032ce6171e50f49 Mon Sep 17 00:00:00 2001 +From: Yann Dirson <yann@...> +Date: Mon, 12 Apr 2021 10:49:18 +0200 +Subject: [PATCH] rk3399: enable serial console by default +Upstream-Status: Submitted [https://github.com/OP-TEE/optee_os/pull/4551= ] + +Signed-off-by: Yann Dirson <yann@...> +--- + core/arch/arm/plat-rockchip/conf.mk | 6 ++++++ + 1 file changed, 6 insertions(+) + +Index: git/core/arch/arm/plat-rockchip/conf.mk +=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D +--- git.orig/core/arch/arm/plat-rockchip/conf.mk ++++ git/core/arch/arm/plat-rockchip/conf.mk +@@ -26,8 +26,6 @@ CFG_EARLY_CONSOLE_BAUDRATE ?=3D 1500000 + CFG_EARLY_CONSOLE_CLK_IN_HZ ?=3D 24000000 + endif +=20 +-CFG_EARLY_CONSOLE ?=3D n +- + ifeq ($(PLATFORM_FLAVOR),rk3399) + include core/arch/arm/cpu/cortex-armv8-0.mk + $(call force,CFG_TEE_CORE_NB_CORE,6) +@@ -37,6 +35,12 @@ CFG_TZDRAM_START ?=3D 0x30000000 + CFG_TZDRAM_SIZE ?=3D 0x02000000 + CFG_SHMEM_START ?=3D 0x32000000 + CFG_SHMEM_SIZE ?=3D 0x00400000 ++ ++CFG_EARLY_CONSOLE ?=3D y ++CFG_EARLY_CONSOLE_BASE ?=3D UART2_BASE ++CFG_EARLY_CONSOLE_SIZE ?=3D UART2_SIZE ++CFG_EARLY_CONSOLE_BAUDRATE ?=3D 1500000 ++CFG_EARLY_CONSOLE_CLK_IN_HZ ?=3D 24000000 + endif +=20 + ifeq ($(PLATFORM_FLAVOR),px30) +@@ -47,6 +51,8 @@ CFG_TZDRAM_START ?=3D 0x30000000 + CFG_TZDRAM_SIZE ?=3D 0x02000000 + CFG_SHMEM_START ?=3D 0x32000000 + CFG_SHMEM_SIZE ?=3D 0x00400000 ++ ++CFG_EARLY_CONSOLE ?=3D n + endif +=20 + ifeq ($(platform-flavor-armv8),1) diff --git a/recipes-security/optee/files/rk3399-boot-fix.patch b/recipes= -security/optee/files/rk3399-boot-fix.patch new file mode 100644 index 0000000..d346157 --- /dev/null +++ b/recipes-security/optee/files/rk3399-boot-fix.patch @@ -0,0 +1,13 @@ +Index: git/core/arch/arm/kernel/entry_a64.S +=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D +--- git.orig/core/arch/arm/kernel/entry_a64.S ++++ git/core/arch/arm/kernel/entry_a64.S +@@ -219,7 +219,7 @@ clear_nex_bss: + adr_l x0, __text_start + ldr x1, cached_mem_end + sub x1, x1, x0 +- bl dcache_cleaninv_range ++/* bl dcache_cleaninv_range*/ +=20 +=20 + /* diff --git a/recipes-security/optee/optee%.bbappend b/recipes-security/op= tee/optee%.bbappend index 2a8722a..ec11863 100644 --- a/recipes-security/optee/optee%.bbappend +++ b/recipes-security/optee/optee%.bbappend @@ -1,2 +1,4 @@ +COMPATIBLE_MACHINE_rk3399 ?=3D "rk3399" + inherit features_check REQUIRED_DISTRO_FEATURES =3D "optee" diff --git a/recipes-security/optee/optee-os_%.bbappend b/recipes-securit= y/optee/optee-os_%.bbappend new file mode 100644 index 0000000..eceb694 --- /dev/null +++ b/recipes-security/optee/optee-os_%.bbappend @@ -0,0 +1,9 @@ +EXTRA_OEMAKE_append_rk3399 =3D " \ + CFG_CORE_ASLR=3Dn \ +" + +FILESEXTRAPATHS_prepend :=3D "${THISDIR}/files:" +SRC_URI +=3D "\ + file://rk3399-boot-fix.patch \ + file://0001-rk3399-enable-serial-console-by-default.patch \ +" --=20 2.30.2
|
|
[meta-rockchip][PATCH 1/6] optee: condition for "optee" DISTRO_FEATURE
Yann Dirson
From: Yann Dirson <yann@...>
This effectively sets up a single switch to activate OP-TEE support. Disabling optee-* recipes when the feature is not set is not the primary goal, though it can occasionally be handy to catch dependencies pulling them without using the new DISTRO_FEATURE, which provides a safeguard to ensure downstream recipes in need of upgrade will fail early. The main value for this flag is for dependent recipes to know when to activate the OP-TEE support, rather than having to control each of them separately: - u-boot - trusted-firmware-a - kernel Signed-off-by: Yann Dirson <yann@...> --- recipes-security/optee/optee%.bbappend | 2 ++ 1 file changed, 2 insertions(+) create mode 100644 recipes-security/optee/optee%.bbappend diff --git a/recipes-security/optee/optee%.bbappend b/recipes-security/op= tee/optee%.bbappend new file mode 100644 index 0000000..2a8722a --- /dev/null +++ b/recipes-security/optee/optee%.bbappend @@ -0,0 +1,2 @@ +inherit features_check +REQUIRED_DISTRO_FEATURES =3D "optee" --=20 2.30.2
|
|
[meta-rockchip][PATCH 0/6] WIP/RFC OP-TEE support for ARM and rk3399
Yann Dirson
From: Yann Dirson <yann@...>
This tries to provide a generic framework for easier OP-TEE support in BSP layers. It would probably make sense to have the generic parts in meta-arm when they are finalized. Today the kernel/dts handling is still not properly done, and patches to fix rk3399 support in OP-TEE have not yet been merged upstream, and I'm mostly posting this to gather comments on the whole idea. Yann Dirson (6): optee: condition for "optee" DISTRO_FEATURE truster-firmware-a: include optee support when requested by DISTRO_FEATURE u-boot: include optee-os as BL32 when requested by DISTRO_FEATURE WIP optee-os: rk3399 support WIP nanopi-m4: declare OP-TEE presence in devicetree WIP kernel config feature for OP-TEE activation conf/machine/include/rk3399.inc | 2 + .../trusted-firmware-a_%.bbappend | 19 ++++++++ recipes-bsp/u-boot/u-boot%.bbappend | 14 ++++++ .../0001-nanopi-declare-optee-presence.patch | 30 ++++++++++++ recipes-kernel/linux/files/bsp/tee.cfg | 2 + recipes-kernel/linux/linux-yocto%.bbappend | 1 + ...399-enable-serial-console-by-default.patch | 46 +++++++++++++++++++ .../optee/files/rk3399-boot-fix.patch | 13 ++++++ recipes-security/optee/optee%.bbappend | 4 ++ recipes-security/optee/optee-os_%.bbappend | 9 ++++ 10 files changed, 140 insertions(+) create mode 100644 recipes-kernel/linux/files/0001-nanopi-declare-optee-= presence.patch create mode 100644 recipes-kernel/linux/files/bsp/tee.cfg create mode 100644 recipes-security/optee/files/0001-rk3399-enable-seria= l-console-by-default.patch create mode 100644 recipes-security/optee/files/rk3399-boot-fix.patch create mode 100644 recipes-security/optee/optee%.bbappend create mode 100644 recipes-security/optee/optee-os_%.bbappend --=20 2.30.2
|
|