Commit Graph

2423 Commits

Author SHA1 Message Date
Francisco Gil 97d8740fb2 ccmp25: swupdate: fix hardcoded index in fwupdate strategy
https://onedigi.atlassian.net/browse/DEL-9228

Signed-off-by: Francisco Gil <francisco.gilmartinez@digi.com>
2024-10-11 14:57:14 +02:00
Francisco Gil 7c543bbafb ccmp25: swupdate: remove unnecessary logic in the script
The rdiff update is only available for dual-boot systems,
and it is checked at the beginning of the process.
We can remove the related logic and some variables in the
script.

Signed-off-by: Francisco Gil <francisco.gilmartinez@digi.com>

# Conflicts:
#	meta-digi-dey/recipes-digi/swu-images/files/update_rdiff.sh
2024-10-11 14:57:14 +02:00
Arturo Buzarra ed8113d99b meta-digi: revert revisions to AUTOREV
Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
2024-10-08 12:00:57 +02:00
Arturo Buzarra 46f15efff2 meta-digi: update revisions for dey-4.0-r7.2
Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
2024-10-08 12:00:57 +02:00
Hector Palacios d1105835e2 dey.conf: bump DEY_BUILD version
Signed-off-by: Hector Palacios <hector.palacios@digi.com>

https://onedigi.atlassian.net/browse/DEL-9291
2024-10-08 12:00:57 +02:00
Javier Viguera 548adca09b eiq-examples: use yocto provided native python
Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2024-10-04 12:34:22 +02:00
Javier Viguera da37858d80 eiq-examples: fix dependence on vela native tool
The recipe level DEPENDS on ethos-u-vela-native is insufficient to ensure
the native vela tool population into the eiq-examples recipe sysroot
native directory before use. The new download_transform_models task uses
that tool, so add the dependence on the task to ensure it is available
before use.

While on it, configure the working directory of the new task using the
Yocto way (using task[dirs]).

Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2024-10-04 11:53:27 +02:00
Isaac Hermida 82851b0308 eiq-examples: improvements
* do not run the demos in background, if not they can not be ctrl+c.
* fix service dependencies: required camera and weston.
* patch the examples to:
** set camera resolution to 1280x720
** set default format to ov5640 camera (YUYV)
** detect the "x" event when the demo application is running in windowed mode (not fullscreen).

Signed-off-by: Isaac Hermida <isaac.hermida@digi.com>
2024-10-03 17:04:06 +02:00
Hector Palacios 720d627bd3 cccs: add libubootenv as RDEPENDS of daemon
Some parameters of the CCCS configuration file need to be substituted
at run-time during a postinst script. Such script takes actions depending
on the value of U-Boot env variables.
The libubootenv recipe itself also has a postinst script that modifies
the U-Boot env configuration file (on NAND-based platforms).
If there are no dependencies between these two recipes, poky will decide
the order in which the postinst scripts are named (and thus executed)
during the first boot.
By creating the rdepends to libubootenv, we guarantee that its postinst
script is run before the cccs one, which depends on the environment being
accessible.

Signed-off-by: Hector Palacios <hector.palacios@digi.com>

https://onedigi.atlassian.net/browse/DEL-9282
2024-10-02 18:12:59 +02:00
Hector Palacios 52287bf6be cccs: specify the runtime package (daemon) that requires the postinst
The postinst modifies the /etc/cccs.conf config file used by the daemon.

Signed-off-by: Hector Palacios <hector.palacios@digi.com>
2024-10-02 18:12:59 +02:00
Hector Palacios 2880f7ea0f cccs: [cosmetic] group RDEPENDS in a single line
Signed-off-by: Hector Palacios <hector.palacios@digi.com>
2024-10-02 18:12:59 +02:00
Javier Viguera 3e1f3cdf9e swupdate: clean warning on firmware update
The swupdate description file allows to configure the setting of u-boot
environment variables. For some platforms the "upgrade_available" variable
has an empty value, and swupdate parser warns when the description asks
to set a variable with an empty value.
    
Initialize the variable to 0, which is semantically the same for u-boot.

https://onedigi.atlassian.net/browse/DEL-9279

Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2024-10-02 11:17:35 +02:00
David Escalona 1de1fae447 stm32mpu-ai: add external delegate library to use NPU
Actually, the NPU demos were not making use of the NPU, just the CPU. To enable the NPU usage,
it is required to add the external delegate library 'tflite-vx-delegate'to the system. This is
done by forcing 'tensorflow-lite' to depend on it for the CCMP2 platform, which also requires
'tim-vx' library as a build dependency.

Both the 'tflite-vx-delegate' and 'tim-vx' recipes have been verbatim copied from the ST Beta
branch, using commit with SHA256: 68686850c75061f1c7c4e756a313a41ca810f6ae

Signed-off-by: David Escalona <david.escalona@digi.com>
2024-10-01 11:09:11 +02:00
Francisco Gil d9ef21b3d0 meta-digi: revert revisions to AUTOREV
Signed-off-by: Francisco Gil <francisco.gilmartinez@digi.com>
2024-09-30 16:39:57 +02:00
Francisco Gil c179cd862c meta-digi: update revisions for dey-4.0-r7.1
Signed-off-by: Francisco Gil <francisco.gilmartinez@digi.com>
2024-09-30 16:38:44 +02:00
Javier Viguera 7b50fb3a06 bluetooth-init: ensure the interface is up before unloading the module
This is a workaround for a driver failure when unloading the module. The
"btnxpuart" driver crashes with a null pointer dereference if the bluetooth
interface is down when the module is unloaded.

Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2024-09-27 14:09:23 +02:00
Javier Viguera 55f8ccadec bluetooth-init: start driver load service before bluetooth daemon
Revert to the previous used order for the bluetooth related
services. First, load the driver and then execute the bluetooth
daemon. This is needed for two reasons:

  * The bluetooth daemon caches the MAC address. Loading the module before
    ensures the daemon caches the correct MAC.
  * The connectcore-demo server stops working if the bluetooth interface
    is unavailable when the server launches. This order ensures the demo
    works as expected.

This change also brings back the problem of the btnxpuart module unload
failure on reboot/suspend. The following commit adds a workaround for
the driver issue.

Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2024-09-27 14:02:34 +02:00
Arturo Buzarra 53b9fd076d Merge branch 'dey-4.0/master' into dey-4.0/maint
Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
2024-09-25 15:53:50 +02:00
David Escalona 7d4a490a44 dey-image-webkit: include st npu samples in the image for the ccmp25 platform
https://onedigi.atlassian.net/browse/CCS-12

Signed-off-by: David Escalona <david.escalona@digi.com>
2024-09-25 14:02:41 +02:00
David Escalona 4bc892961d stm32mpu-ai: recipes-samples: customize st npu samples
Customize the NPU samples provided by ST so they can be executed in our DEY images:
- Add a generic launch script to pre-configure environment variables before launching demos.
- Remove 'weston' user check from demos launch scripts.
- Reduce font size for big screens.
- Set camera resolution to 640x480px and center the image.
- Adapt home folder to 'root' user instead of 'weston'.
- Adapt package group to include the new samples and remove the old ones.
- Fix a couple of errors with models download and include them manually.
- Add a runtime dependency with 'libdrm-tests' as the 'modetest' binary is required.

https://onedigi.atlassian.net/browse/CCS-12

Signed-off-by: David Escalona <david.escalona@digi.com>
2024-09-25 14:02:34 +02:00
David Escalona 1f678d39a3 stm32mpu-ai: recipes-samples: verbatim copy of npu samples from st beta branch
Current samples were not working properly due to problems with libraries and
the runtime frameworks.

This commit brings the updated samples recipes with the new folder structure
that have been proved to work as they were in the st beta branch, using commit
with SHA256: 68686850c75061f1c7c4e756a313a41ca810f6ae

https://onedigi.atlassian.net/browse/CCS-12

Signed-off-by: David Escalona <david.escalona@digi.com>
2024-09-25 13:47:47 +02:00
David Escalona 983df1b9cb stm32mpu-ai: tensorflow-lite: backport recipe from github st main
Current recipe build was failing due to dependencies with cpuinfo header files and
libraries. This commit backports the recipe that is currently being built in the
ST main branch in GitHub which clears these dependencies.

The recipe was backported as it was in commit with SHA256:
fc56201c67adf899080cff5b45ed33824e427609

https://onedigi.atlassian.net/browse/CCS-12

Signed-off-by: David Escalona <david.escalona@digi.com>
2024-09-25 13:47:47 +02:00
David Escalona 5bf2f9b99c stm32mpu-ai: onnxruntime: backport recipe from github st main
Current recipe build was failing due to dependencies with cpuinfo header files and
libraries. This commit backports the recipe that is currently being built in the
ST main branch in GitHub which clears these dependencies.

The recipe was backported as it was in commit with SHA256:
fc56201c67adf899080cff5b45ed33824e427609

https://onedigi.atlassian.net/browse/CCS-12

Signed-off-by: David Escalona <david.escalona@digi.com>
2024-09-25 13:47:47 +02:00
David Escalona b461dd18ce stm32mpu-ai: update cmake-native to version 3.25
Backport a new version of cmake-native from Poky's mickledore release. This
is required by the new version of the onnxruntime package (backported in
the following commit).

https://onedigi.atlassian.net/browse/CCS-12

Signed-off-by: David Escalona <david.escalona@digi.com>
2024-09-25 13:47:47 +02:00
David Escalona c8d5dd29dd conf: allow one additional recipe nesting level to stm32mpu-ai layer
https://onedigi.atlassian.net/browse/CCS-12

Signed-off-by: David Escalona <david.escalona@digi.com>
2024-09-25 13:47:47 +02:00
David Escalona f04581b9a6 eiq-examples: extend recipe to download and transform models in the host
Until now, the recipe only installed the binaries and some scripts in the target device. Then,
user had to execute an script in the running system to download and transform the models for
the demo, a process that could take up to 30 minutes. Also, a custom script was required to
acomodate the environment settings before executing any demo. All of this was preventing us from
creating out-of-the-box images including NPU demos for exhibitions and clients.

With the new changes, the recipe now downloads and transforms all the models in the host machine,
saving around 27 minutes and leaving the demos in the target ready to be executed. To ease the
process, a launch script is included for all the demos to configure the environment as well as an
auto-start service.

https://onedigi.atlassian.net/browse/CCS-10

Co-authored-by: Isaac Hermida <isaac.hermida@digi.com>
Signed-off-by: David Escalona <david.escalona@digi.com>
2024-09-25 13:47:36 +02:00
Javier Viguera bee97587cb orc: fix native build on ubuntu 18
Ubuntu 18 is still a supported distro for Kirkstone, but a recent update
of orc is failing the native build, because it requires a GCC version
newer than the default included in ubuntu 18.

This commit backports a fix which is part of upstream orc 0.4.40.

Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2024-09-24 12:34:14 +02:00
Isaac Hermida 9f7a8e64ce conf: distro: remove Y2038 compilation flag from alsa-lib
Despite the recipe builds for arm, it crashes at runtime.
While on it, alphabetically sort the list of excluded packages.

https://onedigi.atlassian.net/browse/DEL-9245

Signed-off-by: Isaac Hermida <isaac.hermida@digi.com>
2024-09-23 15:52:32 +02:00
Arturo Buzarra 909427ed4a init-ifupdown: virtwlans: add support to ConnectCore MP2 platform
https://onedigi.atlassian.net/browse/DEL-9237

Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
2024-09-19 13:37:01 +02:00
Arturo Buzarra 19be4782ee wpa_supplicant/hostapd: update support to include ConnectCore MP2 platform
This commit updates the wpa-supplicant and hostapd recipes to apply the Murata
release patch series for ConnectCore MP2 platform.

https://onedigi.atlassian.net/browse/DEL-9237

Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
2024-09-19 13:37:01 +02:00
Hector Palacios fa4d07713e psplash: use a PNG logo for psplash instead of *.h file
A preprocessed *.h Digi logo file was used for the psplash.
The psplash recipe from Poky admits a PNG file as input and
does the conversion automatically.

Use a Digi PNG logo and set it using SPLASH_IMAGES variable.
This way, it is easier for users to substitute with their own
logos.

Signed-off-by: Hector Palacios <hector.palacios@digi.com>

https://onedigi.atlassian.net/browse/DEL-9239
2024-09-18 17:43:32 +02:00
Isaac Hermida 97dc7ddd36 pulseaudio: ccmp25: avoid speaker mute
based on commit 951f20d36b, this fix
avoids muting the speaker control.
Despite the original commit is for Headphone, it also applies, for the
ccmp25, to the Speaker control.
While on it, reword the files so the change applies to all stm platforms
by using the common machine.

https://onedigi.atlassian.net/browse/DEL-9227

Signed-off-by: Isaac Hermida <isaac.hermida@digi.com>
2024-09-18 16:44:07 +02:00
Arturo Buzarra a5df257864 connectcore-demo-server: ccmp25: start service after bluetooth init script
ConnectCore MP25 initializes the Bluetooth interface with a init script, so
this commit adds a runtime dependency between the connectcore-demo-server and
the cyw55512-bluetooth service.

Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
2024-09-16 22:30:01 +02:00
Javier Viguera 6107312f03 bluetooth-init: fix systemd service syntax
According to systemd manual, "After" setting expects a space-separated
list. Fix the wrong comma-separated list to prevent the following boot
failure:

  bluetooth-init.service:4: Failed to add dependency on systemd-udev-settle.service,bluetooth.service, ignoring: Invalid argument

Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2024-09-16 18:58:15 +02:00
Mike Engel 6a2737136d conf: distro: add compilation flag to fix Y2038 issue
This commit adds compilation flag for ARM 32Bit architecture
to use 64Bit structure for time_t to fix the Y2038 issue
instead of 32Bit structure.

