Skip to content

Commit

Permalink
recipes-core: Remove all Xavier AGX and NX related code
Browse files Browse the repository at this point in the history
These devices are in progress of being released on JP5,
from a different repository: https://github.com/balena-os/balena-jetson-jp5

Signed-off-by: Alexandru Costache <alexandru@balena.io>
  • Loading branch information
acostach committed Jan 6, 2025
1 parent d24c387 commit ed4c85a
Show file tree
Hide file tree
Showing 4 changed files with 0 additions and 171 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,6 @@ PACKAGE_INSTALL:append = " tegra-firmware-xusb"
# the kernel size to allow for host extensions support for now.
#PACKAGE_INSTALL:append:jetson-tx1 = " kernel-module-bcmdhd"
PACKAGE_INSTALL:remove:jetson-tx1 = "tegra-firmware-xusb"
PACKAGE_INSTALL:append:jetson-xavier = " util-linux-blockdev initramfs-module-blockdev"
PACKAGE_INSTALL:append:jetson-xavier-nx-devkit-emmc = " util-linux-blockdev initramfs-module-blockdev"
PACKAGE_INSTALL:append:jetson-xavier-nx-devkit = " util-linux-blockdev initramfs-module-blockdev"

PACKAGE_INSTALL:remove:astro-tx2 = " mdraid"
PACKAGE_INSTALL:remove:blackboard-tx2 = " mdraid"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -73,41 +73,6 @@ device_specific_configuration:jetson-nano-2gb-devkit() {
done
}

# We leave this space way larger than currently
# needed because other larger partitions are
# added from one Jetpack release to another
DEVICE_SPECIFIC_SPACE:jetson-xavier = "458752"

# Binaries are signed and packed into
# a partition and the flaser script
# gets them from there. Can't store them
# raw due to partition alignments which
# trigger checksum mismatches during flash

do_image:balenaos-img:jetson-xavier[depends] += " tegra194-flash-dry:do_deploy"
device_specific_configuration:jetson-xavier() {
partitions=$(cat ${DEPLOY_DIR_IMAGE}/tegra-binaries/partition_specification194.txt)
NVIDIA_PART_OFFSET=20480
START=${NVIDIA_PART_OFFSET}
for n in ${partitions}; do
part_name=$(echo $n | cut -d ':' -f 1)
file_name=$(echo $n | cut -d ':' -f 2)
part_size=$(echo $n | cut -d ':' -f 3)
file_path=$(find ${DEPLOY_DIR_IMAGE}/bootfiles -name $file_name)
END=$(expr ${START} \+ ${part_size} \- 1)
echo "Will write $part_name from ${START} to ${END} part size: $part_size"
parted -s ${BALENA_RAW_IMG} unit B mkpart $part_name ${START} ${END}
# The padding partition exists to allow for the device specific space to
# be a multiple of 4096. We don't write anything to it for the moment.
if [ ! "$file_name" = "none.bin" ]; then
check_size ${file_path} ${part_size}
dd if=$file_path of=${BALENA_RAW_IMG} conv=notrunc seek=$(expr ${START} \/ 512) bs=512
fi
START=$(expr ${END} \+ 1)
done

}

NVIDIA_PART_OFFSET:jetson-tx2="4097"
DEVICE_SPECIFIC_SPACE:jetson-tx2="49152"

Expand Down Expand Up @@ -196,18 +161,3 @@ write_jetson_nx_partitions() {
START=$(expr ${END} \+ 1)
done
}

# We leave this space way larger than currently
# needed because other larger partitions can be
# added from one Jetpack release to another
DEVICE_SPECIFIC_SPACE:jetson-xavier-nx-devkit-emmc = "458752"
do_image:balenaos-img:jetson-xavier-nx-devkit-emmc[depends] += " tegra194-nxde-flash-dry:do_deploy"
device_specific_configuration:jetson-xavier-nx-devkit-emmc() {
write_jetson_nx_partitions "partition_specification194_nxde.txt"
}

