Skip to content

Commit

Permalink
Merge branch 'lf-edge:master' into master
Browse files Browse the repository at this point in the history
  • Loading branch information
yash-zededa authored Jan 31, 2025
2 parents 34a52d5 + 64a6df4 commit 286f203
Show file tree
Hide file tree
Showing 3,584 changed files with 810,900 additions and 25,323 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
20 changes: 14 additions & 6 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,18 @@ jobs:
strategy:
fail-fast: false
matrix:
os: [buildjet-4vcpu-ubuntu-2204-arm, buildjet-4vcpu-ubuntu-2004]
arch: [arm64, amd64]
platform: [generic, nvidia-jp5, nvidia-jp6]
include:
- os: buildjet-4vcpu-ubuntu-2204-arm
arch: arm64
- os: buildjet-4vcpu-ubuntu-2004
arch: riscv64
platform: generic
exclude:
- os: buildjet-4vcpu-ubuntu-2204-arm
arch: amd64
- os: buildjet-4vcpu-ubuntu-2004
arch: riscv64
platform: arm64
steps:
- name: Starting Report
run: |
Expand Down Expand Up @@ -71,9 +76,9 @@ jobs:
with:
path: ~/.linuxkit/cache
key: linuxkit-${{ matrix.arch }}-${{ github.event.pull_request.head.sha }}
- name: Build packages
- name: Build packages ${{ matrix.os }} for ${{ matrix.platform }}
run: |
make V=1 PRUNE=1 ZARCH=${{ matrix.arch }} pkgs
make V=1 PRUNE=1 PLATFORM=${{ matrix.platform }} ZARCH=${{ matrix.arch }} pkgs
- name: Post package report
run: |
echo Disk usage
Expand Down Expand Up @@ -101,7 +106,10 @@ jobs:
platform: "rt"
- arch: arm64
hv: kvm
platform: "nvidia"
platform: "nvidia-jp5"
- arch: arm64
hv: kvm
platform: "nvidia-jp6"
- arch: arm64
hv: kvm
platform: "imx8mp_pollux"
Expand Down
8 changes: 6 additions & 2 deletions .github/workflows/buildondemand.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
---
name: build and publish packages on demand
on:
on: # yamllint disable-line rule:truthy
workflow_dispatch:
inputs:
force:
Expand Down Expand Up @@ -99,7 +100,10 @@ jobs:
platform: "rt"
- arch: arm64
hv: kvm
platform: "nvidia"
platform: "nvidia-jp5"
- arch: arm64
hv: kvm
platform: "nvidia-jp6"
- arch: arm64
hv: kvm
platform: "imx8mp_pollux"
Expand Down
12 changes: 6 additions & 6 deletions .github/workflows/eden.yml
Original file line number Diff line number Diff line change
Expand Up @@ -113,27 +113,27 @@ jobs:
hv: [kvm]
platform: ["generic"]
if: github.event.review.state == 'approved'
uses: lf-edge/eden/.github/workflows/[email protected].1
uses: lf-edge/eden/.github/workflows/[email protected].2
secrets: inherit
with:
eve_image: "evebuild/pr:${{ github.event.pull_request.number }}"
eve_log_level: "debug"
eve_artifact_name: eve-${{ matrix.hv }}-${{ matrix.arch }}-${{ matrix.platform }}
artifact_run_id: ${{ needs.get_run_id.outputs.run_id }}
eden_version: "1.0.1"
eden_version: "1.0.2"

test_suite_master:
if: github.ref == 'refs/heads/master'
uses: lf-edge/eden/.github/workflows/[email protected].1
uses: lf-edge/eden/.github/workflows/[email protected].2
secrets: inherit
with:
eve_image: "lfedge/eve:snapshot"
eden_version: "1.0.1"
eden_version: "1.0.2"