https://onedigi.atlassian.net/browse/DEL-9216

Signed-off-by: Mike Engel <Mike.Engel@digi.com>
2024-09-16 12:32:56 +02:00
Francisco Gil 40c6f76859 swupdate: ccmp25: update variables to match the ccmp25 partition table
https://onedigi.atlassian.net/browse/DEL-9228

Signed-off-by: Francisco Gil <francisco.gilmartinez@digi.com>
2024-09-13 15:59:36 +02:00
Arturo Buzarra 8f0d1cc65e base-files: fix conflict with procps about sysctl.conf
This commit fixes a build issue by including the procps recipe which also
installs the sysctl.conf file. Since adding this config file in base-file
recipe is something custom from DEY, we include this file only for "dey"
distribution to avoid conflicts.

Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
2024-09-12 13:55:26 +02:00
Francisco Gil ff5f7ddad4 meta-digi: ccmp2-dvk: update libdigiapix.conf
The i2c-1 has the index 0 in the linux user space.

Signed-off-by: Francisco Gil <francisco.gilmartinez@digi.com>
2024-09-12 08:49:37 +02:00
Javier Viguera b6d7853fec meta-digi-dey: fix wifi-related functionality overrides for ccimx91
Some wifi-related functionality was enabled on ccimx93 overrides. The
ccimx91 also needs this functionality but it was not being applied as
the overrides were only for ccimx93.

Generalize the overrides for ccimx9.

https://onedigi.atlassian.net/browse/DEL-9214

Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2024-09-11 12:12:14 +02:00
Mike Engel c5c0c7c966 systemd-boot: meson: Fix build with --optimization=plain
This commit fixes build issues with optimization=plain.

commit: ec35091c8a358aacbf787afb2bfab6a0996031ed

Signed-off-by: Mike Engel <Mike.Engel@digi.com>
2024-09-04 12:54:43 +02:00
Mike Engel 269d80105d recovery-utils: add preprocessor flag to change recovery tool usage help
This commit adds a compiler flag to remove certain options from the
recovery-utils, because some features rely on functionality that is
not supported by the CCMP1 platforms.

https://onedigi.atlassian.net/browse/DEL-9116

Signed-off-by: Mike Engel <Mike.Engel@digi.com>
2024-09-04 11:34:40 +02:00
Mike Engel 11426fcb5b recovery: add initramfs into FIT recovery image
This commit adds the initramfs into the FIT recovery
image. If the RAM disk image is included in the FIT
image we need to create a initramfs file that doesn't
include the u-boot header, because the FIT descriptor
contains all the necessary information to use the
initramfs file.

https://onedigi.atlassian.net/browse/DEL-9168

Signed-off-by: Mike Engel <Mike.Engel@digi.com>
2024-09-04 11:34:40 +02:00
Javier Viguera 4c33a85d6b bluetooth-init: start driver load service after bluetooth daemon
The bluetooth daemon does not need the interface to exist before being
executed. We configure the daemon with AutoEnable=true, which will enable
adapters present on start or that appear later on.

On shutdown, systemd stops services in the opposite order to the boot,
so configuring the driver load service after the bluetooth service,
ensures that on shutdown the driver is unloaded before the bluetooth
daemon is stopped.

The btnxpuart driver needs this order, to prevent a module unload failure
on system reboot/poweroff.

Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2024-08-30 18:22:37 +02:00
Javier Viguera 9ec3740d51 connectcore-demo: configure board image file for ccimx91
The ccimx91 shares the board image file with the ccimx93.

Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2024-08-26 11:29:12 +02:00
Javier Viguera b162eac234 wayland-protocols, weston: fix compatible machine
Adjust the COMPATIBLE_MACHINE to prevent some warnings when building for
the ccimx91.

Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2024-08-22 17:11:42 +02:00
Hector Palacios b1adc08178 bootcount: fix segfault by checking the funcs are not NULL
Signed-off-by: Hector Palacios <hector.palacios@digi.com>
2024-08-22 08:29:37 +02:00
Hector Palacios aad224ef28 bootcount: add support to ccmp25 platform on external RTC on I2C1
Signed-off-by: Hector Palacios <hector.palacios@digi.com>
2024-08-21 17:37:32 +02:00
Mike Engel 16525cca53 swupdate: enable SWU authentication when Trustfence is enabled
This commit enables SWU image authentication when TrustFence
is enabled instead of when signing of images is enabled.
This allows the system to authenticate SWU images on images that
have been externally signed.

https://onedigi.atlassian.net/browse/DEL-8891

Signed-off-by: Mike Engel <Mike.Engel@digi.com>
2024-08-07 10:03:07 +02:00
Arturo Buzarra 6f15713cc4 dey-image-installer: add USB driver installation script for ccmp2
Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
2024-07-30 22:22:09 +02:00
Francisco Gil d202de613c meta-digi: ccmp2-dvk: update libdigiapix.conf
Signed-off-by: Francisco Gil <francisco.gilmartinez@digi.com>
2024-07-30 10:42:02 +02:00
Francisco Gil 06b37d8c9c libdigiapix: ccimx9: add missing spi entry in libdigiapix.conf
Signed-off-by: Francisco Gil <francisco.gilmartinez@digi.com>
2024-07-30 10:41:58 +02:00
Arturo Buzarra 1d29e40d23 meta-digi: integrate ConnectCore MP25 DVK platform on common recipes
Add initial support on common DEY recipes for ConnectCore MP25 DVK platform.

https://onedigi.atlassian.net/browse/DEL-8995

Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
2024-07-22 17:12:33 +02:00
Hector Palacios 9af1e6c322 bump version to dey-4.0-r7
Signed-off-by: Hector Palacios <hector.palacios@digi.com>
2024-07-19 13:35:30 +02:00
Hector Palacios 22238772ee Merge tag 'dey-4.0-r6.1' into dey-4.0/master
Digi Embedded Yocto 4.0-r6.1

Signed-off-by: Hector Palacios <hector.palacios@digi.com>
2024-07-19 13:35:27 +02:00
Mike Engel d11b291f9a meta-digi: add new CCMX91 platform into DEY
This commits adds the CCMX91 platform to the DEY
build system. Furthermore, it creates generic ccimx9
support to be used for the CCiMX91 and CCiMX93
platform.

https://onedigi.atlassian.net/browse/DEL-9106

Signed-off-by: Isaac Hermida <isaac.hermida@digi.com>
Signed-off-by: Mike Engel <Mike.Engel@digi.com>
2024-07-19 07:32:00 +02:00
Isaac Hermida 0c642ed7ec Update Digi Copyright header
Standarize the Copyright header according to company policy.

Signed-off-by: Isaac Hermida <isaac.hermida@digi.com>
2024-07-15 09:28:58 +02:00
Isaac Hermida d439abd0d4 alsa: do not restore UCM profiles
There is a harmless error when restoring alsa profiles, as it also
attempts to restore UCM profiles.
Since we do not include UCM profiles for our sound cards, skip it.

https://onedigi.atlassian.net/browse/DEL-9066

Signed-off-by: Isaac Hermida <isaac.hermida@digi.com>
2024-07-05 13:02:40 +02:00
Francisco Gil ee26f14423 meta-digi: revert revisions to AUTOREV
Signed-off-by: Francisco Gil <francisco.gilmartinez@digi.com>
2024-07-02 12:06:59 +02:00
Francisco Gil 35cf4d61bc meta-digi: update revisions for dey-4.0-r6.1
Signed-off-by: Francisco Gil <francisco.gilmartinez@digi.com>
2024-07-02 10:19:59 +02:00
Gabriel Valcazar 85e59417a3 recovery: prevent partition encryption when singlemtdsys is enabled
In legacy NAND platforms like the ccimx6ul, it's possible to use a single-MTD
configuration with dualboot disabled, which allows access to the functionality
provided by the recovery partition. However, the partition encryption feature
requires a multi-MTD configuation, so said feature shouldn't be accessible in
this case.

Prevent access to partition encryption in a single-MTD system by:

    * Adding the "system" partition to the partition blacklist in both the
      recovery-utils library and the recovery initscript.
    * Checking the "singlemtdsys" environment variable before using any
      functionality related to partition encryption.

Signed-off-by: Gabriel Valcazar <gabriel.valcazar@digi.com>
2024-07-01 13:27:38 +02:00
Gabriel Valcazar 5695cf15db recovery-initramfs-init: fix "update" volume wipe when singlemtdsys is enabled
Currently, when wiping the update volume via the recovery partition on a
ccimx6ul with singlemtdsys enabled, the procedure fails with this error:

    [RECOVERY] Starting recovery...
    [RECOVERY] Wipe 'update' partition requested
    [RECOVERY] Formatting 'update' ubi volume
    ubi0 error: ubi_open_volume.part.0: cannot open device 0, volume 3, error -16
    ubiupdatevol: error!: cannot open "/dev/ubi0_3"
                  error 16 (Device or resource busy)

This is because the logic used to unmount a volume before formatting it is
expecting this entry format when running "mount":

    ubi0:update on /mnt/update type ubifs

While this is the format of the "mount" output in userspace for the rootfs
volume, other trivial volumes have this format instead:

    ubi0_3 on /mnt/update type ubifs

Adapt the logic to this format so that the "update" volume wipe procedure can
take place.

Signed-off-by: Gabriel Valcazar <gabriel.valcazar@digi.com>
2024-06-28 13:07:11 +02:00
Javier Viguera 17658bdffa Merge branch 'dey-4.0/master' into dey-4.0/maint
Merges Trustfence file-based encryption support.

Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2024-06-28 12:14:26 +02:00
Mike Engel 8a2a1beb08 fscrypt: include trustfence-fscrypt tool into rootfs
Add also 'e2fsprogs-tune2fs' to the image, as busybox's version of
tune2fs command does not support setting the "encrypt" feature of the
EXT4 filesystem.

Signed-off-by: Mike Engel <Mike.Engel@digi.com>
Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2024-06-27 15:39:49 +02:00
Javier Viguera 18c0c69314 Merge branch 'dey-4.0/master' into dey-4.0/maint
Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2024-06-21 14:44:59 +02:00
Javier Viguera 0e23efb9b1 trustfence: add variables for file-based encryption
On new platforms, trustfence will use file-based encryption instead of
full-disk encryption. Add base variables and platform defaults to allow
implementing file-based encryption.

Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2024-06-18 14:19:21 +02:00
Javier Viguera 11ee0251d0 trustfence: ccimx93: disable boot artifacts encryption by default
Encrypting boot artifacts impacts the device's boot time, so disable them
by default. It is still possible to enable it in the project's config
file by setting the TRUSTFENCE_DEK_PATH option.

Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2024-06-18 14:03:16 +02:00
Javier Viguera 970c0cac50 trustfence: ccimx93: implement missing secure console functionality
Unlike the rest of the NXP platforms, in u-boot, the ccimx93 allows
configuring a GPIO name to activate the console when secure console is
enabled. Those u-boot options were not translated to the trustfence code
in meta-digi.

https://onedigi.atlassian.net/browse/DEL-9063

Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2024-06-14 17:51:33 +02:00
Mike Engel 37f5db42ac tsn: add basic Time sensitive networking (TSN)
This commit adds some basic TSN support to DEY.
It includes the kernel configuration fragment with
the IEEE 802.1 support and the some user space tools
necessary to configure the network.

https://onedigi.atlassian.net/browse/DEL-9026

Signed-off-by: Mike Engel <Mike.Engel@digi.com>
2024-06-04 12:14:18 +02:00
Javier Viguera 584b263614 meta-digi: enable u-boot env encryption support on ccimx93
https://onedigi.atlassian.net/browse/DUB-1079

Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2024-05-28 17:58:01 +02:00
Mike Engel 932c186225 packagegroups: add packages related to RT
This commit adds real time test tools to the system.

The hwlatedetct is a program that controls the kernel
hardware latency detector module. This is used to detect
large system latencies independent of Linux itself.

The rt-tests package is a test suite that includes the cyclictest
tool to measure the difference between a thread's intended
wake-up time and the time at which it actually wakes up.

Signed-off-by: Mike Engel <Mike.Engel@digi.com>
2024-04-29 16:13:49 +02:00
Javier Viguera afde974a17 packagegroup-imx-ml: ccimx93: only install tensorflow-lite
Rework commit c5c9838e54 to only limit ML
packages for our ccimx93 and not for other imx93-based devices.

Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2024-04-18 10:49:23 +02:00
Arturo Buzarra dfda74348e trustfence: stm: fix TRUSTFENCE_PASSWORD_FILE initialization for ccmp13 platform
Trustfence class was setting the TRUSTFENCE_PASSWORD_FILE variable using the
old keys format where a unique key_pass.txt file contains all the key
passwords.  However, in the new format there are one key_pass file for each
key, so using a PKI tree with the new format throws an unexpected error in the
FIP generation due to it is not able to find the required key password.
This commit sets the TRUSTFENCE_PASSWORD_FILE variable for the ccmp1 platforms
on different way.

Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
2024-04-15 09:15:12 +02:00
Javier Viguera 3c26ef78e0 meta-digi: enable boot artifacts encryption support on ccimx93
Add a check on the existence of the "temp-fitimg-loaded" environment
variable before setting it. It is needed, as with encrypted FIT images,
we need to decrypt them before accessing the boot script. In such cases,
u-boot sets that variable to "no" so the boot script does not override it,
and the FIT image is loaded again before the final boot to the OS.