DEVICE_SPECIFIC_SPACE:jetson-xavier-nx-devkit = "458752"
do_image:balenaos-img:jetson-xavier-nx-devkit[depends] += " tegra194-nxde-sdcard-flash:do_deploy"
device_specific_configuration:jetson-xavier-nx-devkit() {
write_jetson_nx_partitions "partition_specification194_nxde_sdcard.txt"
}
82 changes: 0 additions & 82 deletions layers/meta-balena-jetson/recipes-core/images/balena-image.inc
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,7 @@ DTBFILE:jn30b-nano = "tegra210-p3448-0002-p3449-0000-b00-jn30b.dtb"
DTBFILE:photon-nano = "tegra210-nano-cti-NGX003.dtb"
DTBFILE:photon-tx2-nx = "tegra186-tx2-nx-cti-NGX003-IMX219-2CAM.dtb"
DTBFILE:floyd-nano="tegra210-p3448-0002-p3449-0000-b00-floyd-nano.dtb"
DTBFILE:photon-xavier-nx = "tegra194-xavier-nx-cti-NGX003.dtb"
DTBFILE:cnx100-xavier-nx = "tegra194-xavier-nx-cnx100.dtb"
DTBNAME:jetson-xavier="tegra194-p2888-0001-p2822-0000"
DTBNAME:jetson-xavier-nx-devkit-seeed-2mic-hat="tegra194-p3668-all-p3509-0000-seeed-2mic-hat"

BALENA_BOOT_PARTITION_FILES:append = " \
dispatcher.d/50-sample-script:/dispatcher.d/50-sample-script \
Expand All @@ -48,54 +45,17 @@ BALENA_BOOT_PARTITION_FILES:append:jetson-nano = " ${NANO_BOOT_PARTITION_FILES}
BALENA_BOOT_PARTITION_FILES:append:jetson-nano-emmc = "${NANO_BOOT_PARTITION_FILES}"
BALENA_BOOT_PARTITION_FILES:append:jetson-nano-2gb-devkit = "${NANO_BOOT_PARTITION_FILES}"


do_rootfs:balenaos-img:jetson-xavier[depends] += " tegra194-flash-dry:do_deploy "

BALENA_BOOT_PARTITION_FILES:append:jetson-xavier = " \
bootfiles/mb1_t194_prod_sigheader.bin.encrypt:/bootfiles/mb1_t194_prod_sigheader.bin.encrypt \
bootfiles/spe_t194_sigheader.bin.encrypt:/bootfiles/spe_t194_sigheader.bin.encrypt \
bootfiles/nvtboot_t194_sigheader.bin.encrypt:/bootfiles/nvtboot_t194_sigheader.bin.encrypt \
bootfiles/preboot_c10_prod_cr_sigheader.bin.encrypt:/bootfiles/preboot_c10_prod_cr_sigheader.bin.encrypt \
bootfiles/slot_metadata.bin:/bootfiles/slot_metadata.bin \
bootfiles/bmp.blob:/bootfiles/bmp.blob \
bootfiles/mce_c10_prod_cr_sigheader.bin.encrypt:/bootfiles/mce_c10_prod_cr_sigheader.bin.encrypt \
bootfiles/mts_c10_prod_cr_sigheader.bin.encrypt:/bootfiles/mts_c10_prod_cr_sigheader.bin.encrypt \
bootfiles/cboot_t194_sigheader.bin.encrypt:/bootfiles/cboot_t194_sigheader.bin.encrypt \
bootfiles/tos-trusty_t194_sigheader.img.encrypt:/bootfiles/tos-trusty_t194_sigheader.img.encrypt \
bootfiles/eks_sigheader.img.encrypt:/bootfiles/eks_sigheader.img.encrypt \
bootfiles/bpmp_t194_sigheader.bin.encrypt:/bootfiles/bpmp_t194_sigheader.bin.encrypt \
bootfiles/tegra194-a02-bpmp-p2888-a04_sigheader.dtb.encrypt:/bootfiles/tegra194-a02-bpmp-p2888-a04_sigheader.dtb.encrypt \
bootfiles/xusb_sil_rel_fw:/bootfiles/xusb_sil_rel_fw \
bootfiles/camera-rtcpu-rce_sigheader.img.encrypt:/bootfiles/camera-rtcpu-rce_sigheader.img.encrypt \
bootfiles/adsp-fw_sigheader.bin.encrypt:/bootfiles/adsp-fw_sigheader.bin.encrypt \
bootfiles/warmboot_t194_prod_sigheader.bin.encrypt:/bootfiles/warmboot_t194_prod_sigheader.bin.encrypt \
bootfiles/${DTBNAME}-rootA_sigheader.dtb.encrypt:/bootfiles/${DTBNAME}-rootA_sigheader.dtb.encrypt \
bootfiles/${DTBNAME}-rootB_sigheader.dtb.encrypt:/bootfiles/${DTBNAME}-rootB_sigheader.dtb.encrypt \
bootfiles/boot0_t194.bin.gz:/bootfiles/boot0_t194.bin.gz \
tegra-binaries/partition_specification194.txt:/bootfiles/partition_specification194.txt \
"

