mirror of
https://git.yoctoproject.org/meta-arm
synced 2026-07-19 16:57:09 +00:00
Compare commits
13 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 950a4afce4 | |||
| ea21deb5e9 | |||
| 1947c00029 | |||
| 313ad2a0e6 | |||
| 38bce82e42 | |||
| ecece16871 | |||
| aa85142b5b | |||
| 54fa370dde | |||
| 79c41bb917 | |||
| 1b85bbb4ca | |||
| 58268ddccb | |||
| 29799b787d | |||
| a88dd94883 |
@@ -1,79 +0,0 @@
|
||||
From 42358d889ed652a8c386862f8c65e5fbe7484de2 Mon Sep 17 00:00:00 2001
|
||||
From: Ross Burton <ross.burton@arm.com>
|
||||
Date: Fri, 26 Apr 2024 10:38:28 +0000
|
||||
Subject: [PATCH] procps: fix build with new glibc but old kernel headers
|
||||
|
||||
If you're building procps with a newer glibc (with pidfd_open()) but
|
||||
older kernel headers (say 4.x, before __NR_pidfd_open) then procps will
|
||||
fail to build because of a typo in configure.ac.
|
||||
|
||||
Signed-off-by: Ross Burton <ross.burton@arm.com>
|
||||
---
|
||||
.../procps/procps/pidfd.patch | 42 +++++++++++++++++++
|
||||
meta/recipes-extended/procps/procps_4.0.4.bb | 1 +
|
||||
2 files changed, 43 insertions(+)
|
||||
create mode 100644 meta/recipes-extended/procps/procps/pidfd.patch
|
||||
|
||||
diff --git a/meta/recipes-extended/procps/procps/pidfd.patch b/meta/recipes-extended/procps/procps/pidfd.patch
|
||||
new file mode 100644
|
||||
index 00000000000..f5e8183e547
|
||||
--- /dev/null
|
||||
+++ b/meta/recipes-extended/procps/procps/pidfd.patch
|
||||
@@ -0,0 +1,42 @@
|
||||
+From c8f625e085b8249cc009e8b19c3a19100217eb35 Mon Sep 17 00:00:00 2001
|
||||
+From: Ross Burton <ross.burton@arm.com>
|
||||
+Date: Thu, 25 Apr 2024 13:33:15 +0000
|
||||
+Subject: [PATCH] Fix pidfd_open detection
|
||||
+
|
||||
+This check for pidfd_open uses AC_CHECK_FUNC which just runs the specified code, but
|
||||
+src/pgrep.c checks HAVE_PIDFD_OPEN which will only be defined by AC_CHECK_FUNCS.
|
||||
+
|
||||
+Also pidfd_open is defined in sys/pidfd.h so that needs including.
|
||||
+
|
||||
+Upstream-Status: Pending
|
||||
+Signed-off-by: Ross Burton <ross.burton@arm.com>
|
||||
+---
|
||||
+
|
||||
+diff --git a/configure.ac b/configure.ac
|
||||
+index fec27e3f..024731c7 100644
|
||||
+--- a/configure.ac
|
||||
++++ b/configure.ac
|
||||
+@@ -170,7 +170,7 @@ AC_TRY_COMPILE([#include <errno.h>],
|
||||
+ AC_MSG_RESULT(yes),
|
||||
+ AC_MSG_RESULT(no))
|
||||
+
|
||||
+-AC_CHECK_FUNC([pidfd_open], [enable_pidwait=yes], [
|
||||
++AC_CHECK_FUNCS([pidfd_open], [enable_pidwait=yes], [
|
||||
+ AC_MSG_CHECKING([for __NR_pidfd_open])
|
||||
+ AC_COMPILE_IFELSE([AC_LANG_SOURCE([
|
||||
+ #include <sys/syscall.h>
|
||||
+diff --git a/src/pgrep.c b/src/pgrep.c
|
||||
+index d8e57dff..c5211aec 100644
|
||||
+--- a/src/pgrep.c
|
||||
++++ b/src/pgrep.c
|
||||
+@@ -44,7 +44,9 @@
|
||||
+
|
||||
+ #ifdef ENABLE_PIDWAIT
|
||||
+ #include <sys/epoll.h>
|
||||
+-#ifndef HAVE_PIDFD_OPEN
|
||||
++#ifdef HAVE_PIDFD_OPEN
|
||||
++#include <sys/pidfd.h>
|
||||
++#else
|
||||
+ #include <sys/syscall.h>
|
||||
+ #endif /* !HAVE_PIDFD_OPEN */
|
||||
+ #endif
|
||||
diff --git a/meta/recipes-extended/procps/procps_4.0.4.bb b/meta/recipes-extended/procps/procps_4.0.4.bb
|
||||
index 800384f22f7..ec8c4b0261b 100644
|
||||
--- a/meta/recipes-extended/procps/procps_4.0.4.bb
|
||||
+++ b/meta/recipes-extended/procps/procps_4.0.4.bb
|
||||
@@ -14,6 +14,7 @@ inherit autotools gettext pkgconfig update-alternatives
|
||||
|
||||
SRC_URI = "git://gitlab.com/procps-ng/procps.git;protocol=https;branch=master \
|
||||
file://sysctl.conf \
|
||||
+ file://pidfd.patch \
|
||||
"
|
||||
SRCREV = "4ddcef2fd843170c8e2d59a83042978f41037a2b"
|
||||
|
||||
--
|
||||
2.34.1
|
||||
|
||||
@@ -16,3 +16,4 @@ target:
|
||||
- arm-systemready-ir-acs
|
||||
- arm-systemready-linux-distros-debian
|
||||
- arm-systemready-linux-distros-opensuse
|
||||
- arm-systemready-linux-distros-fedora
|
||||
|
||||
@@ -21,10 +21,6 @@ repos:
|
||||
layers:
|
||||
meta:
|
||||
meta-poky:
|
||||
patches:
|
||||
procps:
|
||||
path: 0001-procps-fix-build-with-new-glibc-but-old-kernel-heade.patch
|
||||
repo: meta-arm
|
||||
|
||||
env:
|
||||
BB_LOGCONFIG: ""
|
||||
|
||||
@@ -0,0 +1,8 @@
|
||||
header:
|
||||
version: 16
|
||||
includes:
|
||||
- kas/arm-systemready-firmware.yml
|
||||
- kas/arm-systemready-linux-distros-unattended-installation.yml
|
||||
|
||||
target:
|
||||
- arm-systemready-linux-distros-fedora
|
||||
@@ -0,0 +1,11 @@
|
||||
header:
|
||||
version: 16
|
||||
|
||||
env:
|
||||
DISTRO_UNATTENDED_INST_TESTS:
|
||||
# The full testimage run typically takes around 12-24h on fvp-base.
|
||||
TEST_OVERALL_TIMEOUT: "${@ 24*60*60}"
|
||||
|
||||
local_conf_header:
|
||||
systemready-unattended-inst: |
|
||||
TESTIMAGE_AUTO = "${@oe.utils.vartrue("DISTRO_UNATTENDED_INST_TESTS", "1", "", d)}"
|
||||
@@ -0,0 +1,6 @@
|
||||
header:
|
||||
version: 14
|
||||
|
||||
local_conf_header:
|
||||
extsys: |
|
||||
MACHINE_FEATURES += "corstone1000-extsys"
|
||||
+1
-1
@@ -14,7 +14,7 @@ machine: fvp-base
|
||||
|
||||
defaults:
|
||||
repos:
|
||||
refspec: master
|
||||
refspec: scarthgap
|
||||
|
||||
repos:
|
||||
meta-arm:
|
||||
|
||||
@@ -180,6 +180,12 @@ then run:
|
||||
|
||||
kas build meta-arm/kas/corstone1000-fvp.yml:meta-arm/ci/debug.yml
|
||||
|
||||
By default, the external system is disabled. To build the Corstone-1000 image with external system enabled, run:
|
||||
|
||||
::
|
||||
|
||||
kas build meta-arm/kas/corstone1000-<fvp,mps3>.yml:meta-arm/ci/debug.yml:meta-arm/kas/corstone1000-extsys.yml
|
||||
|
||||
The initial clean build will be lengthy, given that all host utilities are to
|
||||
be built as well as the target images. This includes host executables (python,
|
||||
cmake, etc.) and the required toolchain(s).
|
||||
@@ -1444,6 +1450,7 @@ The above commands will delete the Platform key (PK) and allow the normal system
|
||||
|
||||
Testing the External System
|
||||
---------------------------
|
||||
Before testing the external system, please make sure to build the Corstone-1000 image with external system enabled as mentioned in section `Building the software stack`_.
|
||||
|
||||
During Linux boot the remoteproc subsystem automatically starts
|
||||
the external system.
|
||||
|
||||
+88
@@ -0,0 +1,88 @@
|
||||
From 4d3ebb03b89b122af490824ca73287954a35bd07 Mon Sep 17 00:00:00 2001
|
||||
From: Jamie Fox <jamie.fox@arm.com>
|
||||
Date: Thu, 22 Aug 2024 16:54:45 +0100
|
||||
Subject: [PATCH] Platform: corstone1000: Fix isolation L2 memory protection
|
||||
|
||||
The whole of the SRAM was configured unprivileged on this platform, so
|
||||
the memory protection required for isolation level 2 was not present.
|
||||
|
||||
This patch changes the S_DATA_START to S_DATA_LIMIT MPU region to be
|
||||
configured for privileged access only. It also reorders the MPU regions
|
||||
so that the App RoT sub-region overlapping S_DATA has a higher region
|
||||
number and so takes priority in the operation of the Armv6-M MPU.
|
||||
|
||||
Signed-off-by: Jamie Fox <jamie.fox@arm.com>
|
||||
Upstream-Status: Submitted [https://review.trustedfirmware.org/c/TF-M/trusted-firmware-m/+/30951]
|
||||
---
|
||||
.../arm/corstone1000/tfm_hal_isolation.c | 43 +++++++++----------
|
||||
1 file changed, 21 insertions(+), 22 deletions(-)
|
||||
|
||||
diff --git a/platform/ext/target/arm/corstone1000/tfm_hal_isolation.c b/platform/ext/target/arm/corstone1000/tfm_hal_isolation.c
|
||||
index 39b19c535..498f14ed2 100644
|
||||
--- a/platform/ext/target/arm/corstone1000/tfm_hal_isolation.c
|
||||
+++ b/platform/ext/target/arm/corstone1000/tfm_hal_isolation.c
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
- * Copyright (c) 2020-2023, Arm Limited. All rights reserved.
|
||||
+ * Copyright (c) 2020-2024, Arm Limited. All rights reserved.
|
||||
* Copyright (c) 2022 Cypress Semiconductor Corporation (an Infineon
|
||||
* company) or an affiliate of Cypress Semiconductor Corporation. All rights
|
||||
* reserved.
|
||||
@@ -99,6 +99,26 @@ enum tfm_hal_status_t tfm_hal_set_up_static_boundaries(
|
||||
return ret;
|
||||
}
|
||||
|
||||
+ /* Set the RAM attributes. It is needed because the first region overlaps the whole
|
||||
+ * SRAM and it has to be overridden.
|
||||
+ * The RAM_MPU_REGION_BLOCK_1_SIZE and RAM_MPU_REGION_BLOCK_2_SIZE are calculated manually
|
||||
+ * and added to the platform_region_defs compile definitions.
|
||||
+ */
|
||||
+ base = S_DATA_START;
|
||||
+ limit = S_DATA_START + RAM_MPU_REGION_BLOCK_1_SIZE;
|
||||
+ ret = configure_mpu(rnr++, base, limit,
|
||||
+ XN_EXEC_NOT_OK, AP_RW_PRIV_ONLY);
|
||||
+ if (ret != TFM_HAL_SUCCESS) {
|
||||
+ return ret;
|
||||
+ }
|
||||
+
|
||||
+ base = S_DATA_START + RAM_MPU_REGION_BLOCK_1_SIZE;
|
||||
+ limit = S_DATA_START + RAM_MPU_REGION_BLOCK_1_SIZE + RAM_MPU_REGION_BLOCK_2_SIZE;
|
||||
+ ret = configure_mpu(rnr++, base, limit,
|
||||
+ XN_EXEC_NOT_OK, AP_RW_PRIV_ONLY);
|
||||
+ if (ret != TFM_HAL_SUCCESS) {
|
||||
+ return ret;
|
||||
+ }
|
||||
|
||||
/* RW, ZI and stack as one region */
|
||||
base = (uint32_t)®ION_NAME(Image$$, TFM_APP_RW_STACK_START, $$Base);
|
||||
@@ -133,27 +153,6 @@ enum tfm_hal_status_t tfm_hal_set_up_static_boundaries(
|
||||
|
||||
#endif
|
||||
|
||||
- /* Set the RAM attributes. It is needed because the first region overlaps the whole
|
||||
- * SRAM and it has to be overridden.
|
||||
- * The RAM_MPU_REGION_BLOCK_1_SIZE and RAM_MPU_REGION_BLOCK_2_SIZE are calculated manually
|
||||
- * and added to the platform_region_defs compile definitions.
|
||||
- */
|
||||
- base = S_DATA_START;
|
||||
- limit = S_DATA_START + RAM_MPU_REGION_BLOCK_1_SIZE;
|
||||
- ret = configure_mpu(rnr++, base, limit,
|
||||
- XN_EXEC_NOT_OK, AP_RW_PRIV_UNPRIV);
|
||||
- if (ret != TFM_HAL_SUCCESS) {
|
||||
- return ret;
|
||||
- }
|
||||
-
|
||||
- base = S_DATA_START + RAM_MPU_REGION_BLOCK_1_SIZE;
|
||||
- limit = S_DATA_START + RAM_MPU_REGION_BLOCK_1_SIZE + RAM_MPU_REGION_BLOCK_2_SIZE;
|
||||
- ret = configure_mpu(rnr++, base, limit,
|
||||
- XN_EXEC_NOT_OK, AP_RW_PRIV_UNPRIV);
|
||||
- if (ret != TFM_HAL_SUCCESS) {
|
||||
- return ret;
|
||||
- }
|
||||
-
|
||||
arm_mpu_enable();
|
||||
|
||||
#endif /* CONFIG_TFM_ENABLE_MEMORY_PROTECT */
|
||||
--
|
||||
2.25.1
|
||||
|
||||
@@ -29,6 +29,7 @@ SRC_URI:append:corstone1000 = " \
|
||||
file://0010-CC312-alignment-of-cc312-differences-between-fvp-and.patch \
|
||||
file://0011-Platform-corstone1000-Increase-buffers-for-EFI-vars.patch \
|
||||
file://0012-corstone1000-Remove-reset-after-capsule-update.patch \
|
||||
file://0013-Platform-corstone1000-Fix-isolation-L2-memory-protection.patch \
|
||||
"
|
||||
|
||||
# TF-M ships patches for external dependencies that needs to be applied
|
||||
|
||||
@@ -64,6 +64,8 @@ SRC_URI:append = " \
|
||||
file://0046-Corstone1000-Change-MMCOMM-buffer-location.patch \
|
||||
file://0047-corstone1000-dts-add-external-system-node.patch \
|
||||
file://0048-corstone1000-Enable-UEFI-Secure-boot.patch \
|
||||
${@bb.utils.contains('MACHINE_FEATURES', 'corstone1000-extsys', \
|
||||
'', 'file://0049-corstone1000-purge-remoteproc-dts-node.patch' , d)} \
|
||||
"
|
||||
|
||||
do_configure:append() {
|
||||
|
||||
+34
@@ -0,0 +1,34 @@
|
||||
From 4e0ab7af882fcf498fd8beb4024ea024e6464cef Mon Sep 17 00:00:00 2001
|
||||
From: Harsimran Singh Tungal <harsimransingh.tungal@arm.com>
|
||||
Date: Wed, 14 Aug 2024 14:33:50 +0000
|
||||
Subject: [PATCH] corstone1000: purge remoteproc DTS node
|
||||
|
||||
Purge remoteproc DTS node
|
||||
This is done to remove the remote proc node from the DTS passed
|
||||
to Linux from U-Boot because the device tree binding for remoteproc
|
||||
has not been upstreamed yet. Existence of remoteproc DTS node in Linux
|
||||
is causing dt-schema test for SystemReady-IR v2.0 certification to fail.
|
||||
|
||||
Upstream-Status: Pending
|
||||
Signed-off-by: Harsimran Singh Tungal <harsimransingh.tungal@arm.com>
|
||||
---
|
||||
board/armltd/corstone1000/corstone1000.c | 3 +--
|
||||
1 file changed, 1 insertion(+), 2 deletions(-)
|
||||
|
||||
diff --git a/board/armltd/corstone1000/corstone1000.c b/board/armltd/corstone1000/corstone1000.c
|
||||
index ef74dc9032..d474fce1b2 100644
|
||||
--- a/board/armltd/corstone1000/corstone1000.c
|
||||
+++ b/board/armltd/corstone1000/corstone1000.c
|
||||
@@ -30,8 +30,7 @@ DT_NON_COMPLIANT_PURGE_LIST(foo) = {
|
||||
{ .node_path = "/soc/mhu@1b010000" },
|
||||
{ .node_path = "/soc/mhu@1b020000" },
|
||||
{ .node_path = "/soc/mhu@1b030000" },
|
||||
- { .node_path = "/soc/client" },
|
||||
- { .node_path = "/soc/extsys@1A010310" },
|
||||
+ { .node_path = "/soc/remoteproc@1a010310" },
|
||||
};
|
||||
|
||||
#define CORSTONE1000_KERNEL_PARTS 2
|
||||
--
|
||||
2.34.1
|
||||
|
||||
@@ -36,13 +36,21 @@ SRC_URI:append:corstone1000 = " ${@bb.utils.contains('MACHINE_FEATURES', \
|
||||
'file://corstone1000_kernel_debug.cfg', \
|
||||
'', \
|
||||
d)}"
|
||||
|
||||
SRC_URI:append:corstone1000 = " \
|
||||
file://extsys.cfg \
|
||||
file://0001-remoteproc-Add-Arm-remoteproc-driver.patch \
|
||||
file://0002-arm64-dts-Add-corstone1000-external-system-device-no.patch \
|
||||
file://0003-dt-bindings-remoteproc-Add-Arm-remoteproc.patch \
|
||||
"
|
||||
${@bb.utils.contains( \
|
||||
'MACHINE_FEATURES', \
|
||||
'corstone1000-extsys', \
|
||||
' \
|
||||
file://extsys.cfg \
|
||||
file://0001-remoteproc-Add-Arm-remoteproc-driver.patch \
|
||||
file://0002-arm64-dts-Add-corstone1000-external-system-device-no.patch \
|
||||
file://0003-dt-bindings-remoteproc-Add-Arm-remoteproc.patch \
|
||||
', \
|
||||
'', \
|
||||
d \
|
||||
) \
|
||||
} \
|
||||
"
|
||||
|
||||
# Default kernel features not needed for corstone1000
|
||||
# otherwise the extra kernel modules will increase the rootfs size
|
||||
|
||||
@@ -0,0 +1,39 @@
|
||||
from oeqa.runtime.case import OERuntimeTestCase
|
||||
|
||||
|
||||
class SystemReadyFedoraUnattendedTest(OERuntimeTestCase):
|
||||
def setUp(self):
|
||||
super().setUp()
|
||||
self.console = self.target.DEFAULT_CONSOLE
|
||||
|
||||
def test_fedora_unattended(self):
|
||||
# Turn on the FVP.
|
||||
self.target.transition('on')
|
||||
|
||||
# Timeout value = elapsed time * 2; where elapsed time was collected
|
||||
# from the elapsed time in the log.do_testimage for each function after
|
||||
# the build is finished on the development machine.
|
||||
self.target.expect(self.console,
|
||||
' Booting `Install Fedora 39\'',
|
||||
timeout=(2 * 60))
|
||||
bb.plain('Installation status: Loading the installer, kernel and initrd...')
|
||||
|
||||
self.target.expect(self.console,
|
||||
'Setting up the installation environment',
|
||||
timeout=(2 * 60 * 60))
|
||||
bb.plain('Installation status: Setting up the installation environment...')
|
||||
|
||||
self.target.expect(self.console,
|
||||
'Installing the software',
|
||||
timeout=(30 * 60))
|
||||
bb.plain('Installation status: Installing the software packages...')
|
||||
|
||||
# Waiting to respond to the boot loader prompt error message.
|
||||
self.target.expect(self.console,
|
||||
'Please respond \'yes\' or \'no\': ',
|
||||
timeout=(16 * 60 * 60))
|
||||
self.target.sendline(self.console, 'yes')
|
||||
|
||||
# Waiting till the installation is finished.
|
||||
self.target.expect(self.console, r'.*login: ', timeout=(5 * 60 * 60))
|
||||
bb.plain('Installation status: Fedora installation finished successfully.')
|
||||
+119
@@ -0,0 +1,119 @@
|
||||
require arm-systemready-linux-distros.inc
|
||||
|
||||
# The Fedora project does not provide a license manifest for the distributed ISO images.
|
||||
# The following list only contains the SPDX license identifiers found on the rpm
|
||||
# packages from the ISO image and is not exhaustive.
|
||||
# For more information about Fedora licenses, including the non-free ones, refer to
|
||||
# https://docs.fedoraproject.org/en-US/legal/fedora-linux-license/.
|
||||
LICENSE = "GPL-1.0-only & GPL-1.0-or-later & GPL-2.0-only & GPL-2.0-or-later & GPL-2.0-with-font-exception \
|
||||
& GPL-2.0-with-GCC-exception & GPL-3.0-only & GPL-3.0-or-later & GPL-3-with-bison-exception \
|
||||
& LGPL-2.0-only & LGPL-2.0-or-later & LGPL-2.1-only & LGPL-2.1-or-later & LGPL-3.0-only & LGPL-3.0-or-later \
|
||||
& 0BSD & BSD-2-Clause & BSD-3-Clause & BSD-3-Clause-Modification & BSD-4-Clause & BSD-4-Clause-UC \
|
||||
& ClArtistic & Artistic-2.0 & Artistic-1.0-Perl & Apache-2.0 & Apache-2.0-with-LLVM-exception & Zlib \
|
||||
& zlib-acknowledgement & Sleepycat & MIT & MIT-open-group & MIT-Modern-Variant & Unlicense & ISC \
|
||||
& AFL-2.1 & AGPL-3.0-only & AGPL-3.0-or-later & FSFAP & MPL-1.1 & MPL-2.0 & CC-BY-3.0 & CC-BY-4.0 \
|
||||
& CC-BY-SA-4.0 & CC0-1.0 & NCSA & APSL-2.0 & IJG & psutils & Sendmail & blessing & NTP & BSL-1.0 \
|
||||
& GFDL-1.1-or-later & GFDL-1.2-or-later & GFDL-1.3 & GFDL-1.3-or-later & GFDL-1.3-no-invariants-or-later \
|
||||
& NPL-1.1 & libtiff & Vim & curl & EUPL-1.1 & OFL-1.1 & OFL-1.1-RFN & FTL & Info-ZIP & Interbase-1.0 \
|
||||
& Unicode-DFS-2016 & SISSL & LPPL-1.3a & SGI-B-2.0 & PSF-2.0 & X11 & OLDAP-2.8 & PostgreSQL & OPUBL-1.0"
|
||||
|
||||
LIC_FILES_CHKSUM = "\
|
||||
file://${COMMON_LICENSE_DIR}/GPL-1.0-only;md5=e9e36a9de734199567a4d769498f743d \
|
||||
file://${COMMON_LICENSE_DIR}/GPL-1.0-or-later;md5=30c0b8a5048cc2f4be5ff15ef0d8cf61 \
|
||||
file://${COMMON_LICENSE_DIR}/GPL-2.0-only;md5=801f80980d171dd6425610833a22dbe6 \
|
||||
file://${COMMON_LICENSE_DIR}/GPL-2.0-or-later;md5=fed54355545ffd980b814dab4a3b312c \
|
||||
file://${COMMON_LICENSE_DIR}/GPL-2.0-with-font-exception;md5=bf93e21a513f6f923474e62fb920434d \
|
||||
file://${COMMON_LICENSE_DIR}/GPL-2.0-with-GCC-exception;md5=14c42911132e8c9008911385aede6449 \
|
||||
file://${COMMON_LICENSE_DIR}/GPL-3.0-only;md5=c79ff39f19dfec6d293b95dea7b07891 \
|
||||
file://${COMMON_LICENSE_DIR}/GPL-3.0-or-later;md5=1c76c4cc354acaac30ed4d5eefea7245 \
|
||||
file://${COMMON_LICENSE_DIR}/GPL-3-with-bison-exception;md5=6e1bac3dc21fcc4fa049cf5c407eb7a2 \
|
||||
file://${COMMON_LICENSE_DIR}/LGPL-2.0-only;md5=9427b8ccf5cf3df47c29110424c9641a \
|
||||
file://${COMMON_LICENSE_DIR}/LGPL-2.0-or-later;md5=6d2d9952d88b50a51a5c73dc431d06c7 \
|
||||
file://${COMMON_LICENSE_DIR}/LGPL-2.1-only;md5=1a6d268fd218675ffea8be556788b780 \
|
||||
file://${COMMON_LICENSE_DIR}/LGPL-2.1-or-later;md5=2a4f4fd2128ea2f65047ee63fbca9f68 \
|
||||
file://${COMMON_LICENSE_DIR}/LGPL-3.0-only;md5=bfccfe952269fff2b407dd11f2f3083b \
|
||||
file://${COMMON_LICENSE_DIR}/LGPL-3.0-or-later;md5=c51d3eef3be114124d11349ca0d7e117 \
|
||||
file://${COMMON_LICENSE_DIR}/0BSD;md5=f667a3c3830a55a17ec3067709f4526c \
|
||||
file://${COMMON_LICENSE_DIR}/BSD-2-Clause;md5=cb641bc04cda31daea161b1bc15da69f \
|
||||
file://${COMMON_LICENSE_DIR}/BSD-3-Clause;md5=550794465ba0ec5312d6919e203a55f9 \
|
||||
file://${COMMON_LICENSE_DIR}/BSD-3-Clause-Modification;md5=27b46022df7bdef61a1e404fc3573f83 \
|
||||
file://${COMMON_LICENSE_DIR}/BSD-4-Clause;md5=624d9e67e8ac41a78f6b6c2c55a83a2b \
|
||||
file://${COMMON_LICENSE_DIR}/BSD-4-Clause-UC;md5=1da3cf8ad50cd8d5d1de3cfc53196d01 \
|
||||
file://${COMMON_LICENSE_DIR}/ClArtistic;md5=f633bbf0697ec33066b83adfa9ebe51d \
|
||||
file://${COMMON_LICENSE_DIR}/Artistic-2.0;md5=8bbc66f0ba93cec26ef526117e280266 \
|
||||
file://${COMMON_LICENSE_DIR}/Artistic-1.0-Perl;md5=8feedd169dbd5738981843bd7d931f9f \
|
||||
file://${COMMON_LICENSE_DIR}/Apache-2.0;md5=89aea4e17d99a7cacdbeed46a0096b10 \
|
||||
file://${COMMON_LICENSE_DIR}/Apache-2.0-with-LLVM-exception;md5=0bcd48c3bdfef0c9d9fd17726e4b7dab \
|
||||
file://${COMMON_LICENSE_DIR}/Zlib;md5=87f239f408daca8a157858e192597633 \
|
||||
file://${COMMON_LICENSE_DIR}/zlib-acknowledgement;md5=c76c64e2cf99efcfb5e2b26aa86b12e6 \
|
||||
file://${COMMON_LICENSE_DIR}/Sleepycat;md5=1cbb64231c94198653282f3ccab88ffb \
|
||||
file://${COMMON_LICENSE_DIR}/MIT;md5=0835ade698e0bcf8506ecda2f7b4f302 \
|
||||
file://${COMMON_LICENSE_DIR}/MIT-open-group;md5=a7c50bba311e4b09d48a526eedcef837 \
|
||||
file://${COMMON_LICENSE_DIR}/MIT-Modern-Variant;md5=272dea2b67586002978254bc04648ab2 \
|
||||
file://${COMMON_LICENSE_DIR}/Unlicense;md5=7246f848faa4e9c9fc0ea91122d6e680 \
|
||||
file://${COMMON_LICENSE_DIR}/ISC;md5=f3b90e78ea0cffb20bf5cca7947a896d \
|
||||
file://${COMMON_LICENSE_DIR}/AFL-2.1;md5=e40039b90e182a056bcd9ad3e47ddd71 \
|
||||
file://${COMMON_LICENSE_DIR}/AGPL-3.0-only;md5=73f1eb20517c55bf9493b7dd6e480788 \
|
||||
file://${COMMON_LICENSE_DIR}/AGPL-3.0-or-later;md5=a4af3f9f0c0fc9de318e4df46665906e \
|
||||
file://${COMMON_LICENSE_DIR}/FSFAP;md5=232368338ef6dc99de71c2e05ff12176 \
|
||||
file://${COMMON_LICENSE_DIR}/MPL-1.1;md5=1d38e87ed8d522c49f04e1efe0fab3ab \
|
||||
file://${COMMON_LICENSE_DIR}/MPL-2.0;md5=815ca599c9df247a0c7f619bab123dad \
|
||||
file://${COMMON_LICENSE_DIR}/CC-BY-3.0;md5=dfa02b5755629022e267f10b9c0a2ab7 \
|
||||
file://${COMMON_LICENSE_DIR}/CC-BY-4.0;md5=9b33bbd06fb58995fb0e299cd38d1838 \
|
||||
file://${COMMON_LICENSE_DIR}/CC-BY-SA-4.0;md5=4084714af41157e38872e798eb3fe1b1 \
|
||||
file://${COMMON_LICENSE_DIR}/CC0-1.0;md5=0ceb3372c9595f0a8067e55da801e4a1 \
|
||||
file://${COMMON_LICENSE_DIR}/NCSA;md5=1b5fdec70ee13ad8a91667f16c1959d7 \
|
||||
file://${COMMON_LICENSE_DIR}/APSL-2.0;md5=f9e4701d9a216a87ba145bbe25f54c58 \
|
||||
file://${COMMON_LICENSE_DIR}/IJG;md5=d9fc5ebaa95c14466091d25e0d34e688 \
|
||||
file://${COMMON_LICENSE_DIR}/psutils;md5=29046009c1f269661e7b74196fb8f6a0 \
|
||||
file://${COMMON_LICENSE_DIR}/Sendmail;md5=8037c42e05a5d4bfce06a44729fb6f1a \
|
||||
file://${COMMON_LICENSE_DIR}/blessing;md5=d5407b61870d6dc19d0bdc04ae4cc654 \
|
||||
file://${COMMON_LICENSE_DIR}/NTP;md5=0926fd147301b2a65e45e21adb3a6f14 \
|
||||
file://${COMMON_LICENSE_DIR}/BSL-1.0;md5=65a7df9ad57aacf825fd252c4c33288c \
|
||||
file://${COMMON_LICENSE_DIR}/GFDL-1.1-or-later;md5=03322744a1a73f36ebf29f98cced39a4 \
|
||||
file://${COMMON_LICENSE_DIR}/GFDL-1.2-or-later;md5=9f58808219e9a42ff1228309d6f83dc6 \
|
||||
file://${COMMON_LICENSE_DIR}/GFDL-1.3;md5=1083add59b39991c748ea70a92166959 \
|
||||
file://${COMMON_LICENSE_DIR}/GFDL-1.3-or-later;md5=e0771ae6a62dc8a2e50b1d450fea66b7 \
|
||||
file://${COMMON_LICENSE_DIR}/GFDL-1.3-no-invariants-or-later;md5=e0771ae6a62dc8a2e50b1d450fea66b7 \
|
||||
file://${COMMON_LICENSE_DIR}/NPL-1.1;md5=f9c017c062c1b02462efb915d9f2cb63 \
|
||||
file://${COMMON_LICENSE_DIR}/libtiff;md5=b99383975855adc28712577c9cd56485 \
|
||||
file://${COMMON_LICENSE_DIR}/Vim;md5=676d28582e2dca824e7e309a9865eeb1 \
|
||||
file://${COMMON_LICENSE_DIR}/curl;md5=f7adb1397db248527ffed14d947e445c \
|
||||
file://${COMMON_LICENSE_DIR}/EUPL-1.1;md5=3f12b8134016fd7ba5a010afd690abaa \
|
||||
file://${COMMON_LICENSE_DIR}/OFL-1.1;md5=fac3a519e5e9eb96316656e0ca4f2b90 \
|
||||
file://${COMMON_LICENSE_DIR}/OFL-1.1-RFN;md5=2680fce30f17e5fed9bcebd9336e5b78 \
|
||||
file://${COMMON_LICENSE_DIR}/FTL;md5=f0bf6b09ee8b02121ed10709d9e49d8b \
|
||||
file://${COMMON_LICENSE_DIR}/Info-ZIP;md5=83a1c8ea099b3b58beb6e55dcbe4c15f \
|
||||
file://${COMMON_LICENSE_DIR}/Interbase-1.0;md5=f65304bc0e87e6700fe1e4ab5affdc6f \
|
||||
file://${COMMON_LICENSE_DIR}/Unicode-DFS-2016;md5=907371994d651afe53e98adc27824669 \
|
||||
file://${COMMON_LICENSE_DIR}/SISSL;md5=fded06bff75eb4a2899bd051e2e128f5 \
|
||||
file://${COMMON_LICENSE_DIR}/LPPL-1.3a;md5=8e2e8e1428b39cd78927c2ad28734ff7 \
|
||||
file://${COMMON_LICENSE_DIR}/SGI-B-2.0;md5=5f5dd7bd973dff1594131b1e9c7981f1 \
|
||||
file://${COMMON_LICENSE_DIR}/PSF-2.0;md5=76c1502273262a5ebefb50dfb20d7c4f \
|
||||
file://${COMMON_LICENSE_DIR}/X11;md5=87f08485cf6ba3c63a00eda8ecba7f1d \
|
||||
file://${COMMON_LICENSE_DIR}/OLDAP-2.8;md5=bb28ada4fbb5c3f52c233899b2e410a5 \
|
||||
file://${COMMON_LICENSE_DIR}/PostgreSQL;md5=a9c78964f52e27f4c01140a1a16da8e2 \
|
||||
file://${COMMON_LICENSE_DIR}/OPUBL-1.0;md5=99367d4750dbf0ae6cc74209ddd52f6d \
|
||||
"
|
||||
|
||||
ARM_SYSTEMREADY_LINUX_DISTRO_INSTALL_SIZE = "6144"
|
||||
|
||||
TEST_SUITES = "${@oe.utils.vartrue("DISTRO_UNATTENDED_INST_TESTS", "arm_systemready_fedora_unattended", "", d)}"
|
||||
|
||||
ISO_LABEL = "${@oe.utils.vartrue("DISTRO_UNATTENDED_INST_TESTS", "Fedora-S-dvd-aarch64-39", "", d)}"
|
||||
BOOT_CATALOG = "${@oe.utils.vartrue("DISTRO_UNATTENDED_INST_TESTS", "boot.catalog", "", d)}"
|
||||
BOOT_IMAGE = "${@oe.utils.vartrue("DISTRO_UNATTENDED_INST_TESTS", "EFI/BOOT/BOOTAA64.EFI", "", d)}"
|
||||
EFI_IMAGE = "${@oe.utils.vartrue("DISTRO_UNATTENDED_INST_TESTS", "images/efiboot.img", "", d)}"
|
||||
|
||||
PV = "39.1.5"
|
||||
SRC_URI = "https://download.fedoraproject.org/pub/fedora/linux/releases/39/Server/aarch64/iso/Fedora-Server-dvd-aarch64-39-1.5.iso;unpack=0;downloadfilename=${ISO_IMAGE_NAME}.iso"
|
||||
SRC_URI[sha256sum] = "d19dc2a39758155fa53e6fd555d0d173ccc8175b55dea48002d499f39cb30ce0"
|
||||
|
||||
modifyiso() {
|
||||
UNATTENDED_CONF_DIR="${THISDIR}/unattended-boot-conf/Fedora"
|
||||
|
||||
cp "${UNATTENDED_CONF_DIR}/ks.cfg" ${EXTRACTED_ISO_TEMP_DIR}
|
||||
sed -i 's/set default="1"/set default="0"/g' "${EXTRACTED_ISO_TEMP_DIR}/EFI/BOOT/grub.cfg"
|
||||
sed -i 's/set timeout=60/set timeout=0/g' "${EXTRACTED_ISO_TEMP_DIR}/EFI/BOOT/grub.cfg"
|
||||
sed -i '0,/vmlinuz/s/vmlinuz/& inst.ks=hd:LABEL=Fedora-S-dvd-aarch64-39:\/ks.cfg/' "${EXTRACTED_ISO_TEMP_DIR}/EFI/BOOT/grub.cfg"
|
||||
}
|
||||
+45
@@ -0,0 +1,45 @@
|
||||
SUMMARY = "Arm SystemReady Linux distros unattended requirements"
|
||||
DESCRIPTION = "Arm SystemReady Linux distro unattended configurations \
|
||||
and ISO image modification"
|
||||
|
||||
EXTRACTED_ISO_TEMP_DIR = "${WORKDIR}/extracted_iso_temp_dir"
|
||||
NEW_ISO_TEMP_DIR = "${WORKDIR}/new_iso_temp_dir"
|
||||
|
||||
# oeqa test case must be added to TEST_SUITES to acknowledge that the unattended
|
||||
# installation was successful.
|
||||
inherit testimage
|
||||
|
||||
python () {
|
||||
unattended_required_vars = ['ISO_LABEL', 'BOOT_CATALOG', 'BOOT_IMAGE', 'EFI_IMAGE']
|
||||
|
||||
for var in unattended_required_vars:
|
||||
if not d.getVar(var):
|
||||
raise bb.parse.SkipRecipe(f'{var} variable is not set')
|
||||
}
|
||||
|
||||
unpackiso() {
|
||||
# Unpack the ISO image
|
||||
bsdtar -xf ${WORKDIR}/${ISO_IMAGE_NAME}.iso -C ${EXTRACTED_ISO_TEMP_DIR}
|
||||
chmod -R u+rw ${EXTRACTED_ISO_TEMP_DIR}
|
||||
}
|
||||
|
||||
modifyiso() {
|
||||
|
||||
}
|
||||
|
||||
repackiso() {
|
||||
# Repack the ISO image
|
||||
mkisofs -o ${NEW_ISO_TEMP_DIR}/${ISO_IMAGE_NAME}.iso -U -r -v -T -J -joliet-long -V ${ISO_LABEL} \
|
||||
-volset ${ISO_LABEL} -A ${ISO_LABEL} -b ${BOOT_IMAGE} -c ${BOOT_CATALOG} -no-emul-boot \
|
||||
-boot-load-size 4 -boot-info-table -J -R -V ${ISO_LABEL} -eltorito-alt-boot \
|
||||
-eltorito-boot ${EFI_IMAGE} -no-emul-boot ${EXTRACTED_ISO_TEMP_DIR}
|
||||
|
||||
mv -f ${NEW_ISO_TEMP_DIR}/${ISO_IMAGE_NAME}.iso ${WORKDIR}
|
||||
}
|
||||
|
||||
# Write the test data in IMAGE_POSTPROCESS_COMMAND
|
||||
IMAGE_POSTPROCESS_COMMAND += "write_image_test_data; "
|
||||
|
||||
do_unpack[depends] += "cdrtools-native:do_populate_sysroot libarchive-native:do_populate_sysroot"
|
||||
do_unpack[postfuncs] += "unpackiso modifyiso repackiso"
|
||||
do_unpack[cleandirs] += "${EXTRACTED_ISO_TEMP_DIR} ${NEW_ISO_TEMP_DIR}"
|
||||
+13
-2
@@ -2,7 +2,12 @@ SUMMARY = "Arm SystemReady Linux distros installation"
|
||||
DESCRIPTION = "Arm SystemReady Linux distro CD/DVD images and installation \
|
||||
target disk image"
|
||||
|
||||
IMAGE_CLASSES:remove = "license_image testimage"
|
||||
DISTRO_UNATTENDED_INST_TESTS ?= "0"
|
||||
|
||||
require ${@oe.utils.vartrue("DISTRO_UNATTENDED_INST_TESTS", "arm-systemready-linux-distros-unattended.inc", "", d)}
|
||||
|
||||
IMAGE_CLASSES:remove = "license_image"
|
||||
IMAGE_CLASSES:remove = "${@oe.utils.vartrue("DISTRO_UNATTENDED_INST_TESTS", "", "testimage", d)}"
|
||||
BUILDHISTORY_FEATURES:remove = "image"
|
||||
|
||||
INHIBIT_DEFAULT_DEPS = "1"
|
||||
@@ -15,7 +20,7 @@ do_configure[noexec] = "1"
|
||||
do_compile[noexec] = "1"
|
||||
|
||||
ISO_IMAGE_NAME = "${PN}-${PV}"
|
||||
IMAGE_LINK_NAME = "${PN}-${PV}-${MACHINE}"
|
||||
IMAGE_LINK_NAME = "${PN}-${MACHINE}"
|
||||
|
||||
ARM_SYSTEMREADY_LINUX_DISTRO_ISO_IMAGE = \
|
||||
"${DEPLOY_DIR_IMAGE}/${ISO_IMAGE_NAME}.iso"
|
||||
@@ -44,7 +49,13 @@ python do_image_complete() {
|
||||
from oe.utils import execute_pre_post_process
|
||||
post_process_cmds = d.getVar("IMAGE_POSTPROCESS_COMMAND")
|
||||
execute_pre_post_process(d, post_process_cmds)
|
||||
|
||||
if d.getVar('DISTRO_UNATTENDED_INST_TESTS') == "1":
|
||||
# Ensure an empty rootfs manifest exists (required by testimage)
|
||||
fname = os.path.join(d.getVar('IMGDEPLOYDIR'), d.getVar('IMAGE_LINK_NAME') + ".manifest")
|
||||
open(fname, 'w').close()
|
||||
}
|
||||
|
||||
do_image_complete[nostamp] = "1"
|
||||
addtask image_complete after do_deploy before do_build
|
||||
|
||||
|
||||
+39
@@ -0,0 +1,39 @@
|
||||
# Generated by Anaconda 39.32.6
|
||||
# Generated by pykickstart v3.48
|
||||
#version=DEVEL
|
||||
# Use text mode install
|
||||
text
|
||||
|
||||
# Keyboard layouts
|
||||
keyboard --vckeymap=us --xlayouts='us'
|
||||
# System language
|
||||
lang en_GB.UTF-8
|
||||
|
||||
# Use CDROM installation media
|
||||
cdrom
|
||||
|
||||
%packages --excludedocs --ignoremissing
|
||||
@core --nodefaults
|
||||
|
||||
%end
|
||||
|
||||
# Run the Setup Agent on first boot
|
||||
firstboot --enable
|
||||
# Do not configure the X Window System
|
||||
skipx
|
||||
|
||||
# System bootloader configuration
|
||||
bootloader --location=mbr --boot-drive=vda
|
||||
autopart
|
||||
# Partition clearing information
|
||||
clearpart --all --initlabel --drives=vda
|
||||
|
||||
# System timezone
|
||||
timezone Europe/London --utc
|
||||
|
||||
# Root password
|
||||
rootpw --lock
|
||||
user --groups=wheel --name=user --password=unsafe --gecos="usr1"
|
||||
|
||||
# Reboot after installation with an attempt to eject the installation media
|
||||
reboot --eject
|
||||
@@ -0,0 +1 @@
|
||||
PACKAGECONFIG:remove = "${@bb.utils.contains('TCMODE', 'external-arm', 'libmount-mountfd-support', '' , d)}"
|
||||
@@ -134,8 +134,14 @@ class FVPRunner:
|
||||
for console in self._pexpects:
|
||||
import pexpect
|
||||
# Ensure pexpect logs all remaining output to the logfile
|
||||
console.expect(pexpect.EOF, timeout=5.0)
|
||||
console.close()
|
||||
try:
|
||||
console.expect(pexpect.EOF, timeout=30.0)
|
||||
except pexpect.TIMEOUT:
|
||||
pexpect_logfile = ""
|
||||
if console.logfile is not None:
|
||||
pexpect_logfile = f" ({console.logfile})"
|
||||
self._logger.debug(f"Unable to get EOF on pexpect spawn obj{pexpect_logfile}.")
|
||||
console.close(force=True)
|
||||
|
||||
if self._fvp_process and self._fvp_process.returncode and \
|
||||
self._fvp_process.returncode > 0:
|
||||
|
||||
@@ -3,6 +3,7 @@ import enum
|
||||
import pathlib
|
||||
import pexpect
|
||||
import os
|
||||
import time
|
||||
|
||||
from oeqa.core.target.ssh import OESSHTarget
|
||||
from fvp import runner
|
||||
@@ -127,9 +128,19 @@ class OEFVPTarget(OESSHTarget):
|
||||
def call_pexpect(terminal, *args, **kwargs):
|
||||
attr = getattr(self.terminals[terminal], name)
|
||||
if callable(attr):
|
||||
return attr(*args, **kwargs)
|
||||
self.logger.debug(f"Calling {name} on {terminal} : with arguments -> {args} : {kwargs}")
|
||||
start_time = time.monotonic() # Record the start time
|
||||
|
||||
attr = getattr(self.terminals[terminal], name)
|
||||
result = attr(*args, **kwargs)
|
||||
|
||||
end_time = time.monotonic() # Record the end time
|
||||
elapsed_time = end_time - start_time
|
||||
self.logger.debug(f"Execution time for result: [ {result} ] - elapsed_time: {elapsed_time} seconds")
|
||||
else:
|
||||
return attr
|
||||
result = attr
|
||||
|
||||
return result
|
||||
|
||||
return call_pexpect
|
||||
|
||||
|
||||
@@ -1,16 +1,29 @@
|
||||
from oeqa.runtime.case import OERuntimeTestCase
|
||||
from oeqa.core.decorator.data import skipIfNotInDataVar
|
||||
from oeqa.core.decorator.depends import OETestDepends
|
||||
from time import sleep
|
||||
|
||||
|
||||
class FvpDevicesTest(OERuntimeTestCase):
|
||||
def run_cmd(self, cmd, check=True):
|
||||
def run_cmd(self, cmd, check=True, retry=3):
|
||||
"""
|
||||
A wrapper around self.target.run, which:
|
||||
* Fails the test on command failure by default
|
||||
* Allows the "run" behavior to be overridden in sub-classes
|
||||
* Has a retry mechanism when SSH returns 255
|
||||
"""
|
||||
(status, output) = self.target.run(cmd)
|
||||
status = 255
|
||||
# The loop is retrying the self.target.run() which uses SSH only when
|
||||
# the SSH return code is 255, which might be an issue with
|
||||
# "Connection refused" because the port isn't open yet
|
||||
while status == 255 and retry > 0:
|
||||
(status, output) = self.target.run(cmd)
|
||||
retry -= 1
|
||||
# In case the status is 255, delay the next retry to give time to
|
||||
# the system to settle
|
||||
if status == 255:
|
||||
sleep(30)
|
||||
|
||||
if status and check:
|
||||
self.fail("Command '%s' returned non-zero exit "
|
||||
"status %d:\n%s" % (cmd, status, output))
|
||||
|
||||
Reference in New Issue
Block a user