test_suite_tag:
if: startsWith(github.ref, 'refs/tags')
uses: lf-edge/eden/.github/workflows/[email protected].1
uses: lf-edge/eden/.github/workflows/[email protected].2
secrets: inherit
with:
eve_image: "lfedge/eve:${{ github.ref_name }}"
eden_version: "1.0.1"
eden_version: "1.0.2"
3 changes: 2 additions & 1 deletion .spdxignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@ pkg/installer/src/vendor/
pkg/kube/eve-bridge/vendor/
pkg/measure-config/vendor/
pkg/newlog/vendor/
pkg/nvidia/cdi/
pkg/nvidia/cdi/jp5
pkg/nvidia/cdi/jp6
pkg/pillar/vendor/
pkg/recovertpm/src/vendor/
pkg/rngd/cmd/rngd/vendor/
Expand Down
7 changes: 3 additions & 4 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,6 @@ export ZARCH
CROSS ?=
ifneq ($(HOSTARCH),$(ZARCH))
CROSS = 1
$(warning "WARNING: We are assembling an $(ZARCH) image on $(HOSTARCH). Things may break.")
endif

DOCKER_ARCH_TAG=$(ZARCH)
Expand Down Expand Up @@ -390,10 +389,10 @@ else
#kube container will not be in non-kubevirt builds
PKGS_$(ZARCH)=$(shell find pkg -maxdepth 1 -type d | grep -Ev "eve|alpine|sources|kube|external-boot-image$$")
# nvidia platform requires more space
ifeq ($(PLATFORM),nvidia)
ROOTFS_MAXSIZE_MB=450
else
ifeq (, $(findstring nvidia,$(PLATFORM)))
ROOTFS_MAXSIZE_MB=270
else
ROOTFS_MAXSIZE_MB=450
endif
endif

Expand Down
40 changes: 20 additions & 20 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -285,11 +285,15 @@ Since a full Raspberry Pi 4 support is only available in upstream Linux kernels

