Commit Graph

4273 Commits

Author SHA1 Message Date
Tatiana Leon 3912f76f59 ccimx8m: ccmp1: cc6ul: cloudconnector: update store certificates in '/etc/ssl/certs'
Cloud Connector configuration file sets:
  * 'edp12.devicecloud.com' as the URL to connect to (this end point uses client
    certificates)
  * '/mnt/data' as the directory to store downloaded certificates, now that
    this is also available in emmc platforms (see
    62d937df42)

This commit:

  * reverts a0842cbcfd to keep
    'edp12.devicecloud.com' URL that uses certificates for ccimx8m platforms.

  * reverts fd94f10c0b since now the cloud connector
    configuration file sets '/mnt/data' as the place to store downloaded
    certificates, so no need to modify it for ccmp1 platforms.

  * It also configures '/etc/ssl/certs' as the certificates directory for cc6ul
    devices. Although by default, these devices are connecting to
    'remotemanager.digi.com' that not uses certificates, we prefer to use an
    existing directory in that setting. See commit
    063a946e7c.

Signed-off-by: Tatiana Leon <Tatiana.Leon@digi.com>
2023-04-03 14:44:35 +02:00
Tatiana Leon dba8dbdab4 dualboot: change the way to determine if device is using nand or emmc
'environment' partition is not available in the ccmp15.

The solution suggested is read the "/proc/mounts" and check if the 'rootfs' is
'ubifs' mounted.

Related to commits 7c07b15370 and
678eaaf0fc4ce74e67682387e3465eb29659bd47

Signed-off-by: Tatiana Leon <Tatiana.Leon@digi.com>
2023-04-03 14:44:35 +02:00
Tatiana Leon eca521f505 dualboot: update-firmware: get current active system not using U-Boot variable
This commit adds a new function to get the active system in a dualboot device
without using 'active_system' U-Boot variable.
This way the script always knows the real active system even when the variable
'active_system' has the value of the next boot active system, for example, after
performing a 'update-firmware --swap-active-system'.

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

Signed-off-by: Tatiana Leon <Tatiana.Leon@digi.com>
2023-04-03 14:44:35 +02:00
Tatiana Leon ccc4680924 dualboot: update-firmware: new option to swap active system ('--swap-active-system')
This allows to remove the script 'on-the-fly-swap-partition.sh'.

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

Signed-off-by: Tatiana Leon <Tatiana.Leon@digi.com>
2023-04-03 14:44:35 +02:00
Tatiana Leon 1b17e8f657 dualboot: update-firmware: new script option ('-s')
This option combined with '-a' ('--active') only prints the active block: a or b

The purpose an output to be consumed by other scripts or programs.

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

Signed-off-by: Tatiana Leon <Tatiana.Leon@digi.com>
2023-04-03 14:44:35 +02:00
Tatiana Leon 556bda6d57 dualboot: update-firmware: update the check of nand or emmc system
Check the second ('/') and third ('ubifs') field of 'rootfs' entry in
'/proc/mounts' as the first one ('rootfs_a' or 'rootfs_b') may be changed by
custormers:

    root@ccmp15-dvk:~# cat /proc/mounts
    ubi0:rootfs_b / ubifs rw,relatime,assert=read-only,ubi=0,vol=5 0 0
    [...]

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

Signed-off-by: Tatiana Leon <Tatiana.Leon@digi.com>
2023-04-03 14:44:35 +02:00
Tatiana Leon 006138e134 dualboot: update-firmware: rework the script to use functions and avoid repetitions
Signed-off-by: Tatiana Leon <Tatiana.Leon@digi.com>
2023-04-03 14:44:35 +02:00
Tatiana Leon e37d52ebd7 dualboot: update-firmware: add '--no-reboot' option to avoid the reboot of the system
This is required for the firmware update using Digi Remote Manager. The reboot
is commanded by the server, it that does not happen the update process is not
ended for DRM.

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

Signed-off-by: Tatiana Leon <Tatiana.Leon@digi.com>
2023-04-03 14:44:35 +02:00
Tatiana Leon d7f9cfb718 dualboot: update-firmware: add long options to the tool usage
Signed-off-by: Tatiana Leon <Tatiana.Leon@digi.com>
2023-04-03 14:44:35 +02:00
Hector Palacios 40d5207400 update URL of NXP recipes from codeaurora to Github
Codeaurora was retired on April 2023.
Fix bbappends to point to their new location on Github.