https://onedigi.atlassian.net/browse/DEL-8945

Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2024-04-11 18:18:13 +02:00
Isaac Hermida b84de064c0 ccimx93: tensorflow-lite-ethosu-delegate: fix hang issue with multiple tflite context
This patch fixes the hang issue with EiQ demos using multiple tflite files,
for instance the gesture_detection demo.

https://onedigi.atlassian.net/browse/DEL-8949

Signed-off-by: Isaac Hermida <isaac.hermida@digi.com>
2024-04-08 18:00:53 +02:00
Isaac Hermida b00e341495 meta-digi: remove python3-scipy
This recipe is not supported anymore. If you need to add that package
for aarch64, a solution is include pip3 in your image and install it
using the pip3 install manager.

Signed-off-by: Isaac Hermida <isaac.hermida@digi.com>
2024-04-08 17:57:19 +02:00
Arturo Buzarra 2c4e1f85fd trustfence: stm: fix TRUSTFENCE_PASSWORD_FILE initialization for ccmp13 platform
Trustfence class was setting the TRUSTFENCE_PASSWORD_FILE variable using the
old keys format where a unique key_pass.txt file contains all the key
passwords.  However, in the new format there are one key_pass file for each
key, so using a PKI tree with the new format throws an unexpected error in the
FIP generation due to it is not able to find the required key password.
This commit sets the TRUSTFENCE_PASSWORD_FILE variable for the ccmp1 platforms
on different way.

Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
2024-03-26 13:06:51 +01:00
Gabriel Valcazar 3fc0a30115 trustfence: rename variables related to FIT image signing
Different mechanisms are used to sign FIT images on the ccmp1 platforms and the
ccimx93, and we manage each mechanism via a different variable. The variable
names don't really reflect which platform they affect, which makes maintenance
harder.

Rename the variables so that it's easier to identify the platforms/vendors they
affect:

    * Replace TRUSTFENCE_FIT_IMG with TRUSTFENCE_SIGN_FIT_STM
    * Replace TRUSTFENCE_SIGN_FIT_ARTIFACT with TRUSTFENCE_SIGN_FIT_NXP

Don't rename TRUSTFENCE_FIT_IMG_SIGN_KEYNAME

Signed-off-by: Gabriel Valcazar <gabriel.valcazar@digi.com>
2024-03-19 13:26:47 +01:00
Gabriel Valcazar 72675e510c ccmp1: decouple FIT functionality from signed FIT functionality
We rely on FIT support to implement boot artifact authentication on ccmp1
platforms, but our implementation made it impossible to enable FIT support
outside of the context of Trustfence/secure boot.

Change this so that it's possible to enable FIT support without having to sign
the FIT artifacts. Also, modify the linux-dey 5.15 recipe so that the U-Boot
DTBs with signatures get copied only when FIT signing is enabled.

https://onedigi.atlassian.net/browse/DEL-8946

Signed-off-by: Gabriel Valcazar <gabriel.valcazar@digi.com>
2024-03-19 13:26:47 +01:00
Arturo Buzarra ecd77dece9 firmware-murata: update firmware binaries to version imx-kirkstone-hedorah_r1.0
This commit updates the required firmware binaries for Bluetooth and Wireless
interfaces, hostapd and wpa_supplicant recipes based on the Cypress Linux WiFi
Driver (FMAC) release v5.15.58-2023_1128 (Wireless firmware v13.10.246.334).
This change also includes a custom defconfig file for the hostapd and
wpa_supplicant recipes including the changes from the patches and the Digi
customizations.

Also are updated the Murata firmware repositories to match with the latest
Murata release imx-kirkstone-hedorah_r1.0, which is based in the same Cypress
Linux Wifi Driver release v5.15.58-2023_1128.

https://onedigi.atlassian.net/browse/DEL-8667

Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
2024-03-18 18:13:09 +01:00
Javier Viguera e6b67b6bf8 meta-digi: trustfence: support signing a FIT boot artifact
And enable it for the ccimx93.

https://onedigi.atlassian.net/browse/DEL-8704

Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2024-03-12 18:13:05 +01:00
Isaac Hermida c5c9838e54 packagegroup-imx-ml: imx93: only install tensorflow-lite
Not installing all the ML packages but just tensorflow-lite saves space.
We are not including onnxruntime and torchvision, which are not supported
by the i.mx93 (see NXP user guide for details).
The ext4.gz size is decreased from 430MB to 217MB.

Signed-off-by: Isaac Hermida <isaac.hermida@digi.com>
2024-02-29 12:58:16 +01:00
Gabriel Valcazar 948e55bde9 swupdate: replace on-the-fly patch with a clearer, equivalent one
The patch we were using comes from the time during dualboot support development
where said feature was selectable at build time. The patch adds a new build
option, giving the impression that it only gets enabled under certain
circumstances, when in reality:

    * The option is never enabled anywhere in our code
    * It's a string option that is treated like a boolean, meaning its
      respective conditional compilation is always getting compiled even when
      disabled

Our current dualboot support is enabled at runtime, so it doesn't make sense to
have a build-time option related to it, especially one that's broken. Replace
the patch with a functionally equivalent one that is less confusing. Also,
remove the related config option from our defconfig.

Signed-off-by: Gabriel Valcazar <gabriel.valcazar@digi.com>
2024-02-27 18:37:36 +01:00
Gabriel Valcazar b2d9d33cf9 swupdate: reduce default log level in runtime config file
The current log level is very verbose and generates way too much output in some
cases, such as a binary diff update. Reduce the default log level to avoid
this.

Signed-off-by: Gabriel Valcazar <gabriel.valcazar@digi.com>
2024-02-27 12:37:27 +01:00
Gabriel Valcazar 8430114f4c swupdate: adapt patches to 2023.12.1
https://onedigi.atlassian.net/browse/DEL-8885

Signed-off-by: Gabriel Valcazar <gabriel.valcazar@digi.com>
2024-02-26 17:18:23 +01:00
Gabriel Valcazar 5457c89a9e Revert "dey.conf: continue using stable versions of swupdate and libubootenv"
Prepare to support the latest versions of these packages

This reverts commit a22d21ab84.

https://onedigi.atlassian.net/browse/DEL-8885
Signed-off-by: Gabriel Valcazar <gabriel.valcazar@digi.com>
2024-02-26 17:17:54 +01:00
Arturo Buzarra 6b5b341a38 psplash: fix bbappend for different distro than "dey"
This commit fixes a build issue using meta-digi layer with a different distro
than "dey". Also simplified the bbappend to avoid creating a custom
do_patch_png() task before do_configure().

Reported-by: Stephan Klatt <skladd@users.noreply.github.com>
Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
2024-02-23 14:27:01 +01:00
Isaac Hermida 5588c30a7b Revert "ccimx93: bluetooth-init: re-initilize the LE support after hci reset"
This reverts commit c5b53c9765.

The HCI reset interface is fixed inside each BT power calibration shell
script, so this workaround is not needed anymore.

https://onedigi.atlassian.net/browse/DEL-8458

Signed-off-by: Isaac Hermida <isaac.hermida@digi.com>
2024-02-21 18:00:34 +01:00
Isaac Hermida c5b53c9765 ccimx93: bluetooth-init: re-initilize the LE support after hci reset
for the IW61x, when the FW is instructed with an hci reset command, the
LE stack is not correctly reset.
It can be workaround-ed by SW doing a SW power cycle.

Signed-off-by: Isaac Hermida <isaac.hermida@digi.com>
2024-02-19 09:01:45 +01:00
Isaac Hermida f44ae189e5 bluetooth-init: ccimx93: adjust power levels
https://onedigi.atlassian.net/browse/DEL-8327
https://onedigi.atlassian.net/browse/DEL-8458

Signed-off-by: Isaac Hermida <isaac.hermida@digi.com>
2024-02-19 09:01:45 +01:00
Arturo Buzarra 5e1b0ab830 meta-digi-dey: bump distro version to 4.0-r6
Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
2024-02-16 13:06:48 +01:00
Stephan Klatt 637c392cd5 bootcount: fix typo in INITSCRIPT_PARAMS
Add missing curly brace

Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
2024-02-16 13:05:02 +01:00
Arturo Buzarra 52eb698999 Merge tag 'dey-4.0-r5.2' into dey-4.0/master
Digi Embedded Yocto 4.0-r5.2

Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
2024-02-16 12:59:43 +01:00
Stephan Klatt df1a6160ba bootcount: fix typo in INITSCRIPT_PARAMS
Add missing curly brace

Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
2024-02-14 19:19:51 +01:00
Arturo Buzarra e0193228ad meta-digi: revert revisions to AUTOREV
Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
2024-02-06 18:11:28 +01:00
Arturo Buzarra bdf80833dc meta-digi: update revisions for dey-4.0-r5.2
Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
2024-02-06 18:07:48 +01:00
Arturo Buzarra 67fdbb01e8 meta-digi-dey: bump dey build to 4.0-r5.2
Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
2024-02-05 21:46:08 +01:00
Gabriel Valcazar fd35a3149e weston: include NXP patch to enable cursor without having to move the mouse
This is an NXP change that reverts a mainline weston commit form v9.0.0, in
which the mouse cursor only gets activated when there is mouse movement. This
change was only being included in the weston v10.0.X i.MX forks.

For platforms that don't use these weston forks (ccimx93 uses the v11.0.X fork
and ccmp15 uses mainline weston), the mouse cursor doesn't load right away when
booting the system, which causes apps that are automatically launched (such as
the LVGL demo) to not register the mouse, rendering said apps unresponsive to
it.

Port NXP's change to all of the weston versions we currently use to avoid this
problem.

https://onedigi.atlassian.net/browse/DEL-8865

Signed-off-by: Gabriel Valcazar <gabriel.valcazar@digi.com>
2024-02-01 18:34:58 +01:00
Arturo Buzarra 7fb5205e73 meta-digi: revert revisions to AUTOREV
Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
2024-01-30 16:52:26 +01:00
Arturo Buzarra 04a00b2bd0 meta-digi: update revisions for dey-4.0-r5.1
Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
2024-01-30 16:51:33 +01:00
David Escalona a58ce7e254 meta-digi-dey: python3-connectcore-ble: update recipe to v1.0.7
Signed-off-by: David Escalona <david.escalona@digi.com>
2024-01-30 15:40:42 +01:00
Hector Palacios 327d9f3cd3 graphic demos: cc93: fix display and expansion of variable
The display for the cc93 is 'wayland-1'.
Use backslashes before the curly braces to avoid potential expansion by
bitbake variables.

Signed-off-by: Hector Palacios <hector.palacios@digi.com>
2024-01-29 18:53:34 +01:00
Hector Palacios cc295eabe0 lvgl-demo: rename bitbake variables by adding LVGL_ prefix
This is to avoid duplicating names with variable DEMO_DISPLAY inside
the lvgl-demo-init script itself.

Signed-off-by: Hector Palacios <hector.palacios@digi.com>
2024-01-29 18:53:34 +01:00
Javier Viguera dc3eabdba0 trustfence: ccimx93: disable not supported functionality
Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2024-01-26 11:58:04 +01:00
Hector Palacios 68fae1420d packagroup-dey-examples: make recipe compatible with cc93
These are not included on the default image, but allow to
build them for cc93 if requested.

Signed-off-by: Hector Palacios <hector.palacios@digi.com>
2024-01-25 13:59:18 +01:00
Hector Palacios ff22903a81 cc93: standby-actions: rework the programming of resume actions
There are some cases in which the loading of the Wi-Fi modules may be
problematic due to timing conditions:
- when a suspend operation in progress is aborted
- when Bluetooth is disabled

The Wi-Fi needs some time for the system to be ready before loading the
modules.

This commit:
- Stops the Bluetooth before bringing down the Wi-Fi on suspend
- Starts the Bluetooth (or adds a small delay) before bringing up the
  Wi-Fi on resume