Once your Raspberry Pi 4 is happily running an EVE image you can start using EVE controller for further updates (so that you don't ever have to take an SD card out of your board). Build your rootfs by running `make ZARCH=arm64 HV=xen rootfs` (or `make ZARCH=arm64 HV=kvm rootfs` if you want KVM by default) and give resulting `dist/arm64/current/installer/rootfs.img` to the controller.

### How to use on an Onlogic FR201 ARM board
### How to use on an Onlogic FR201 ARM device

Onlogic Factor 201 (FR201) is a device based on the Raspberry Pi Compute Module 4 (CM4). To use EVE on FR201, build an image for Raspberry Pi 4, as described above and flash it on a USB stick. Then, to enable FR201's specific subdevices, the boot configuration has to be manually edited.
Onlogic Factor 201 (FR201) is a device based on the Raspberry Pi Compute Module 4 (CM4). To use EVE on FR201, build a live or installer image for Raspberry Pi 4, as described below and flash it on a USB stick. Then, to enable FR201's specific subdevices, the boot configuration has to be manually edited.

Specifically, in file `config.txt` of the 1st partition of the live/installer image, two lines must be changed, as shown here:
1. To build a live raw image: `make ZARCH=arm64 HV=kvm live-raw` (Only KVM is supported)
1. To build an installation raw image: `make ZARCH=arm64 HV=kvm installer-raw` (Only KVM is supported)
1. Flash the `dist/arm64/current/installer.raw` install EVE image onto an USB Stick [following these instructions](../README.md#3-flash-the-image-to-the-device)

Edit the file `config.txt` of the 1st partition of the live/installer image, two lines must be changed, as shown by the diff syntax below:

```diff
--- config.txt_OLD 2024-10-21 14:01:02.782670479 +0300
Expand All @@ -313,6 +317,17 @@ Specifically, in file `config.txt` of the 1st partition of the live/installer im

Finally, boot or install EVE, using the USB 3.0 port. The installer will install EVE on the eMMC drive, using the NVMe as the persist drive. If an OS is already present on those two drives, see the [documentation](https://support.onlogic.com/documentation/factor/?_gl=1*o7b3gz*_gcl_au*NzI0MzU3NDU5LjE3MjMxMTk0NTQ.*_ga*MTk3NjkxMzg5LjE3MjMxMTk0NDc.*_ga_SEVJD5HQBB*MTcyOTI0NTcwMS4xNC4xLjE3MjkyNDk3MTUuNTguMC4w) from Onlogic on how to erase them and be able to boot from the USB stick.

### FR201 without eMMC

Some variants of the FR201 don't have an internal eMMC. For these devices,
EVE must be installed entirely in the internal NVMe. The following line
must be added to the `grub.cfg` file inside the CONFIG partition of the
installer USB stick:

```sh
set_global dom0_platform_tweaks "eve_install_disk=sdb rootdelay=10"
```

## How to use on an HiKey ARM board

Unlike Raspberry Pi boards, HiKey boards come with a built-in flash, so we will be using EVE's installer to install a copy of EVE onto that storage. You can follow these steps to prepare your installation media:
Expand Down Expand Up @@ -405,24 +420,9 @@ above and executing exactly the same boot command:
Shell> fs0:\EFI\BOOT\BOOTX64.EFI
```

## How to use on a Jetson nano 4GB ARM board

In Jetson nano, from January 22, 2021, it became possible to save the u-boot to an internal qspi chip. Following the instructions from the first point and specifying the kernel and u-boot versions in the same way as in EVE, we can run it on the Jetson nano with 4GB of RAM.

1. Follow steps in [instruction](https://github.com/lf-edge/eve/blob/master/boards/nvidia/jetson/) for flash jetson boot flow partitions to qspi.
2. Make sure you have a clean build directory (since this is a non-standard build) `rm -rf dist/arm64`
3. Build a live image `make ZARCH=arm64 HV=kvm live-raw` (Only KVM is supported)
4. Flash the `dist/arm64/current/live.raw` live EVE image onto your SD card by [following these instructions](#how-to-write-the-eve-image-and-installer-onto-storage-media)

## How to use on a Jetson Xavier NX platform

Currently EVE supports the following devices from NVIDIA's Jetson Xavier NX platform:

1. Lenovo ThinkEdge SE70
2. Siemens SIMATIC IPC520A
3. NVIDIA Jetson Xavier NX developer kit
## How to use on a NVIDIA Jetson based device

See [NVIDIA-NX.md](./docs/NVIDIA-NX.md) for instructions on how to build and deploy EVE on these devices.
Currently EVE supports several NVIDIA Jetson devices, see [NVIDIA.md](./docs/NVIDIA.md) for details.

## How to use on a i.MX 8MQuad Evaluation Kit ARM board

Expand Down
1 change: 1 addition & 0 deletions docs/CONFIG-PROPERTIES.md
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,7 @@
| goroutine.leak.detection.check.window.minutes | integer (minutes) | 10 | Interval in minutes for which the leak analysis is performed. It should contain at least 10 measurements, so no less than 10 × goroutine.leak.detection.check.interval.minutes. |
| goroutine.leak.detection.keep.stats.hours | integer (hours) | 24 | Amount of hours to keep the stats for leak detection. We keep more stats than the check window to be able to react to settings with a bigger check window via configuration. |
| goroutine.leak.detection.cooldown.minutes | integer (minutes) | 5 | Cooldown period in minutes after the leak detection is triggered. During this period, no stack traces are collected; only warning messages are logged. |
| kubevirt.drain.timeout | integer | 24 | hours to allow kubernetes to drain a node |

## Log levels

Expand Down
12 changes: 6 additions & 6 deletions docs/NVIDIA-NX.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@ can be changed in the bootloader's setup interface with the following steps:

### Installing EVE on the ThinkEdge SE70

1. Build an installation raw image `make ZARCH=arm64 HV=kvm PLATFORM=nvidia installer-raw` (Only KVM is supported)
1. Flash the `dist/arm64/current/installer.raw` install EVE image onto an USB Stick [following these instructions](../README.md#how-to-write-eve-image-and-installer-onto-an-sd-card-or-an-installer-medium)
1. Build an installation raw image `make ZARCH=arm64 HV=kvm PLATFORM=nvidia-jp5 installer-raw` (Only KVM is supported)
1. Flash the `dist/arm64/current/installer.raw` install EVE image onto an USB Stick [following these instructions](../README.md#3-flash-the-image-to-the-device)
1. Insert the USB Stick and power on the device

The installation process will start and it will install EVE on the NVMe automatically.
Expand All @@ -43,8 +43,8 @@ If the installation succeed, the device will be powered off. Remove the USB Stic

### Running a live image on the ThinkEdge SE70

1. Build a live raw image `make ZARCH=arm64 HV=kvm PLATFORM=nvidia live-raw` (Only KVM is supported)
1. Flash the `dist/arm64/current/live.raw` live EVE image onto an USB Stick [following these instructions](../README.md#how-to-write-eve-image-and-installer-onto-an-sd-card-or-an-installer-medium)
1. Build a live raw image `make ZARCH=arm64 HV=kvm PLATFORM=nvidia-jp5 live-raw` (Only KVM is supported)
1. Flash the `dist/arm64/current/live.raw` live EVE image onto an USB Stick [following these instructions](../README.md#3-flash-the-image-to-the-device)
1. Insert the USB Stick and power on the device

EVE should boot the live image and run from the USB Stick. **NOTE** that the NVMe SSD must not contain an EVE installation,
Expand Down Expand Up @@ -112,8 +112,8 @@ Once the procedure is done, power off the board and disconnect the pin *FC REC*
### Running a live image on the Jetson Xavier NX developer kit

1. Make sure the bootloader is present in the QSPI EEPROM
1. Build a live raw image `make ZARCH=arm64 HV=kvm PLATFORM=nvidia live-raw` (Only KVM is supported)
1. Flash the `dist/arm64/current/live.raw` live EVE image onto an SD Card [following these instructions](../README.md#how-to-write-eve-image-and-installer-onto-an-sd-card-or-an-installer-medium)
1. Build a live raw image `make ZARCH=arm64 HV=kvm PLATFORM=nvidia-jp5 live-raw` (Only KVM is supported)
1. Flash the `dist/arm64/current/live.raw` live EVE image onto an SD Card [following these instructions](../README.md#3-flash-the-image-to-the-device)
1. Insert the SD Card and power on the board

## References
Expand Down
104 changes: 104 additions & 0 deletions docs/NVIDIA-ORIN.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,104 @@
# NVIDIA's Jetson Orin platform

Currently EVE supports the following devices based on the NVIDIA's Jetson Orin platform:

1. [Aetina AIE-PX22](#aetina-aie-px22)
1. [Aetina AIE-KN32](#aetina-aie-kn32)
1. [Jetson Orin Nano developer kit](#jetson-orin-nano-developer-kit)

The Jetson Orin platform has a complex boot flow[[1]](#references) that performs a lot of operations
to setup all the hardware: initialize memory controller, power up CPUs, load firmware components, etc. The last stage of
the bootloader provides an UEFI interface able to boot an UEFI capable Operating System. The bootloader can be present
in a bootable device, such as an SD Card, or at some internal memory of the device. EVE doesn't support embed the
bootloader on its image for the Jetson Orin platform, so the bootloader must be already present in the device.

## Aetina AIE-PX22

The [Aetina AIE-PX22](https://www.onlogic.com/store/jetagx/) it's a
powerful device based on the Jetson AGX Orin module. EVE supports only the
Jetpack 6.x version for this device. Thus, the bootloader must be
compatible with this version. Detailed instructions on how to update the
device for Jetpack 6 can be found on the following link: [Upgrading to Jetpack 6 on Aetina Jetson Devices](https://github.com/onlogic/Updating-to-Jetpack-6-for-Aetina-Jetson/tree/main)

Once the device has the Jetpack 6 installed (with the bootloader), EVE can
be installed into the device (or run from a live image from an USB Stick).

### Installing EVE on the Aetina AIE-PX22

1. Build an installation raw image `make ZARCH=arm64 HV=kvm PLATFORM=nvidia-jp6 installer-raw` (Only KVM is supported)
1. Flash the `dist/arm64/current/installer.raw` install EVE image onto an USB Stick [following these instructions](../README.md#3-flash-the-image-to-the-device)
1. Insert the USB Stick and power on the device

The installation process will start and it will install EVE on the eMMC and setup the persist storage on the NVMe device automatically.

If the installation succeed, the device will be powered off. Remove the USB Stick and power on the device again.

### Running a live image on the Aetina AIE-PX22

1. Build a live raw image `make ZARCH=arm64 HV=kvm PLATFORM=nvidia-jp6 live-raw` (Only KVM is supported)
1. Flash the `dist/arm64/current/live.raw` live EVE image onto an USB Stick [following these instructions](../README.md#3-flash-the-image-to-the-device)
1. Insert the USB Stick and power on the device

EVE should boot the live image and run from the USB Stick. **NOTE** that the eMMC must not contain an EVE installation,
otherwise it will conflict with the live image and **EVE will not run properly**.

> [!TIP]
> In case the device doesn't boot automatically from the USB stick, you can also boot it
> from the UEFI setup menu by pressing _ESC_ and accessing _Boot Manager_.
## Aetina AIE-KN32

The [Aetina AIE-KN32](https://www.aetina.com/products-detail.php?i=554) it's a device based on the Jetson Orin NX module.
The installation process it's exactly the same applied for the
[Aetina AIE-PX22](#aetina-aie-px22). The only exception is that EVE will be
installed entire in the NVMe SSD disk since it's the only built-in storage
present on the device.

## Jetson Orin Nano developer kit

The Jetson Orin Nano developer kit comes with a CoM (Computer on Module) without eMMC, so the entire OS should run from
an SD Card. However, the device has a small QSPI EEPROM where the bootloader can be written in order to boot the board.

### Flashing the bootloader to QSPI EEPROM

- Put the device into the recovery mode:

1. Power off the board
1. Connect the pin (using a jumper or a wire) **FC REC** to the **GND**. These are the second (GND) and third (FC REC) pins counting from the PWR BTN pin.
1. Attach it to a host computer through the micro USB port.
1. Power on the board

On the host computer, the following device should appear in the USB bus:

```sh
Bus 001 Device 120: ID 0955:7e19 NVIDIA Corp. APX
```

- Download and extract the NVIDIA's Jetpack tarball:

```sh
wget https://developer.nvidia.com/downloads/embedded/l4t/r36_release_v3.0/release/jetson_linux_r36.3.0_aarch64.tbz2
tar -xvjf jetson_linux_r36.3.0_aarch64.tbz2
```

- Execute the flash.sh script tool to flash the bootloader to the QSPI EEPROM:

```sh
cd Linux_for_Tegra
sudo ./flash.sh --no-systemimg -c bootloader/generic/cfg/flash_t234_qspi.xml jetson-orin-nano-devkit mmcblk0p1
```

Once the procedure is done, power off the board and disconnect the pin _FC REC_ from the _GND_.

### Running a live image on the Jetson Xavier NX developer kit

1. Make sure the bootloader is present in the QSPI EEPROM
1. Build a live raw image `make ZARCH=arm64 HV=kvm PLATFORM=nvidia-jp5 live-raw` (Only KVM is supported)
1. Flash the `dist/arm64/current/live.raw` live EVE image onto an SD Card [following these instructions](../README.md#3-flash-the-image-to-the-device)
1. Insert the SD Card and power on the board

## References

1. [Jetson AGX Orin BootFlow](https://docs.nvidia.com/jetson/archives/r35.1/DeveloperGuide/text/AR/BootArchitecture/JetsonAgxOrinBootFlow.html)
1. [Aetina AIE-PX22](https://www.onlogic.com/store/jetagx/)
1. [Aetina AIE-KN32](https://www.aetina.com/products-detail.php?i=554)
Loading

0 comments on commit 286f203

Please sign in to comment.