Signed-off-by: Hector Palacios <hector.palacios@digi.com>
2023-04-03 11:53:49 +02:00
Arturo Buzarra b00bddb73f meta-digi-dey: bump distro version to 4.0-r3
Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
2023-03-31 11:15:31 +02:00
David Escalona 62d937df42 e2fsprogs: extend recipe to format data partition on first boot for block based devices
Signed-off-by: David Escalona <david.escalona@digi.com>
2023-03-27 17:36:32 +02:00
David Escalona bf88deb602 mount_digiparts.sh: add unit running check for systemd devices
For devices running 'systemd', the mount process is done through 'systemd-mount', which
spawns a system unit. Trying to mount the partition again throws an error stating that a
unit with the same name is already running. To avoid it, check if the unit is already
spawned before mounting the partition and, if so, just restart the unit.

Signed-off-by: David Escalona <david.escalona@digi.com>
2023-03-27 17:36:32 +02:00
Isaac Hermida 060e2f4fe1 ccimx93-dvk.conf: include WiFi and BT features support
https://onedigi.atlassian.net/browse/DEL-8346
2023-03-27 16:34:06 +02:00
Isaac Hermida 66fb6e55c1 ccimx93: iw612: add bluetooth support
The bluetooth FW for the IW612 is loaded together with WiFi FW, so there
is not BT FW file as in our other products.
In order to use the BT, it is a requirement to load the WiFi FW, so
ensure that the service is started after the load of the system
modules.

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

Signed-off-by: Isaac Hermida <isaac.hermida@digi.com>
2023-03-27 16:34:06 +02:00
Isaac Hermida 38831535fb ccimx93: iw612: add WiFi support
https://onedigi.atlassian.net/browse/DEL-8346

Signed-off-by: Isaac Hermida <isaac.hermida@digi.com>
2023-03-27 16:34:06 +02:00
Isaac Hermida 4200b2f06a add nxp-wlan-sdk and kernel-module-nxp-wlan NXP verbatim copies
add a verbatim copy of those recipes as they are provided by nxp in langdale-6.1.1-1.0.0

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

Signed-off-by: Isaac Hermida <isaac.hermida@digi.com>
2023-03-27 12:53:40 +02:00
Hector Palacios a7833a380c README: fix cc6ul supported platforms
- Add missing PNs and order list as per Digi website.
- Remove SBC Express, which is not available for purchase.

Reported-by: Leonid Makhnovskiy <leonid.makhnovskiy@digi.com>
Signed-off-by: Hector Palacios <hector.palacios@digi.com>
(cherry picked from commit 4f1bbf4d2d)
2023-03-23 11:15:35 +01:00
Francisco Gil 800e875397 pulseaudio: keep the PID file in headless system
Without the PIDfile pulseaudio is not reliable.

https://onedigi.atlassian.net/browse/DEL-8429
https://onedigi.atlassian.net/browse/DEL-6795

Signed-off-by: Francisco Gil <francisco.gilmartinez@digi.com>
2023-03-23 07:58:18 +01:00
Hector Palacios 4f1bbf4d2d README: fix cc6ul supported platforms
- Add missing PNs and order list as per Digi website.
- Remove SBC Express, which is not available for purchase.

Reported-by: Leonid Makhnovskiy <leonid.makhnovskiy@digi.com>
Signed-off-by: Hector Palacios <hector.palacios@digi.com>
2023-03-22 17:11:02 +01:00
Javier Viguera c01c394806 meta-digi: rework distro features configuration
Instead of changing POKY_DEFAULT_DISTRO_FEATURES, do the distro features
configuration directly in the DISTRO_FEATURES variable. Also, add a couple
of variables (MACHINE_DISTRO_FEATURES_ADD/REMOVE) that allow machines
for extra tweaking the distro features.

While on it, clean up some distro features:

  - pulseaudio: already added by DISTRO_FEATURES_BACKFILL
  - bluez5, splashscreen, initrd, gplv3: not used (dead code)

Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2023-03-22 11:46:53 +01:00
Isaac Hermida c30b947408 kernel-module-qualcomm: add script to load the wlan module
In rare cases, the wlan module may fail to load. In this scenario, forcing the
MMC driver to rebind the interface resolves the issue, making the WLAN module
load more reliably.
This only affects to modules where the qca chip is connected through the
MMC interface.

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

Signed-off-by: Isaac Hermida <isaac.hermida@digi.com>
2023-03-22 10:46:19 +01:00
Javier Viguera d76bb3ac2c machine: restrict udev extra rules to systemd or udevd device managers
There are other device managers (e.g. mdev) that do not understand those
udev rules, so do not install them unconditionally.

Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2023-03-21 17:05:15 +01:00
Francisco Gil 1560472f66 pulseaudio: keep the PID file in headless system
Without the PIDfile pulseaudio is not reliable.

https://onedigi.atlassian.net/browse/DEL-8429
https://onedigi.atlassian.net/browse/DEL-6795