- Reworks the way the resume operations are programmed, to do them in
  reverse order (first load the Wi-Fi modules, then bring the interfaces
  up (if required). It does so by appending/prepending actions into a
  variable and dumping the contents finally to a temp file.

Signed-off-by: Hector Palacios <hector.palacios@digi.com>
2024-01-25 13:57:16 +01:00
Gabriel Valcazar b3391941dd connectcore-demo: avoid removal of board image file for the ccimx6qpsbc
Commit c4f2fce4d3 added logic to do_install()
that saves space by removing board image files that don't match the machine
name. However, the ccimx6qpsbc uses the ccimx6sbc board image file, and it was
being removed from the demo, breaking the demo's landing page.

Avoid this by specifying the correct filename for the ccimx6qpsbc.

Signed-off-by: Gabriel Valcazar <gabriel.valcazar@digi.com>
2024-01-25 09:30:13 +01:00
Gabriel Valcazar 568d142b11 ccimx6ul: remove "-x11" suffix from dey-image-lvgl image name
The ccimx6ul is the only platform that doesn't include a desktop backend in the
LVGL image, so remove the desktop backend suffix from the image's name. This
affects the image name itself, the corresponding SWU package and the
installation scripts.

Signed-off-by: Gabriel Valcazar <gabriel.valcazar@digi.com>
2024-01-25 09:30:13 +01:00
Arturo Buzarra cfe613f5e9 lvgl-demo: set touchscreen as default input method for ccimx6ul platform
ccimx6ul platform uses the fbdev backend to run LVGL graphical applications,
the mouse input device is not supported by default on this platform.

Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
2024-01-24 17:16:20 +01:00
Arturo Buzarra 349b263ed9 lvgl-demo: increase default application dimensions for ccimx6ul platform
This commit sets the default LVGL demo dimensions to match with the resolution
of the supported LVDS display, showing the application at fullscreen.

Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
2024-01-24 17:16:20 +01:00
Arturo Buzarra a1f68f94d4 lvgl-demo: add support to initialize LVGL demo at boot
This commit adds a systemd service and a sysvinit script to initialize the LVGL
demo automatically on boot.

Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
2024-01-24 17:12:31 +01:00
Arturo Buzarra a1a176f091 dey-image-lvgl: remove x11 graphical support for ccimx6ul platform
LVGL graphical library has support for different backends, in the case of the
ccimx6ul we use the fbdev directly, so we don't need the x11 support.
This commit removes x11 support for the ccimx6ul platform for the
dey-image-lvgl image.

Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
2024-01-24 17:12:31 +01:00
Gabriel Valcazar dd749650bb lvgl-demo: update to latest revision to fix wayland window glitches
This revision disables LVGL's wayland client-side decorations to prevent visual
glitches on some platforms and homogenize the look of the demo regardless of
platforms/backend.

Signed-off-by: Gabriel Valcazar <gabriel.valcazar@digi.com>
2024-01-19 15:14:49 +01:00
Gabriel Valcazar 87a888d35b weston_11.0.3: restore wl_shell functionality for LVGL demo
This is needed to make the LVGL demo work on the ccimx93, which uses a newer
version of weston that no longer includes wl_shell support. Restore the
wl_shell functionality via a patch and enable it.

https://onedigi.atlassian.net/browse/DEL-8849

Signed-off-by: Gabriel Valcazar <gabriel.valcazar@digi.com>
2024-01-19 15:14:49 +01:00
Arturo Buzarra 62fa660d05 Merge branch 'dey-4.0/master' into dey-4.0/maint
Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
2024-01-19 11:46:55 +01:00
David Escalona 2ecaf1ca55 swupdate: add support to update U-Boot in the redundant partition
The support to update U-Boot in the redundant partition must be enabled in the project
configuration file by setting the variable "SWUPDATE_UBOOTIMG_REDUNDANT" to "true":

SWUPDATE_UBOOTIMG_REDUNDANT = "true"

This feature is only available for the newer platforms: ccmp13, ccmp15 and ccimx93. Trying to
enable it in older platforms will display a warning and fallback to non-redundant update.

Signed-off-by: David Escalona <david.escalona@digi.com>
2024-01-19 10:33:44 +01:00
Javier Viguera 9348d94d22 ccimx93: update multimedia package for NXP release lf-6.1.55-2.2.0
Backport of multimedia package for ccimx93 from NXP's Mickledore-based
lf-6.1.55-2.2.0 release. Mainly copies and appends of multimedia
recipes from the new release, and restricted to ccimx93 by changing the
COMPATIBLE_MACHINE, so it does not affect other platforms.

https://onedigi.atlassian.net/browse/DEL-8840

Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2024-01-18 09:46:32 +01:00
Javier Viguera 5d74f18c2e imx-gst1.0-plugin: restrict patches to ccimx6ul
The JIRA in the patch description describes a problem in the CC6UL, so
do not use the patches on other platforms.

Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2024-01-18 09:46:31 +01:00
Tatiana Leon 721039df6b cccs: add CCCS_CONF_PATH variable to define custom cccs configuration file
If 'CCCS_CONF_PATH' is defined, the specified file is installed as CCCS
configuration file without any modification.
It it is not defined or it is empty, the configuration file in cc_dey
('cc_dey/cccs-daemon/cfg_files/cccs.conf') is installed and modified if
required.

Signed-off-by: Tatiana Leon <Tatiana.Leon@digi.com>
2024-01-17 18:51:56 +01:00
Isaac Hermida efb80f3806 cc93: standby: decople bluetooth from WiFi actions
Do not make conditional the bluetooth actions on WiFi, as they can be
treated independently.

Signed-off-by: Isaac Hermida <isaac.hermida@digi.com>
2024-01-17 10:51:28 +01:00
David Escalona 6d898e51f9 swupdate: rework script to update U-Boot in NAND devices
Rework the script so that it has a similar structure as the MMC leaving it ready
to integrate new platforms.

Signed-off-by: David Escalona <david.escalona@digi.com>
2024-01-16 17:55:17 +01:00
David Escalona e25f3e4f5f swupdate: ccmp1: remove not required 'upgrade_available' U-Boot variable from tempalte
This variable is only required to enable the bootcount feature after an update when the bootcount value is
stored in the environment. This only happens in the CCIMX6 products, so it makes no sense to use it for the
CCMP1 devices.

Signed-off-by: David Escalona <david.escalona@digi.com>
2024-01-16 17:55:17 +01:00
David Escalona 10b22aea64 swupdate: add support to update U-Boot to boot1 partition in mmc devices
While on it, enable support to update encrypted U-Boot for all mmc platforms
supporting it. The install script extracts the DEK blob from the installed
U-Boot and appends it to the new U-Boot before flashing it.

Signed-off-by: David Escalona <david.escalona@digi.com>
2024-01-16 17:55:17 +01:00
David Escalona a0bc831353 meta-digi-arm: machine: add new 'BOOTLOADER_SEEK_BOOTPART' variable to platform configurations
This new variable establishes the number of 1Kb blocks to skip before writing U-Boot in the
bootloader partition.

Signed-off-by: David Escalona <david.escalona@digi.com>
2024-01-16 17:55:17 +01:00
Arturo Buzarra ba1e3b8328 qt5: ccmp1: add support for EGLFS backend
EGLFS is a platform plugin for running single Qt applications in full-screen
mode, without a windowing system like X11 or Wayland.

https://onedigi.atlassian.net/browse/DEL-8802

Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
2024-01-16 13:32:46 +01:00
Francisco Gil 0817a4de93 cccs: dualboot: set by default on the fly to true
To work in a dualboot memory layout out of the box, the most
common use case of the firmware update through the cloud should
be on the fly because in nand platforms there is not enough
memory to keep the update file in the system.

https://onedigi.atlassian.net/browse/DEL-8305

Signed-off-by: Francisco Gil <francisco.gilmartinez@digi.com>
2024-01-15 11:42:35 +01:00
Isaac Hermida 02d1523591 ccimx93: update ML/AI packages for NXP release 6.1.55-2.2.0
As part of the integration of the new ML package, also update the
ethos-u-firmware binary built from Stash:

Repo: emp/ethos_u_firmware.git
Revision: bd5506ddba364ad04602d5009b77077f78450b97
Source: NXP's MCUXpresso SDK_2.14.2_MIMX9352xxxxM

Co-authored-by: Javier Viguera <javier.viguera@digi.com>

Signed-off-by: Isaac Hermida <isaac.hermida@digi.com>
Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2024-01-12 12:09:21 +01:00
Javier Viguera 952edde975 meta-digi: update cmake-native to version 3.25
Backport a new version of cmake-native from Poky's mickledore release. This
is required by the new version of the onnxruntime package (updated in
the following commit).

Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2024-01-12 12:09:21 +01:00
Gabriel Valcazar fdd8026d30 python3-connectcore-ble: update to v1.0.6
Set the PV variable to keep track of the currently used version.

Signed-off-by: Gabriel Valcazar <gabriel.valcazar@digi.com>
2024-01-11 18:14:04 +01:00
Gabriel Valcazar 3305d78ec1 python3-xbee: update to most recent available version
Set the PV variable to keep track of the currently used version.

Signed-off-by: Gabriel Valcazar <gabriel.valcazar@digi.com>
2024-01-11 18:14:04 +01:00
Gabriel Valcazar e954bd1e6d lvgl-demo: build from our github fork instead of patching the original repo
Our fork contains the same patches that were originally applied in this recipe.
This makes it easier for customers to identify the modifications necessary to
get LVGL working on our platforms.

Signed-off-by: Gabriel Valcazar <gabriel.valcazar@digi.com>
2024-01-11 12:14:56 +01:00
Hector Palacios bf1eeabbf5 cc93: standby: add a small delay before resuming Wi-Fi
When switching off the 3.3V supply from the Wi-Fi during suspend,
around a 10% of the times, when resuming the Wi-Fi driver fails to load.

It was verified that a rebind operation over the mmc interface (which
eventually calls the script that loads the Wi-Fi module) makes it
load successfully, which denotes a timing issue during resume.

Adding a small delay on the resume operation before running the script
makes the Wi-Fi driver load at the first try.

Signed-off-by: Hector Palacios <hector.palacios@digi.com>

https://onedigi.atlassian.net/browse/DEL-8821
2024-01-10 13:15:12 +01:00
Javier Viguera 4d8be061f0 ccimx93: update graphics package for NXP release lf-6.1.55-2.2.0
Backport of graphics package for ccimx93 from NXP's Mickledore-based
lf-6.1.55-2.2.0 release. Mainly copies and appends of graphics recipes
from the new release, and restricted to ccimx93 by changing the
COMPATIBLE_MACHINE, so it does not affect other platforms.

Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2024-01-08 16:39:01 +01:00
Gabriel Valcazar 214acb335d trustfence-initramfs: remove openssl-ossl-module-legacy
We removed this package from the recovery initramfs, but it was getting added
as a recommendation to the trustfence initramfs as well.

Signed-off-by: Gabriel Valcazar <gabriel.valcazar@digi.com>
2024-01-05 14:24:17 +01:00
Gabriel Valcazar 4e86570976 cryptsetup: remove udev packageconfig to prevent unwanted packages in intramfs
We use cryptsetup in both the recovery and trustfence initramfs to handle block
device encryption on platforms that use eMMC as the internal storage. In
meta-openembedded commit 1ce71d6ec31195280073adec0e400dda7c0dd8a7 (between
DEY 2.6 and 3.0), a lot of PACKAGECONFIG options were added to the cryptsetup
recipe, all of them enabled by default. One of these options is "udev", which
adds a runtime dependency with udev that in turn pulls in a lot of other
dependencies with it. This is unnecessary because we already use mdev in our
recovery image, and the other packages simply take up space as they aren't
needed at all.

Our eMMC partition encryption functionality, which is the reason why we need
cryptsetup to begin with, is unaffected by this change and still works as
expected. Keep in mind that it was working properly without udev in DEY 2.6 and
older DEY releases, so removing udev isn't an issue.

Remove this PACKAGECONFIG option to get rid of udev and its dependencies in
the recovery and trustfence initramfs.

Signed-off-by: Gabriel Valcazar <gabriel.valcazar@digi.com>
2024-01-05 14:24:17 +01:00
Gabriel Valcazar ba3f3481aa libcap: prevent linking against libpam
In theory, libcap's pam_cap module should use libpam's dlopen runtime linking
mechanism, but starting in libcap 2.53, this changed in order to support
distros that can only link it at build-time. Then, in 2.54, a compile-time
option was added (FORCELINKPAM) to allow users to force the link or not. In the
poky recipe for libcap, this option isn't set, so the library was getting
linked by default, dragging all of its dependencies with it.

For more info: https://bugzilla.kernel.org/show_bug.cgi?id=214023

Set the flag to "no" to avoid linking against libpam, removing its dependency
from the recovery image and saving some space.

Signed-off-by: Gabriel Valcazar <gabriel.valcazar@digi.com>
2024-01-05 14:24:12 +01:00
Hector Palacios efd5f898d8 ccmp1: move definition of TF-A and OP-TEE suffixes to platform
The TF-A and OP-TEE images have different suffixes depending
on whether TrustFence is enabled or not, but the suffix variables
themselves must exist independently of whether TF is enabled.
Currently, they were defined on the trustfence.bbclass, and the
variables did not exist when TF was disabled, which caused build
problems, for example, building the SWU file.

Signed-off-by: Hector Palacios <hector.palacios@digi.com>
2024-01-04 16:56:06 +01:00
Gabriel Valcazar 82a96801de Remove "wipe" from recovery and trustfence initramfs
This package is purely vestigial and hasn't been used at all in any of our
initramfs images for over 7 years. It was used in the first implementation
of the trustfence initramfs (commit 4dd7d438af)
to securely erase the key used by cryptsetup, but two weeks later, that logic
was moved to trustfence-tool (commit a8c50c16ea)
and "wipe" was no longer needed. However, the package remained in the
dependencies of the trustfence initramfs, which were then used as reference for
the recovery initramfs, even though this initramfs didn't even need "wipe" to
begin with.

Removing this package saves 30.8 KiB in the ccimx6ul recovery image.

https://onedigi.atlassian.net/browse/DEL-8819

Signed-off-by: Gabriel Valcazar <gabriel.valcazar@digi.com>
2024-01-04 11:24:20 +01:00
Gabriel Valcazar a0309c2a39 recovery-initramfs: remove openssl-ossl-module-legacy from recovery image
This is added as a recommendation for libcrypto and only contains legacy
ciphers which are deemed outdated or unsafe. If any of the packages in the
image actually required this module, they would depend on it explicitly, but
this isn't the case. This saves 66.8 KiB on the ccimx6ul recovery image.

https://onedigi.atlassian.net/browse/DEL-8819

Signed-off-by: Gabriel Valcazar <gabriel.valcazar@digi.com>
2024-01-04 11:24:20 +01:00
Gabriel Valcazar 215ab5fedf libarchive: remove more unneeded packageconfigs to reduce recovery image size
We depend on libarchive so that swupdate can perform updates with .tar.gz
files, but by default, libarchive is configured to support a lot of additional
features that pull in even more dependencies. This increases the size of the
recovery image, which barely fits on platforms with limited internal storage
like the ccimx6ul. We already removed zstd support to mitigate this, but the
image size increased again after adding imx-kobs to it in commit
aa2480d1de.

Since libarchive isn't used by any other package in our system, remove the
configurations that bloat the recovery image and are not needed at all for
our file update use case. Note that removing the "lzo" packageconfig doesn't
remove its respective library from the image because mtd-utils also depends on
it, but it still reduces the size of libarchive. On the ccimx6ul, this removes
193 KiB worth of libraries and trims libarchive down by 20.5 KiB in the
recovery image.

https://onedigi.atlassian.net/browse/DEL-8819

Signed-off-by: Gabriel Valcazar <gabriel.valcazar@digi.com>
2024-01-04 11:24:20 +01:00
Hector Palacios cef235f61d swu: add sha256 to SWUPDATE_SCRIPT_NAME
These fields were added to default files, but not to the
special sw-description files for ccmp1 and cc6ul platforms.

Signed-off-by: Hector Palacios <hector.palacios@digi.com>
2024-01-03 13:05:05 +01:00
Mike Engel 0cd1c33a7b trustfence: use signed images suffixes for ccmp1 boot artifacts
When TrustFence is enabled, the boot artifacts (TFA and FIP)
have a 'signed' suffix. Handle this case so that the correct
symlinks are created and the correct artifacts are put into the
SWU file.

Signed-off-by: Mike Engel <Mike.Engel@digi.com>
Signed-off-by: Hector Palacios <hector.palacios@digi.com>
2024-01-03 13:05:05 +01:00
Hector Palacios 4f33afcbcf trustfence: split ccmp13 passwords in 8 files and set SWUPDATE keys
For signing SWU files we need to set a couple of variables:
 - SWUPDATE_PRIVATE_KEY_TEMPLATE to the private key file
 - SWUPDATE_PASSWORD_FILE to the password of the private key

The latter must only contain one password, whereas the current key_pass.txt
file had (for the ccmp13) the eight keys separated by a white space.

This commit:
 - If the file key_pass.txt exists, it extracts each key into a separate
   file key_pass0X.txt.
 - If the keys don't exist, generates separate files per key.
 - Changes the permissions of password files to 400.
 - Adapts the sign script to use the single password files.
 - Fixes a few quotes

Signed-off-by: Hector Palacios <hector.palacios@digi.com>
2024-01-03 13:05:05 +01:00
Gabriel Valcazar 32e46e4f9b swupdate: change runtime config file suffix to avoid build-time config errors
We were using the .cfg suffix for both the build-time config fragments and the
runtime configuration file. During do_configure(), all files in SRC_URI ending
in .cfg were being merged together to create the final build configuration,
including said runtime file, which has a completely different syntax. In most
cases, the contents of this file were being ignored, but when tweaking
swupdate's configuration and re-building the package, sometimes strange errors
would prevent the build from finishing.

Change the runtime file's suffix entirely to separate it from the config
fragments and prevent it from being treated as such, and reflect the name
change in the defconfig and the recovery script.

Signed-off-by: Gabriel Valcazar <gabriel.valcazar@digi.com>
2024-01-02 11:14:23 +01:00
Gabriel Valcazar b6c453a8c1 dey.conf: continue using stable versions of swupdate and libubootenv
meta-swupdate recently added support for swupdate 2023.12 and libubootenv
0.3.5. This upgrade conflicts with our custom functionality in both packages,
so keep using 2023.05 and 0.3.2 respectively so DEY 4.0 can be built without
introducing possible functionality changes.

Signed-off-by: Gabriel Valcazar <gabriel.valcazar@digi.com>
2023-12-26 17:32:43 +01:00
Gabriel Valcazar a22d21ab84 dey.conf: continue using stable versions of swupdate and libubootenv
meta-swupdate recently added support for swupdate 2023.12 and libubootenv
0.3.5. This upgrade conflicts with our custom functionality in both packages,
so keep using 2023.05 and 0.3.2 respectively so DEY 4.0 can be built without
introducing possible functionality changes.

Signed-off-by: Gabriel Valcazar <gabriel.valcazar@digi.com>
2023-12-26 17:31:41 +01:00
Gabriel Valcazar 90afd7025c recovery-initramfs: fix multi-MTD detection when formatting NAND partitions
Commit 7e81e706a1 modified the logic used to
determine if a NAND is using multi-MTD or single-MTD, but single quotes were
used in the grep pattern, which prevents the variable inside from expanding.
This makes the script always enter the single-MTD code path, even in multi-MTD
systems, which breaks partition formatting in these cases.

Replace the single quotes with double quotes so the variable can expand and the
condition can be properly checked.

https://onedigi.atlassian.net/browse/DEL-8773

Signed-off-by: Gabriel Valcazar <gabriel.valcazar@digi.com>
2023-12-21 11:21:09 +01:00
Gabriel Valcazar 6468431179 recovery-initramfs: fix multi-MTD detection when formatting NAND partitions
Commit 7e81e706a1 modified the logic used to
determine if a NAND is using multi-MTD or single-MTD, but single quotes were
used in the grep pattern, which prevents the variable inside from expanding.
This makes the script always enter the single-MTD code path, even in multi-MTD
systems, which breaks partition formatting in these cases.

Replace the single quotes with double quotes so the variable can expand and the
condition can be properly checked.

https://onedigi.atlassian.net/browse/DEL-8773

Signed-off-by: Gabriel Valcazar <gabriel.valcazar@digi.com>
2023-12-20 14:57:02 +01:00
Gabriel Valcazar 85a659dd11 Revert "mp1: cmsis-svd: switch from master branch to main branch"
Fixed via commit 311a492c21f0f3643f4b764f8b743c4c6908d31b in meta-st-stm32mp

This reverts commit 09c4645894.

Signed-off-by: Gabriel Valcazar <gabriel.valcazar@digi.com>
2023-12-15 13:50:56 +01:00
Gabriel Valcazar 31e68ff34a Revert "mp1: cmsis-svd: switch from master branch to main branch"
Fixed via commit 311a492c21f0f3643f4b764f8b743c4c6908d31b in meta-st-stm32mp

This reverts commit 09c4645894.

Signed-off-by: Gabriel Valcazar <gabriel.valcazar@digi.com>
2023-12-15 12:15:47 +01:00
Mike Engel aa2480d1de images: add imx-kobs support to recovery image
Signed-off-by: Mike Engel <Mike.Engel@digi.com>
2023-12-05 10:54:29 +01:00
Mike Engel e4bb4d69af swupdate: add u-boot swupdate support
This commit adds u-boot swupdate support for all platforms.
Now u-boot can be updated with all our supported update
options. Currently it will only update first partition
u-boot partition.

https://onedigi.atlassian.net/browse/DEL-8749

Signed-off-by: Mike Engel <Mike.Engel@digi.com>
2023-12-05 10:53:55 +01:00
Hector Palacios fd70bf2fce swupdate: use dynamic mtd-blacklist for configuration file
The 'mtd-blacklist' parameter prevents swupdate from acting upon those
partitions that we consider sensitive.
Make such list platform-dependent.

Signed-off-by: Hector Palacios <hector.palacios@digi.com>
2023-12-01 10:55:05 +01:00
Hector Palacios e9aac1b489 swupdate: install a default config file with optional public-key-file
The swupdate recipe installs by default a systemd service
and a socket to listen for updates coming from a web server.
DEY only makes use of such service during on-the-fly updates from Cloud
Connector web service.

The default swupdate service fails on images with TrustFence because it's
called with no arguments and there doesn't exist a configuration file.
This commit installs a default configuration file and, if TrustFence is
enabled, sets the parameter 'public-key-file' to point to the public
certificate to use to authenticate SWU packages.

While on it, it removes the same file from the recovery-initramfs recipe
that was the only recipe that was adding such config file for recovery
images only.

Signed-off-by: Hector Palacios <hector.palacios@digi.com>
2023-12-01 10:55:05 +01:00
Hector Palacios 32dc939812 trustfence: create a global variable TRUSTFENCE_ENABLED when the class is added
meta-digi layers use many conditionals basing on TRUSTFENCE_SIGN, but this
variable may be disabled when the signing process wants to be isolated
from the image creation.
There are cases when we still need to know if TrustFence is enabled even
if the images are not going to be signed.

Signed-off-by: Hector Palacios <hector.palacios@digi.com>
2023-12-01 10:55:05 +01:00
fgilmar b9b883d47c trustfence: fix trustfence support in NXP platforms
In commit df9b1cf329, the UBOOT_SIGN_ENABLE is set for all
platforms, and should be only added for FIT images.

This is making the process failing in cc8mn/cc8mm platforms
due to the UBOOT_SIGN_ENABLE is also used there to use a dtb
patched with the signature node.

https://onedigi.atlassian.net/browse/DEL-8764

Signed-off-by: Francisco Gil francisco.gilmartinez@digi.com
2023-11-30 14:45:07 +01:00
Gabriel Valcazar 0ae6422742 mp1: cmsis-svd: switch from master branch to main branch
Otherwise, bitbake's git client won't be able to fetch the sources if there are
no mirrors available.

Signed-off-by: Gabriel Valcazar <gabriel.valcazar@digi.com>
2023-11-30 14:22:12 +01:00
Gabriel Valcazar 09c4645894 mp1: cmsis-svd: switch from master branch to main branch
Otherwise, bitbake's git client won't be able to fetch the sources if there are
no mirrors available.

Signed-off-by: Gabriel Valcazar <gabriel.valcazar@digi.com>
2023-11-28 16:31:32 +01:00
Javier Viguera 3cfce77c0f ccimx93: update ML package for NXP release 6.1.36-2.1.0
As part of the integration of the new ML package, also update the
ethos-u-firmware binary built from Stash:

Repo: emp/ethos_u_firmware.git
Revision: a0352b0cf7267c896b55980dedd08daddc780733
Source: NXP's MCUXpresso SDK_2.14.0_MIMX9352xxxxK

And, drop deepview-rt support for ccimx93, as NXP has done the same in
6.1.36-2.1.0 release.

Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2023-11-28 15:51:38 +01:00
Hector Palacios 8f40cddfc6 trustfence: rework configuration for signing FIT images
- Set variables required for FIT signing inside python function, under the
  condition of having TRUSTFENCE_SIGN="1".
- Define two sign keys using TRUSTFENCE_ wrapper constants. Default values:
  - 'fitcfg' for configuration nodes inside the FIT
  - 'fitimg' for image nodes inside the FIT
- Enable FIT_SIGN_INDIVIDUAL to also sign individual images inside the FIT
- Set FIT_GENERATE_KEYS by default (kernel-fitimage.bbclass already checks
  if the keys exist before generating new ones)

Signed-off-by: Hector Palacios <hector.palacios@digi.com>
2023-11-28 12:53:30 +01:00
Gabriel Valcazar c497caca66 lvgl: configure app dimensions in main recipe file instead of lv-drivers.inc
This change isn't functional, but necessary if we want to be able to separate
the logic in the include file and the demo recipe. This way the include file is
agnostic and can be included into other recipes if needed.

Signed-off-by: Gabriel Valcazar <gabriel.valcazar@digi.com>
2023-11-23 17:55:58 +01:00
Gabriel Valcazar d1c5919298 qt5: set default QT_QPA_PLATFORM values for mp1 platforms
Otherwise, launching a Qt5 app will result in errors and the QPA platform will
need to be set manually to get it to work.

Signed-off-by: Gabriel Valcazar <gabriel.valcazar@digi.com>
2023-11-23 11:35:32 +01:00
Gabriel Valcazar 54c9de6a74 qt5: set default QT_QPA_PLATFORM values for mp1 platforms
Otherwise, launching a Qt5 app will result in errors and the QPA platform will
need to be set manually to get it to work.

Signed-off-by: Gabriel Valcazar <gabriel.valcazar@digi.com>
2023-11-22 16:06:07 +01:00
Javier Viguera b48f2806eb ccimx93: update graphics package for NXP release 6.1.36-2.1.0
Backport of graphics package for ccimx93 from NXP's Mickledore-based
6.1.36-2.1.0 release. Mainly copies and appends of graphics recipes
from the new release, and restricted to ccimx93 by changing the
COMPATIBLE_MACHINE, so it does not affect other platforms.

Notice, that the new version of weston used now by the ccimx93 requires
a different profile file (weston-socket.sh). This profile supercedes the
old 'weston.sh'.

Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2023-11-21 18:23:26 +01:00
Javier Viguera 3aee8c39f7 ccimx93: update multimedia package for NXP release 6.1.36-2.1.0
Backport of multimedia package for ccimx93 from NXP's Mickledore-based
6.1.36-2.1.0 release. Mainly copies and appends of multimedia recipes
from the new release, and restricted to ccimx93 by changing the
COMPATIBLE_MACHINE, so it does not affect other platforms.

Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2023-11-21 18:23:26 +01:00
Javier Viguera 5794b18cd2 meson: backport version 1.0.1 from yocto 4.2
This is required to build the new version of gstreamer used by NXP for
the ccimx93 and integrated in following commits.

Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2023-11-21 18:23:26 +01:00
Gabriel Valcazar 2a015f3f87 Add support for dey-image-lvgl images
LVGL is a free and open-source embedded graphics library that is able to run
in environments with limited resources.

This image includes a desktop environment and an LVGL widget demo (lvgl_demo)

https://onedigi.atlassian.net/browse/DEL-8740

Signed-off-by: Gabriel Valcazar <gabriel.valcazar@digi.com>
2023-11-16 11:39:03 +01:00
Gabriel Valcazar c0789c416b lvgl-demo-fb: generalize for any backend and add improvements
Rename the recipe to lvgl-demo to reflect the generalization and select the
most appropriate backend for each platform. Aside from making sure each backend
builds and runs fine, add some usability improvements:

    * Specify the mouse as the default evdev device instead of the touchscreen
    * Use common resolution variables to be able to configure the app's
      dimensions easily

https://onedigi.atlassian.net/browse/DEL-8740

Signed-off-by: Gabriel Valcazar <gabriel.valcazar@digi.com>
2023-11-16 11:38:56 +01:00
Gabriel Valcazar 33a93ccae4 Copy lvgl-demo-fb recipe from meta-openebedded master branch
https://onedigi.atlassian.net/browse/DEL-8740

Signed-off-by: Gabriel Valcazar <gabriel.valcazar@digi.com>
2023-11-14 14:24:46 +01:00
Francisco Gil 66af49ef9e update firmware: some improvements in update firmware script
Signed-off-by: Francisco Gil <francisco.gilmartinez@digi.com>
2023-11-13 17:23:06 +01:00
Mike Engel df9b1cf329 ccmp1: add signed FIT image support
This commit adds signed FIT image support for the CCMP1
platforms when using Trustfence.

https://onedigi.atlassian.net/browse/DEL-8591

Signed-off-by: Mike Engel <Mike.Engel@digi.com>
2023-10-30 12:58:19 +01:00
David Escalona 7bf452e85a swu: enable 'upgrade-available' flag on single systems and file updates
ConnectCore 6 based products require the use of the 'upgrade_available' environment flag to save the
bootcount value between resets. Extend the use of this U-Boot variable for single system updates and
updates based on files.

Signed-off-by: David Escalona <david.escalona@digi.com>
2023-10-20 16:33:27 +02:00
Tatiana Leon cb6b4fe67a cccs: increment the wait time to restart cccs services when they fail to start
This commits sets 30s between restart attempt after a failure.

Signed-off-by: Tatiana Leon <Tatiana.Leon@digi.com>
2023-10-16 12:18:13 +02:00
Arturo Buzarra e2ee631832 meta-digi: [cosmetic] alphabetize compatible machine string
Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
2023-10-10 14:58:58 +02:00
Gabriel Valcazar 3ccbcdec0f packagegroup-qt6-dey: remove qtquick3d-dev
This package was inadvertantly pulling in a lot of dependencies into our
images that make use of Qt6. Most of these packages consisted of *-dev
packages, which are only useful for development with the SDK.

Remove this package along with its dependencies to significantly reduce the
dey-image-qt rootfs image size.

Note that this change was already done in commit
8979331ef8, but it was accidentally reverted when
upgrading to Qt 6.5 in commit a5c6f2b795.

Signed-off-by: Gabriel Valcazar <gabriel.valcazar@digi.com>
(cherry picked from commit 0d6d6d219f)
2023-10-10 13:50:44 +02:00
Gabriel Valcazar 0d6d6d219f packagegroup-qt6-dey: remove qtquick3d-dev
This package was inadvertantly pulling in a lot of dependencies into our
images that make use of Qt6. Most of these packages consisted of *-dev
packages, which are only useful for development with the SDK.

Remove this package along with its dependencies to significantly reduce the
dey-image-qt rootfs image size.

Note that this change was already done in commit
8979331ef8, but it was accidentally reverted when
upgrading to Qt 6.5 in commit a5c6f2b795.

Signed-off-by: Gabriel Valcazar <gabriel.valcazar@digi.com>
2023-10-10 13:23:57 +02:00
Arturo Buzarra 614c7c62c8 meta-digi-dey: bump distro version to 4.0-r5
Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
2023-10-09 15:47:41 +02:00
Tatiana Leon ef1857fac5 connectcore-demo: fix systemd service dependency on connectcore-demo-server.service
This fix systemd error on boot:

[    6.974370] systemd[1]: /lib/systemd/system/connectcore-demo-example.service:3: Failed to add dependency on connectcore-demo-server, ignoring: Invalid argument

Signed-off-by: Tatiana Leon <Tatiana.Leon@digi.com>
2023-10-09 15:36:23 +02:00
Arturo Buzarra 65f7ca3999 Merge tag 'dey-4.0-r4.1' into dey-4.0/master
Digi Embedded Yocto 4.0-r4.1

Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
2023-10-09 15:33:18 +02:00
Tatiana Leon 0d9b393afc connectcore-demo: fix systemd service dependency on connectcore-demo-server.service
This fix systemd error on boot:

[    6.974370] systemd[1]: /lib/systemd/system/connectcore-demo-example.service:3: Failed to add dependency on connectcore-demo-server, ignoring: Invalid argument

Signed-off-by: Tatiana Leon <Tatiana.Leon@digi.com>
2023-09-29 10:50:18 +02:00
Javier Viguera 07525e1c2c trustfence: relax the expression to match AHAB based SRK certs
Current pattern does not match the SRKs generated for the ccimx93. The
ccimx93 does not support subordinated SGK certs, so the name of the SRKs
do not contain the "_ca_" pattern. So relax the expression used in the
trustfence bbclass to match the SRKs generated for both platforms.

  # For the ccimx93
  $ ls -1 crts/SRK1*crt.pem
  crts/SRK1_sha512_secp521r1_v3_usr_crt.pem

  # For the ccimx8x
  $ ls -1 crts/SRK1*crt.pem
  crts/SRK1_sha512_secp521r1_v3_ca_crt.pem

Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2023-09-25 14:23:40 +02:00
Javier Viguera 34e82e9bac trustfence-initramfs: make compatible with ccimx93
Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2023-09-25 14:23:40 +02:00
Javier Viguera f1bdbe74c8 trustfence: decouple signing external artifacts
Some platforms do not support signing external artifacts (kernel, dtb,
etc.) yet, so we need to decouple the signing of the bootloader from the
signing of the external artifacts.

This commit generalizes the code, so instead of having platform exceptions
scattered along the recipes, we create a new variable used conditionally
to sign or not the external artifacts.

Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2023-09-25 14:23:40 +02:00
Isaac Hermida 441164c575 dey-examples: connectcore-demo: restart service on suspend
If the system is send to suspend mode, the bluetooth core is reconfigured.
Therefore, restart the service if it is running, to configure the ble
service.

https://onedigi.atlassian.net/browse/DEL-8694

Signed-off-by: Isaac Hermida <isaac.hermida@digi.com>
2023-09-20 10:43:34 +02:00
Francisco Gil ff071a17be meta-digi: revert revisions to AUTOREV
Signed-off-by: Francisco Gil <francisco.gilmartinez@digi.com>
2023-09-15 16:42:58 +02:00
Francisco Gil c7b6a9d637 meta-digi: update revisions for dey-4.0-r4.1
Signed-off-by: Francisco Gil <francisco.gilmartinez@digi.com>
2023-09-15 16:41:49 +02:00
David Escalona 7001c87e16 dualboot: pass pubkey to swupdate when available
Signed-off-by: David Escalona <david.escalona@digi.com>
2023-09-15 14:46:09 +02:00
Francisco Gil d6a42cf8e5 meta-digi-dey: remove zstd packageconfig to reduce recovery size
Signed-off-by: Francisco Gil <francisco.gilmartinez@digi.com>
2023-09-15 14:46:03 +02:00
David Escalona 600a5f1625 swupdate: fix new SWU package types to be compatible with Trustfence
Signed-off-by: David Escalona <david.escalona@digi.com>
2023-09-14 16:51:57 +02:00
David Escalona 904464c313 trustfence: fix function that copies public key
Bitbake was always copying the public key 1 to the rootfs, no matter what the value specified in
the 'TRUSTFENCE_KEY_INDEX' variable was. This commit fixes the issue by enclosing the variable
between curly braces so that bitbake is able to expand it and calculate the correct key index.

Signed-off-by: David Escalona <david.escalona@digi.com>
2023-09-14 16:50:40 +02:00
Hector Palacios 58b3bdb584 swupdate: restore a full defconfig out of a .config
Commit 429125cce0 created a minimal version 'defconfig'
that doesn't include all the default configuration options
of swupdate.

However, an anonymous python function inside the swupdate
repository establishes dependencies basing on configuration
switches it finds (or not) in the 'defconfig' file and any
additional configuration fragments.
For this reason, a minimal 'defconfig' cannot be used in
this recipe and a full configuration file (that also includes
default options) must be used instead.

Reported-by: Stephan Klatt
Signed-off-by: Hector Palacios <hector.palacios@digi.com>
Signed-off-by: Javier Viguera  <javier.viguera@digi.com>
2023-09-14 14:00:57 +02:00
Francisco Gil 337f3b2ef3 libdigiapix: pwm: correct the name of the pwm dtbo
Signed-off-by: Francisco Gil <francisco.gilmartinez@digi.com>
2023-09-13 12:00:51 +02:00
Francisco Gil 02562fded0 libdigiapix: adc: fix index in configuration file
There was a missmatch between the configuration file and the
correct adc in the ccmp15 platform.

Also a whitespace is removed from ccmp13 configuration file.

https://onedigi.atlassian.net/browse/DEL-8702

Signed-off-by: Francisco Gil <francisco.gilmartinez@digi.com>
2023-09-12 11:32:07 +02:00
Francisco Gil c544b3252a installer: squashfs: add squashfs images to the installer
https://onedigi.atlassian.net/browse/DEL-8638

Signed-off-by: Francisco Gil <francisco.gilmartinez@digi.com>
2023-09-11 08:48:57 +02:00
Arturo Buzarra 386a97590f switch to building from maintenance branches for dey-4.0-r4
Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
2023-09-08 10:33:34 +02:00
Arturo Buzarra 8db6c71a95 Merge branch 'dey-4.0/master' into dey-4.0/maint
Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
2023-09-08 10:33:10 +02:00
Tatiana Leon 2f2f68dc34 dey-examples: cccs: move cccs examples to dey-examples repository
ConnectCore Cloud Services examples are included in 'dey-examples' repository
so they can be built from here and also imported in Eclipse/Digi Application
Development Environment for Linux with the samples wizard.

The example 'upload_file' has been removed since currently there is no support
for binary data points in the CCCS daemon/client model.

https://onedigi.atlassian.net/browse/DEL-8628

Signed-off-by: Tatiana Leon <Tatiana.Leon@digi.com>
2023-09-06 13:02:01 +02:00
Tatiana Leon f13c0e60cf cc: cccs: replace cloudconnector recipe with new ConnectCore Cloud Services
This recipe generates several packages:

   * 'cccs' includes the CCCS shared library
   * 'cccs-daemon' includes the binary and resources to execute the CCCS daemon
     (daemon, service and init scripts, configuration file)
   * 'cccs-cert' includes the required certificate to use CCCS daemon
   * 'cccs-gs-demo' includes the binary and resources to execute the CCCS get
     started demo (binary, service and init scripts)
   * 'cccs-legacy' includes the binary (all-in-one) application to execute
     the legacy CCCS application (aka cloud-connector) and the configuration
     file
   * 'cccs-legacy-dev' includes resources to develop legacy CCCS applications
     (all-in-one) (header files inside 'cloud-connector' and 'cloudconnector.pc'
     pkg config file)
   * 'cccs-legacy-staticdev' includes static resources to develop legacy CCCS
     applications (all-in-one) (static library)

This commit also renames:
   * 'CLOUDCONNECTOR_PKGS' variable to 'CCCS_PKGS'.
   * 'CC_DEVICE_TYPE' variable to 'CCCS_DEVICE_TYPE'.

https://onedigi.atlassian.net/browse/DEL-8628

Signed-off-by: Tatiana Leon <Tatiana.Leon@digi.com>
2023-09-06 13:01:50 +02:00
Javier Viguera a26c96e35f meta-digi-dey: remove not needed STM specific bbappends
Those bbappends are enabling 'examples' PACKAGECONFIG. This is now done
in the distro config file.

https://onedigi.atlassian.net/browse/DEL-8675

Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2023-09-04 10:23:31 +02:00
Javier Viguera a5c6f2b795 meta-digi-dey: upgrade QT6 to version 6.5
QT v6.5 is a long term support (LTS) and is the version used in newer
releases from NXP (based on Yocto 4.2 mickledore)

This commit basically backports the QT v6.5 from meta-freescale community
layer (mickledore) with some recipe's polishing from meta-imx.

https://onedigi.atlassian.net/browse/DEL-8675

Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2023-09-04 10:23:31 +02:00
Francisco Gil 50554f257c swupdate: add configuration file for ccmp1X platforms
Now we can't determine if the rootfs is ubifs/squashfs
in the ccmp1X platforms, so we need to add again the rootfstype
parameter but only for ccmp1X platforms.

Signed-off-by: Francisco Gil <francisco.gilmartinez@digi.com>
2023-09-01 17:17:04 +02:00
Hector Palacios 7e81e706a1 recovery-initramfs: adapt format_ubi_volume() to new partition layout of ccmp1
The ccmp1 has two MTD partitions (UBI, UBI_2) with different system
volumes.
Previously, the fact of having two ubi devices was taken as proof of
being on a multi-MTD system (one that has one UBI volume per partition).
Instead, this commit reformulates the condition to having a partition of
the same name than the UBI volume.

For the case of the ccmp1, add a new for loop to iterate across any number
of UBI devices.

Signed-off-by: Hector Palacios <hector.palacios@digi.com>
2023-09-01 17:16:54 +02:00
Isaac Hermida eba8e21d72 p2p scripts: generalize support getting name from configuration
The P2P interface may have a different name, for instance, in the ccimx93 it
is wfd (wifi direct).
Generalize Digi P2P scripts to use the name from the platform config file.

https://onedigi.atlassian.net/browse/DEL-8468

Signed-off-by: Isaac Hermida <isaac.hermida@digi.com>
2023-09-01 14:55:37 +02:00
Gabriel Valcazar 3641b93750 qt6: add preliminary support for mp1 platforms
Make sure all packagegroups and examples needed for Qt6 support are accesible
to both NXP and STM-based platforms.

https://onedigi.atlassian.net/browse/DEL-8655

Signed-off-by: Gabriel Valcazar <gabriel.valcazar@digi.com>
2023-09-01 11:37:10 +02:00
Arturo Buzarra acd2ee22c1 trustfence: stm: rework PKI tree generation for CCMP15 platforms
PKI tree generation for the STM32MP15 cpu provides the undesired file
"publicKeysHashHashes.bin", which is only required by STM32MP13. This commit
generates the PKI tree according to the KeyGen tool documentation to avoid
generate this extra file and avoid confusing the end user.

Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
2023-08-30 09:53:56 +02:00
David Escalona fd6d797eae meta-digi-dey: swu-images: enable upgrade available feature only for CCIMX6
The CCIMX6 platform is the only one that will keep using the 'bootcount' value stored in the environment.
For this reason, that is the only platform requiring the 'upgrade_available' flag to be set after a
firmware update. For the rest of the platforms, remove it.

https://onedigi.atlassian.net/browse/DEL-8506

Signed-off-by: David Escalona <david.escalona@digi.com>
2023-08-29 14:55:44 +02:00
David Escalona 981c5e44bb meta-digi-dey: core: add 'bootcount' to DEY core package group to reset bootcount on boot
While on it, remove the block of the 'dualboot' script that was taking care of this action.

https://onedigi.atlassian.net/browse/DEL-8506

Signed-off-by: David Escalona <david.escalona@digi.com>
2023-08-29 14:55:44 +02:00
David Escalona 7174a42e87 meta-digi-dey: bootcount: add new binary application to manage the bootcount
Add a user space application to manage the bootcount from the running system. This application
allows to read, reset and set the bootcount:

Usage: bootcount [options]
  -r              --read           Read the current bootcount value (Default action)
  -s <value>      --set=<value>    Set current bootcount to a specific value.
  -x              --reset          Reset bootcount value to zero.

The binary checks the running platform underneath to perform the correct system access.

While on it, add a service to automatically execute the binary on boot to reset the bootcount value.

https://onedigi.atlassian.net/browse/DEL-8506

Signed-off-by: David Escalona <david.escalona@digi.com>
2023-08-29 14:55:44 +02:00
Mike Engel 32078060f7 swu-images: add sha256 entry for script files.
This commit adds sha256 entry for the script files into
the sw-descrition. It is necessary for the Trustfence
authentication to have the included script files signed.

https://onedigi.atlassian.net/browse/DEL-8649

Signed-off-by: Mike Engel <Mike.Engel@digi.com>
2023-08-28 12:34:52 +02:00
Isaac Hermida 6bddaddb2c hostapd: ccimx93: add code for WPA3 strict mode
Signed-off-by: Isaac Hermida <isaac.hermida@digi.com>
2023-08-28 08:22:23 +02:00
Hector Palacios 13e28b293d recovery-initramfs: remove copying of public key
This is now handled by trustfence.bbclass at image level.

Signed-off-by: Hector Palacios <hector.palacios@digi.com>
2023-08-24 11:49:49 +02:00
Hector Palacios 388a3d13d5 trustfence: fix path creation and calling on copy_public_key()
In the context of the class, we must use ${IMAGE_ROOTFS} instead of ${D}.
Change the calling of the function to POSTPROCESS (after the rootfs has
been created) instead of POSTINSTALL (after the packages have been
installed).

Signed-off-by: Hector Palacios <hector.palacios@digi.com>
2023-08-24 11:48:56 +02:00
Francisco Gil c85d064bdd recovery: squashfs: change the way to determine nand device
There is a corner case in the cc6ul where the update from
recovery was failing.

If the u-boot variable rootfstype is set to squashfs u-boot
modify the bootargs adding "root=/dev/ubiblock1_0". The grep
of the command line was failing and detecting the device as
mmc and making the firmware update process fail.

Modify the grep to use the same system that we are using in
the update-firmware script.

Signed-off-by: Francisco Gil <francisco.gilmartinez@digi.com>
2023-08-23 11:04:22 +02:00
Francisco Gil a56790c072 swupdate: get rid of rootfstype u-boot variable
This variable is only needed in the cc6ul, that's the reason
to create another sw-description only for the ccimx6ul.

Signed-off-by: Francisco Gil <francisco.gilmartinez@digi.com>
2023-08-22 16:19:09 +02:00
Hector Palacios 998598415a dey-image: generate public key after rootfs install
When TrustFence is enabled, a PKI tree is generated.
In the case of NXP platforms, the PKI contains public certificates
from which the public key needs to be extracted using an openssl
command.
In the case of STM platforms, the PKI contains directly the
public key.

In all cases, we need the public key to be installed in the
rootfs /etc/ssl/certs/ folder, so that it can be used by
swupdate to authenticate signed SWU packages.
Up to now, this was being done on the dualboot recipe, but the
installation of the public key should really be only dependant
on the fact of TF being enabled.

This commit:
 - Removes the generation of the public key from dualboot.bb.
 - Generates a patch to extract the public key from the certificate
   as part of the PKI tree generation (on NXP platforms).
 - Installs the public key during a post install function after
   the final rootfs has been created.
 - For NXP platforms, extracts the public key using openssl if
   it does not exist (for backwards compatibility).

Signed-off-by: Hector Palacios <hector.palacios@digi.com>
2023-08-21 09:21:30 +02:00
Javier Viguera d5e33fa947 bluez5: bdaddr: support setting MAC address for NXP's iw612
That's the wifi/bt chip used on the ccimx93.

Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2023-08-17 10:23:00 +02:00
Javier Viguera 787bab09d3 busybox: backport hwclock support to get/set RTC parameters
This allows to set RTC configuration parameters. For example, the rv3028
RTC included in ccmp1 and ccimx93 has the "backup switching mode"
configuration in a register that is saved to an eeprom. By default the
BSM value is 00, which means backup switchover disabled. This means that
even if you connect a coin cell to our DVK, the RTC will ignore it.

With this commit, the BSM can be configured to direct switching mode
(DSM) or level switching mode (LSM) so the RTC uses the battery when the
device is powered off.

Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2023-08-17 10:23:00 +02:00
David Escalona f9396581fd meta-digi-dey: swupdate: add firmware update support based on differences for R/O systems
Implement a new mechanism to allow users to create update packages based on differences for read-only
systems. The update mechanism requires full knowledge of the current software running on the device in order
to compute a sensitive patch. For this reason, only systems without user modifications in the rootfs/boot
partitions are eligible for this kind of updates. At the moment, only the 'rootfs' partition supports the
read-only squashfs file system type, so it is the only partition supporting incremental updates. The 'boot'
partition will still be updated but as a full image.

This new feature is done making use of the SWUpdate 'rdiff' handler, which applies binary deltas with the
functionallity provided by the rsync library. During the update process, the contents of the active 'rootfs'
partition are read as the base and written to the inactive 'rootfs' partition applying the delta binary patch
on-the-fly. To ensure the delta file is applied using the correct base, the firmware update process verifies
the contents of the 'rootfs' base partition before applying the update.

The binary delta file is automatically generated by the DEY build system using the resulting 'rootfs' squashfs
image as target and the user specified file as source. The file is then packaged with the rest of components in
the SWU update image. Users must specify the base source file in their project configuration file using the
new variable 'SWUPDATE_RDIFF_ROOTFS_SOURCE_FILE'. Also, 'read-only-rootfs' image feature should be set in the
project to generate this new SWU update package.

Since a base and a target 'rootfs' partition is required during the update, only 'dualboot' systems can benefit
from this new feature.

Note: If variable 'SWUPDATE_RDIFF_ROOTFS_SOURCE_FILE' is configured in the project but any of 'SWUPDATE_FILES_LIST'
      or 'SWUPDATE_FILES_TARGZ_FILE' variables is also set, the build system will prioritize a SWU update package
      based on files instead of a differences package.

https://onedigi.atlassian.net/browse/DEL-8624

Signed-off-by: David Escalona <david.escalona@digi.com>
2023-08-14 10:59:16 +02:00
David Escalona e65be961cd meta-digi-dey: swupdate: reorganize 'swupdate' custom classes and extensions
We expect new types of SWU update packages to be created in the future. To avoid splitting
all the code in different classes based on the update type, create the generic class
'dey-swupdate' to hold all the custom code and the 'dey-swupdate-common' class to hold all
the required variables. This basically renames the old 'swupdate-files' and 'swupdate-files-common'
classes.

While on it, reorganize the 'swupdate-images' recipe to move variable declarations and
functionallity to the correct place:
  - Move all variable declarations to 'swupdate-digi-common' class and organize them in
    functional groups.
  - Improve the way files are included in the 'SWUPDATE_IMAGES' by using the update type
    variables.
  - Move the update script copy to the 'do_swuimage' prepend function. Until now, the copy
    process was executed in the 'fill_description' method, which should only touch the
    'sw-description' file.
  - Rename some variables to use 'SWUPDATE' prefix.
  - Minor cosmetic changes.

https://onedigi.atlassian.net/browse/DEL-8624

Signed-off-by: David Escalona <david.escalona@digi.com>
2023-08-14 10:36:37 +02:00
David Escalona 3bd1541f09 meta-digi-dey: swupdate: add 'UBIVOL_RDIFFHANDLER' support to MTD based systems
Writing directly into UBI volumes is not allowed, so a special 'rdiff' handler capable of
write data in UBI volumes is required. This commits adds the new handler and enables it in
MTD based systems.

https://onedigi.atlassian.net/browse/DEL-8624

Signed-off-by: David Escalona <david.escalona@digi.com>
2023-08-14 10:35:58 +02:00
David Escalona a203487d8f meta-digi-dey: swupdate: add 'RDIFFHANDLER' support to defconfig
The 'RDIFF' handler allows to apply incremental updates using rdiff delta files in the
swu update package. This functionallity is only recommended for read-only file systems,
where the source partition cannot be modified externally by users.

https://onedigi.atlassian.net/browse/DEL-8624

Signed-off-by: David Escalona <david.escalona@digi.com>
2023-08-14 10:35:38 +02:00
Hector Palacios ae327e8dae trustfence: stm: move generation of PKI out of sign script
Create a new script for the generation of PKI tree for STM platforms
and leave the trustfence-sign-artifact script exclusively for signing.
The new gen-pki script only requires the platform as an argument and the
path to where to save the tree (if it doesn't exist) in
CONFIG_SIGN_KEYS_PATH.

This commit also reverts commit 13c136dbc5 by getting rid of the
trustfence-genpki-native.bb recipe and moving back the PKI generation
functions into trustfence.bbclass. This recipe didn't quite guarantee
that the PKI was generated on time for the recipes that required the
keys to exist, anyway.
Instead, the PKI generation function must be called right after
do_compile() of recipe tf-a-stm32mp to be ready for do_deploy() where
the key is used.

Signed-off-by: Hector Palacios <hector.palacios@digi.com>
2023-08-14 09:19:16 +02:00
Isaac Hermida 3bfcc31563 sound: max98088: update card name
Starting at kernel 6.1, the maxim98088 driver has been migrated
from the old imx-max98088.c driver to NXP’s new audio framework
fsl-asoc-card.c.
Update the sound stuff to match the new audio card and some of
the new controls.

https://onedigi.atlassian.net/browse/DEL-8596

Signed-off-by: Isaac Hermida <isaac.hermida@digi.com>
2023-08-08 10:29:16 +02:00
Javier Viguera e2bbc06fea swupdate: fix non-parallel build
Building swupdate with '-j1' fails with:

swupdate$ make -j1
scripts/kconfig/conf  --silentoldconfig Kconfig
  CC      ipc/network_ipc.o
  CC      ipc/network_ipc-if.o
  CC      ipc/progress_ipc.o
  LD      ipc/built-in.o
  LD      libswupdate.so.0.1
Failed:
aarch64-dey-linux/11.3.0/ld: cannot find ipc-static/lib.a: No such file or directory
collect2: error: ld returned 1 exit status

That's due to trying to link a static library that has not been compiled
yet. That dependence seems spurious and we added it in a patch, so
remove it to fix non-parallel builds.

https://onedigi.atlassian.net/browse/DEL-8445

Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2023-08-04 13:10:56 +02:00
Isaac Hermida bc4aaf2237 ccimx93: bluetooth-init: adjust recipes to btnxpuart driver
The btnxpuart driver uses internally the serial port to manage the chip, and
loads the BT FW independently of the WiFi subsystem.
While on it, add support in the bluetooth-init script to be able to power the
chip when the WiFi support is not present.

https://onedigi.atlassian.net/browse/DEL-8632

Signed-off-by: Isaac Hermida <isaac.hermida@digi.com>
2023-08-01 18:54:00 +02:00
Javier Viguera b804a2c8d8 Revert "sdk: dey-image-webkit: fix creation of dey-image-webkit toolchain"
This reverts commit ef84752539.

Fixed upstream:
https://git.yoctoproject.org/poky/commit/?id=80bf4d4f9ad5013851687e7d81bbeda93351d089

Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2023-07-31 13:56:57 +02:00
Mike Engel e1976ca2fb trustfence: add environment encryption
Signed-off-by: Mike Engel <Mike.Engel@digi.com>
2023-07-28 13:29:51 +02:00
Javier Viguera 19373e38f8 systemd: remove console on virtual terminals
This reuses the same variable from sysvinit (USE_VT) to disable running
getty/login on virtual terminals.

Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2023-07-28 12:40:38 +02:00
Javier Viguera f75c78dd8f swu-images: swu.inc: configure directories needed for fill_description
fill_description copies some artifacts to the images deploy directory,
so that should be created beforehand. Otherwise it may fail on the
'do_unpack' task depending on how bitbake schedules the tasks.

Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2023-07-07 18:01:49 +02:00
David Escalona 94d4bbbe9f meta-digi-dey: swupdate-files: add firmware update support based on files
Implement a new mechanism to allow users to create update packages based on files and folders to modify
the active system.

This is done through the new class 'swupdate-files', which creates a tar.gz update file in the image
distribution output directory containing all the files and directories to create/update. The 'tar.gz'
file is used later by the 'swu-images' recipe to generate the final SWUpdate package. The SWU package
installation process extracts the tar.gz file in the root folder ("/") of the active system.

Users can specify the list of files and directories to include in the update package using the
'SWUPDATE_FILES_LIST' variable. These files will be directly copied from the generated system rootfs and
placed in the tar.gz archive. Additionally, users can provide their custom 'tar.gz' file to use in the update
by specifying its location in the 'SWUPDATE_FILES_TARGZ_FILE' variable. In any case, all the paths to include
in the update package must be relative to "/", as it is the base directory where tar.gz file contents are
extracted.

The update process for dual boot systems sets a new u-boot flag so that active bank is not swapped once
installation is complete and system reboots.

The SWU update mechanism based on files provides a custom update script which takes care of preparing the
system for the installation process. Just like in the SWU updates based on images, users can customize this
script or override it with the 'SWUPDATE_SCRIPT' variable, specifying the location of the new script to use.

If both the 'SWUPDATE_FILES_LIST' and 'SWUPDATE_FILES_TARGZ_FILE' variables are empty, a standard images
SWUpdate package will be generated instead.

Signed-off-by: David Escalona <david.escalona@digi.com>
2023-07-06 11:00:05 +02:00
David Escalona e5392996ed meta-digi-dey: swupdate: enable 'ARCHIVE' handler support to directly install 'tar.gz' files
Signed-off-by: David Escalona <david.escalona@digi.com>
2023-07-06 11:00:05 +02:00
David Escalona 429125cce0 meta-digi-dey: swupdate: clean defconfig file
Make the 'defconfig' file a real defconfig by including only differences with respect default
values. While on it, improve the recipe:

  - Enable 'BOOTLOADERHANDLER' by default in the 'defconfig'. We were unconditionally setting
    this value to 'y' in the recipe, so move it to the default configuration.
  - Move 'UBI' configuration values to 'mtd.cfg' file to be added only when device filesystem is
    MTD based. Until now, 'UBI' support was always added by default.
  - Move the 'SIGNED_IMAGES' configuration entry to a '.cfg' file like we are doing with the rest
    of the functionallity. Use 'oe.utils.conditional' checking 'TRUSTFENCE' feature for this.

Signed-off-by: David Escalona <david.escalona@digi.com>
2023-07-06 11:00:05 +02:00
David Escalona 4395fa1f11 meta-digi-dey: swupdate-images: add SWUpdate script support
Enable scripting support during the installation of system images with SWU. A new shell
script is included by default in all the SWU update packages that will be executed just
before the update starts and just after it finishes. The script is empty and contains two
place-holders that will be called in the two scenarios mentioned before.

Users can customize this script to execute specific actions based on their final product
needs or provide their own one by setting its location in the 'SWUPDATE_SCRIPT' variable.

While on it, rename the 'sw-description_template' file to 'sw-description-images_template'
as it is more accurate with the update mechanism it is used for.

Signed-off-by: David Escalona <david.escalona@digi.com>
2023-07-06 11:00:03 +02:00
Francisco Gil 1e5bd003bd recovery-initramfs: get rid off singlemtdsys variable
This variable is not defined in ccmp1 platforms, making the
swupdate for single mtd failing.

Instead of reading this variable from uboot environment,
determine if the system is multimtd checking the existence
of /dev/ubi1.

Signed-off-by: Francisco Gil <francisco.gilmartinez@digi.com>
2023-07-06 08:18:22 +02:00
Francisco Gil 614c457139 update-firmware: squashsf: modify the logic to include the ro systems
In a squashfs the mount points are different and the current logic
wasn't working.

It's more reliable to check the /proc/cmdline to determine if
the system is a nand or an emmc.

Added also logic to get the active partition in nand devices
when the rootfs is squashfs.

https://onedigi.atlassian.net/browse/DEL-8558

Signed-off-by: Francisco Gil <francisco.gilmartinez@digi.com>
2023-07-03 11:30:33 +02:00
Francisco Gil e395d4a98c sw-update: read-only: modify swu descriptor for squashfs rootfs
When a squashfs image is flashed we need to delete the compression
field in the swupdate descriptor.

Also the rootfstype u-boot variable needs to be set to squashfs.

https://onedigi.atlassian.net/browse/DEL-8558

Signed-off-by: Francisco Gil <francisco.gilmartinez@digi.com>
2023-07-03 11:30:27 +02:00
Isaac Hermida 6feaa6e3c0 ccimx93: bluetooth-init: leave the interface up after attaching
Ensure we leave the Bluetooth interface up after attaching it. If not,
under some circumstances, it could be down.

https://onedigi.atlassian.net/browse/DEL-8608

Signed-off-by: Isaac Hermida <isaac.hermida@digi.com>
2023-06-30 11:04:44 +02:00
Isaac Hermida fbb261d4b8 ethos-u-driver-stack: use ethosu_firmware without debug port
The default ethosu_firmware in github reconfigures the uart2 to be used as
debug port. Those pins are used to manage the HW flow control for the Bluetooth
chip.
Build a custom ethosu_firmware that does not reconfigure the uart2 pins.

Compiled from internal "ethos_u_firmware.git" repository on Stash,
with revision 48a4b9e6a0770212aac529fb7f81ed2e6ff51cbd

md5sum: 0bf8686fcabec7378483755106dc6433

https://onedigi.atlassian.net/browse/DEL-8587

Signed-off-by: Isaac Hermida <isaac.hermida@digi.com>
2023-06-28 11:54:16 +02:00
Javier Viguera 54a0d44df3 onnxruntime: update revision and fix rdepends
Backport changes from NXP's lf-6.1.1-1.0.0 release for the ccimx93.

Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2023-06-26 16:20:30 +02:00
Javier Viguera 4992b9934f ethos-u: backport driver, firmware and vela python tool
From NXP's lf-6.1.1-1.0.0 release for the ccimx93.

Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2023-06-26 16:20:28 +02:00
Javier Viguera 9acc53d948 flatbuffers: update to version 2.0.7
Backport from NXP's lf-6.1.1-1.0.0 release for the ccimx93 (meta-ml
layer).

This version of flatbuffers is needed for ethos-u-vela version 3.6.0
(backported in following commit).

Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2023-06-26 16:19:42 +02:00
Isaac Hermida cbe83df69a packagegroup-imx-ml: add missing packages for imx93
These packages are new from NXP's release (lf-6.1.1_1.0.0).

https://onedigi.atlassian.net/browse/DEL-8137
https://onedigi.atlassian.net/browse/DEL-8563

Signed-off-by: Isaac Hermida <isaac.hermida@digi.com>
Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2023-06-26 16:18:23 +02:00
Isaac Hermida 7e1b8bd65d deepview-rt: fix build error when using tensorflow version 2.10
Update binary package to match backported version of tensorflow-lite.

https://onedigi.atlassian.net/browse/DEL-8137
https://onedigi.atlassian.net/browse/DEL-8563

Signed-off-by: Isaac Hermida <isaac.hermida@digi.com>
Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2023-06-26 16:16:33 +02:00
Isaac Hermida 43ea95739a tensorflow-lite: add support for version 2.10
Backport tensorflow-lite recipes from NXP's lf-6.1.1_1.0.0 release (Langdale based)

https://onedigi.atlassian.net/browse/DEL-8137
https://onedigi.atlassian.net/browse/DEL-8563

Signed-off-by: Isaac Hermida <isaac.hermida@digi.com>
Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2023-06-26 14:48:57 +02:00
Isaac Hermida 4f659d2094 eiq-examples: add eiq tools
Backport EIQ examples recipe from NXP's lf-6.1.1_1.0.0 release (Langdale based)

https://onedigi.atlassian.net/browse/DEL-8137
https://onedigi.atlassian.net/browse/DEL-8563

Signed-off-by: Isaac Hermida <isaac.hermida@digi.com>
2023-06-23 08:43:55 +02:00
David Escalona a04af0cbc1 meta-digi-dey: swu-images: simplify sw-description file
The fact of including both storage types (mtd and mmc) in the same 'sw-description' file is not providing any kind
of benefit. Instead, it makes the file larger, complex and harder to maintain. Additionally, most of the images
entries share the same structure and contents, changing only names and mount points. This commit simplifies the
'sw-description' file by configuring the storage type and the images to include in the SWU package at build
time, using a generic 'sw-description' template and template files for 'mmc' and 'mtd' images.

While on it, use the new 'DEY_FIRMWARE_VERSION' variable for SWU package version and fix the recipe to not include
all 'SRC_URI' files in the SWU update image, but only the required files for the update. Also, make use of variable
substitution provided by SWU class in the 'sw-description' file.

Note: SWU U-Boot update will be broken after this change. Waiting for official support with a robust implementation.

https://onedigi.atlassian.net/browse/DEL-8537
https://onedigi.atlassian.net/browse/DEL-8538

Signed-off-by: David Escalona <david.escalona@digi.com>
2023-06-21 18:23:50 +02:00
David Escalona 96af1bd3de meta-digi-dey: dey-image: add new 'sw-versions' file to track system firmware version
https://onedigi.atlassian.net/browse/DEL-8574
https://onedigi.atlassian.net/browse/DEL-8575

Signed-off-by: David Escalona <david.escalona@digi.com>
2023-06-21 18:23:50 +02:00
David Escalona a3bbd8a56f meta-digi-dey: sysinfo: include the new firmware version variable in the 'sysinfo' report
While on it, rename the old "Firmware" variable to "DEY version", as it refers explicity to the DEY
distribution version.

https://onedigi.atlassian.net/browse/DEL-8539

Signed-off-by: David Escalona <david.escalona@digi.com>
2023-06-21 18:23:50 +02:00
David Escalona ce14f12ac5 meta-digi-dey: fw_version: add new variable to store global system firmware version
https://onedigi.atlassian.net/browse/DEL-8539

Signed-off-by: David Escalona <david.escalona@digi.com>
2023-06-21 18:23:50 +02:00
Tatiana Leon 6e30a8127e cloudconnector: set 'MACHINE' as the default device type
If 'CC_DEVICE_TYPE' is not defined or it is empty use 'MACHINE' as the device
type in the Cloud Connector configuration file.

This commit also limits its length to a maximum of 255 characters.

https://onedigi.atlassian.net/browse/DEL-8531

Signed-off-by: Tatiana Leon <Tatiana.Leon@digi.com>
2023-06-21 16:57:27 +02:00
Mike Engel 33bad0022e qtmultimedia: add QT environment variable for camera support
Signed-off-by: Mike Engel <Mike.Engel@digi.com>
2023-06-06 16:06:00 +02:00