do_rootfs:balenaos-img:jetson-tx2[depends] += " tegra186-flash-dry:do_deploy \
linux-tegra:do_deploy \
"

do_rootfs:balenaos-img:jetson-xavier-nx-devkit-emmc[depends] += " tegra194-nxde-flash-dry:do_deploy "
do_rootfs:balenaos-img:jetson-xavier-nx-devkit[depends] += " tegra194-nxde-sdcard-flash:do_deploy "

# The space resinOS takes will amount to 1GiB
IMAGE_ROOTFS_SIZE = "487424"

# Bootloader blob is 32MB on the NX
IMAGE_ROOTFS_SIZE:jetson-xavier-nx-devkit-emmc = "733184"
IMAGE_ROOTFS_SIZE:jetson-xavier-nx-devkit = "733184"

# Need space for all the above signed update binaries
BALENA_BOOT_SIZE:jetson-nano = "80960"
BALENA_BOOT_SIZE:jetson-nano-2gb-devkit = "80960"
BALENA_BOOT_SIZE:jetson-nano-emmc = "80960"
BALENA_BOOT_SIZE:jetson-xavier = "121440"
BALENA_BOOT_SIZE:jetson-xavier-nx-devkit-emmc = "121440"
BALENA_BOOT_SIZE:jetson-xavier-nx-devkit = "121440"
BALENA_BOOT_SIZE:jetson-tx2="80960"
BALENA_BOOT_SIZE:jetson-tx1="80960"

Expand All @@ -112,48 +72,6 @@ IMAGE_INSTALL:append:jetson-nano = "${IMAGE_PACKAGES_NANO}"
IMAGE_INSTALL:append:jetson-nano-emmc = "${IMAGE_PACKAGES_NANO}"
IMAGE_INSTALL:append:jetson-nano-2gb-devkit = "${IMAGE_PACKAGES_NANO}"

IMAGE_INSTALL:append:jetson-xavier = " \
tegra194-flash-dry \
fan-startup \
parted \
gptfdisk \
tegra-nvpmodel \
tegra-configs-nvstartup \
tegra-configs-udev \
tegra-boot-tools \
"

IMAGE_INSTALL:append:jetson-xavier-nx-devkit-emmc = " \
tegra194-nxde-flash-dry \
parted \
gptfdisk \
tegra-nvpmodel \
tegra-configs-nvstartup \
tegra-configs-udev \
tegra-wifi \
tegra-bluetooth \
tegra-firmware-rtl8822 \
tegra-udrm-probeconf \
mtd-utils \
tegra-boot-tools \
"

IMAGE_INSTALL:append:jetson-xavier-nx-devkit = " \
tegra194-nxde-sdcard-flash \
fan-startup \
parted \
gptfdisk \
tegra-nvpmodel \
tegra-configs-nvstartup \
tegra-configs-udev \
mtd-utils \
tegra-bluetooth \
tegra-wifi \
tegra-firmware-rtl8822 \
tegra-udrm-probeconf \
tegra-boot-tools \
"

IMAGE_INSTALL:append:jetson-tx2 = " \
tegra186-flash-dry \
parted \
Expand Down
Original file line number Diff line number Diff line change
@@ -1,41 +1,5 @@
FILESEXTRAPATHS:prepend := "${THISDIR}/files:"

SRC_URI:append:jetson-xavier = " \
file://blockdev \
"

SRC_URI:append:jetson-xavier-nx-devkit-emmc = " \
file://blockdev \
"

SRC_URI:append:jetson-xavier-nx-devkit = " \
file://blockdev \
"

do_install:append:jetson-xavier() {
install -m 0755 ${WORKDIR}/blockdev ${D}/init.d/02-blockdev
}

do_install:append:jetson-xavier-nx-devkit-emmc() {
install -m 0755 ${WORKDIR}/blockdev ${D}/init.d/02-blockdev
}

do_install:append:jetson-xavier-nx-devkit() {
install -m 0755 ${WORKDIR}/blockdev ${D}/init.d/02-blockdev
}

PACKAGES:append:jetson-xavier = " \
initramfs-module-blockdev \
"

PACKAGES:append:jetson-xavier-nx-devkit-emmc = " \
initramfs-module-blockdev \
"

PACKAGES:append:jetson-xavier-nx-devkit = " \
initramfs-module-blockdev \
"

# Run this script after 01-udev
# to populate /dev with emmc partitions
SUMMARY:initramfs-module-blockdev = "Trigger ioctl to force re-read emmc partitions"
Expand Down

0 comments on commit ed4c85a

Please sign in to comment.