Signed-off-by: Francisco Gil <francisco.gilmartinez@digi.com>
2023-03-21 15:14:53 +01:00
Hector Palacios 661f59967c trustfence: add function to generate a PKI tree if it doesn't exist
The stand-alone signing script 'trustfence-sign-artifact.sh' checks
if a valid PKI tree exists (by checking the existance of four SRK
files) and if they don't, it calls trustfence-gen-pki.sh (which is
a wrapper over different generators (for HAB or AHAB) to create one.

Recipes such as 'dualboot' or 'recovery-initramfs' may need to call
openssl functions over the PKI tree. These recipes do not currently
generate the PKI tree; they expect it to be already in place.
This might not be the case if the trustfence-sign-artifact.sh script
has not been called yet.

Originally, a fake dependency on virtual/kernel recipe was made to
force it, but it doesn't quite work since the calling only happens
on deploy() while regular DEPENDS doesn't wait for this task.
If the PKI does not exist, a recipe that requires the PKI tree will
fail.

The solution is to create a function on the trustfence.bbclass that
allows any recipe to check for the existance of a PKI tree and
generate it if it doesn't exist. This is repeated inside the
trustfence-sign-artifact.sh, but it needs to be in both places
because this script must work stand-alone.

The generation of the PKI tree takes some seconds so this commit
adds a lock dir to prevent race conditions when called from
different recipes.

It also removes the fake dependency on virtual/kernel and adds a
dependency on trustfence-cst-native (which is the recipe that
provides the PKI generation tool).

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

https://onedigi.atlassian.net/browse/DEL-8430
(cherry picked from commit 6a8bf7afff)
2023-03-21 13:36:58 +01:00
Hector Palacios 6a8bf7afff trustfence: add function to generate a PKI tree if it doesn't exist
The stand-alone signing script 'trustfence-sign-artifact.sh' checks
if a valid PKI tree exists (by checking the existance of four SRK
files) and if they don't, it calls trustfence-gen-pki.sh (which is
a wrapper over different generators (for HAB or AHAB) to create one.

Recipes such as 'dualboot' or 'recovery-initramfs' may need to call
openssl functions over the PKI tree. These recipes do not currently
generate the PKI tree; they expect it to be already in place.
This might not be the case if the trustfence-sign-artifact.sh script
has not been called yet.

Originally, a fake dependency on virtual/kernel recipe was made to
force it, but it doesn't quite work since the calling only happens
on deploy() while regular DEPENDS doesn't wait for this task.
If the PKI does not exist, a recipe that requires the PKI tree will
fail.

The solution is to create a function on the trustfence.bbclass that
allows any recipe to check for the existance of a PKI tree and
generate it if it doesn't exist. This is repeated inside the
trustfence-sign-artifact.sh, but it needs to be in both places
because this script must work stand-alone.

The generation of the PKI tree takes some seconds so this commit
adds a lock dir to prevent race conditions when called from
different recipes.

It also removes the fake dependency on virtual/kernel and adds a
dependency on trustfence-cst-native (which is the recipe that
provides the PKI generation tool).

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

https://onedigi.atlassian.net/browse/DEL-8430
2023-03-21 09:41:36 +01:00
Arturo Buzarra 358dd2a815 build.sh: add dey-image-qt for ccmp15-dvk
ConnectCore MP15 has support to QT applications, so add it to the daily build.

Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
(cherry picked from commit b92028b407)
Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2023-03-20 17:07:39 +01:00
Arturo Buzarra 0a80edeb28 dey-image-installer: remove path from binaries stored inside a folder in the deploy dir
Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
(cherry picked from commit 88251adc0d)
Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2023-03-20 17:07:32 +01:00
Arturo Buzarra a53eaa5b49 systemd-conf: use custom journald conf file
The Poky layer defines a default journald conf file that allows log files on
the file system to grow to a maximum of 64 MiB. However, this size on some
platforms is impossible to address, so this commit reduces the maximum size for
runtime logs to 4 MiB.

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

Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
(cherry picked from commit bdece7102b)
Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2023-03-20 17:07:25 +01:00
Arturo Buzarra abf9dc46bd dey-image-installer: remove path from README file for USB driver installation script
Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
(cherry picked from commit 7ea467dba7)
Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2023-03-20 17:07:19 +01:00
Javier Viguera 4ef4794f20 Merge tag 'dey-4.0-r2.2' into dey-4.0/master
Digi Embedded Yocto 4.0-r2.2

Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2023-03-20 11:05:11 +01:00
Arturo Buzarra b92028b407 build.sh: add dey-image-qt for ccmp15-dvk
ConnectCore MP15 has support to QT applications, so add it to the daily build.

Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
2023-03-17 12:26:56 +01:00
Arturo Buzarra 88251adc0d dey-image-installer: remove path from binaries stored inside a folder in the deploy dir
Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
2023-03-14 09:37:00 +01:00
Arturo Buzarra bdece7102b systemd-conf: use custom journald conf file
The Poky layer defines a default journald conf file that allows log files on
the file system to grow to a maximum of 64 MiB. However, this size on some
platforms is impossible to address, so this commit reduces the maximum size for
runtime logs to 4 MiB.

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

Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
2023-03-13 16:36:06 +01:00
Arturo Buzarra 7ea467dba7 dey-image-installer: remove path from README file for USB driver installation script
Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
2023-03-13 13:11:27 +01:00
Francisco Gil 27414d3420 meta-digi: revert revisions to AUTOREV
Signed-off-by: Francisco Gil <francisco.gilmartinez@digi.com>
2023-03-10 15:48:01 +01:00
Francisco Gil b59f31c114 meta-digi: update revisions for dey-4.0-r2.2
Signed-off-by: Francisco Gil <francisco.gilmartinez@digi.com>
2023-03-10 15:46:34 +01:00
Arturo Buzarra 358a7cc414 meta-digi: revert revisions to AUTOREV
Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
2023-03-08 18:59:27 +01:00
Arturo Buzarra de3ba53ef3 meta-digi: update revisions for dey-4.0-r2.1
Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
2023-03-08 18:58:58 +01:00
Arturo Buzarra a389791bd0 meta-digi: prepare for dey-4.0-r2.1
Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
2023-03-08 15:45:35 +01:00
Tatiana Leon a0842cbcfd ccimx8m: cloudconnector: connect to 'remotemanager.digi.com' not to use certificates
This commit modifies the cloud connector configuration to use
'remotemanager.digi.com' URL since it does not use certificates for the
connection.
'edp12.devicecloud.com' only allows connections with certificates.
The certificate is downloaded during the first device connection to DRM and
stored in '/etc/ssl/certs' directory inside the 'rootfs' partition.
Following connections must use this certificate.

After a firmware update 'rootfs' partition is re-programmed (standard boot)
or changed to use the corresponding partition of the other block (dual boot). In
any case the certificate downloaded is not available anymore, so the device is
not able to reconnect.

Currently there is no a 'immutable' partition to store the certificate, that is,
a place where the certificate is not removed during a firmware update and can
be used by the cloud connector (similar to the 'data' partition on a ccmp1)

Related to commit 063a946e7c.

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

Signed-off-by: Tatiana Leon <Tatiana.Leon@digi.com>
2023-03-08 12:05:52 +01:00
Tatiana Leon ef9e14ab5b pulseaudio: launch pulseaudio in system mode
By launching in system mode it is possible to play music from a shell using
pulseaudio. With change all platforms and images (with or without graphical
support) have pulseaudio working.

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

Signed-off-by: Tatiana Leon <Tatiana.Leon@digi.com>
2023-03-08 12:05:52 +01:00
Arturo Buzarra e7b0a7affc cmp15: apply DT overlay for the DVK v1 on boards without board_version defined
This commit modifies the boot script condition to apply the overlay for DVK v1
on boards without the board_version variable defined.

Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
2023-03-08 10:57:05 +01:00
Hector Palacios ea9a34f205 ccmp15/ccmp13: remove rs232 device tree overlays
These overlays have been removed from the kernel.

Signed-off-by: Hector Palacios <hector.palacios@digi.com>
2023-03-07 18:14:20 +01:00
Arturo Buzarra 0773e31fd4 ccmp15: add DT overlay for the DVK v1
This commit adds an overlay for DVK v1 and modifies the boot script to apply it
based on the board_version variable.

Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
2023-03-07 13:59:29 +01:00
Gonzalo Ruiz 5c5fb956f2 meta-digi: ccmp13: add 'core-image-base' as DEFAULT_IMAGE_NAME
Signed-off-by: Gonzalo Ruiz <Gonzalo.Ruiz@digi.com>
2023-03-07 12:02:28 +01:00
Gonzalo Ruiz 732f8cb0cf u-boot-dey: install fip-b unconditionally in install scripts
Partitions 'fip-a' and 'fip-b' are redundant at the moment. They are
not currently part of the dualboot system. In consequence, program
both partitons unconditionally during the install process.

Signed-off-by: Gonzalo Ruiz <Gonzalo.Ruiz@digi.com>
2023-03-07 12:02:28 +01:00
Arturo Buzarra 739f1b6ab0 build.sh: add dey-image-webkit for ccimx8 platforms
Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
2023-03-06 16:03:38 +01:00
Javier Viguera 14da5bce49 mkproject: disable ccimx93-dvk for this release
Not yet officially supported.

Signed-off-by: Javier Viguera <javier.viguera@digi.com>
2023-03-06 14:04:12 +01:00
Hector Palacios 6477070dfe ccmp15.conf: remove unused ccmp151-dvk device tree
This was thought for a variant that doesn't exist.
The device tree is also obsolete.

Signed-off-by: Hector Palacios <hector.palacios@digi.com>
2023-03-06 13:58:41 +01:00