-
Notifications
You must be signed in to change notification settings - Fork 135
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
scarthgap-l4t-r35.x kas build errors #403
base: scarthgap
Are you sure you want to change the base?
Conversation
My newest pull request builds all without errors. However after flashing and booting I do get these errors:
Any idea how to fix this? |
I think it is fixed with my latest commit. data partition is not 42 but 45. Can this configuration be automated or mentioned in the README? |
The remaining problem with this image on Nvidia AGX xavier is the A/B switching does not work properly.
root@jetson-agx-xavier-devkit:~# fw_printenv
ERR: could not identify current boot slot
mender_boot_part=UNKNOWN I can switch to B partition with: fw_setenv mender_boot_part 2
fw_setenv mender_boot_part_hex 2 but I cannot switch back to 1 afterwards. It hangs inside the EFI boot console. Also if I try to install the .mender file via mender this is the log: 2024-09-01 16:13:22.159 +0000 UTC info: Running Mender client 4.0.4
2024-09-01 16:13:22.161 +0000 UTC info: Deployment with ID 4b2fe6fc-82d8-4b53-9d3a-aecb59e9a486 started.
2024-09-01 16:13:22.172 +0000 UTC info: Sending status update to server
2024-09-01 16:13:23.02 +0000 UTC info: Installing artifact...
2024-09-01 16:13:23.196 +0000 UTC info: Update Module output (stderr): ERR: could not identify current boot slot
2024-09-01 16:13:23.199 +0000 UTC info: Update Module output (stderr): /usr/share/mender/modules/v3/rootfs-image: line 96: test: UNKNOWN: integer expression expected
2024-09-01 16:13:23.226 +0000 UTC info: Update Module output (stderr): Mounted root does not match boot loader environment (/dev/mmcblk0p2)!
2024-09-01 16:13:23.227 +0000 UTC error: Process returned non-zero exit status: Download: Update Module returned non-zero status: Process exited with status 1
2024-09-01 16:13:23.255 +0000 UTC info: Sending status update to server Any ideas how to solve this? @zach-welch-aquabyte and/or @TheYoctoJester ? |
Here a log when trying to install a mender yocto update:
|
Hello @TheYoctoJester, can you give a look at this one? |
Hi @tjhgit, unfortunately I don't have a board on which I could test this. The key is probably this line: https://github.com/mendersoftware/mender/blob/f2cc0ddd0c04231ade944c976d960d422116a14f/support/modules/rootfs-image#L141, which checks if the actually mounted root partition matches the expectations. I can imagine that being special on Tegras (big surprise!), so a first pointer might be in the output of the |
@TheYoctoJester the response is as expected for the command you pointed out in the install script: aaeon@aaeon-xavier:~$ mount | grep -F ' on / ' | sed -e 's/ .*//; s,^ubi,/dev/ubi,'
/dev/mmcblk0p2 This is using a yocto-build: root@jetson-agx-xavier-devkit:~# mount | grep -F ' on / ' | sed -e 's/ .*//; s,^ubi,/dev/ubi,'
/dev/mmcblk0p1 I then switch to B boot:
This is what the debug console of the jetson says between the reboot and coming up after several? boots with rootfs B:
root@jetson-agx-xavier-devkit:~# mount | grep -F ' on / ' | sed -e 's/ .*//; s,^ubi,/dev/ubi,'
/dev/mmcblk0p2 When then trying to set: fw_setenv mender_boot_part 1
fw_setenv mender_boot_part_hex 1 It gets stuck in PXE boot, since unable to boot again from A?? See console log: [0000.053] W> RATCHET: MB1 binary ratchet value 4 is larger than ratchet level 2 from HW fuses.
[0000.061] I> MB1 (prd-version: 2.6.0.0-t194-41334769-cab45716)
[0000.066] I> Boot-mode: Coldboot
[0000.069] I> Platform: Silicon
[0000.072] I> Chip revision : A02P
[0000.075] I> Bootrom patch version : 15 (correctly patched)
[0000.080] I> ATE fuse revision : 0x200
[0000.084] I> Ram repair fuse : 0x0
[0000.087] I> Ram Code : 0x2
[0000.089] I> rst_source: 0xb, rst_level: 0x1
[0000.094] I> Boot-device: SDMMC (instance: 3)
[0000.110] I> sdmmc DDR50 mode
[0000.114] I> Boot chain mechanism: A/B
[0000.117] I> Current Boot-Chain Slot: 1
[0000.121] I> BR-BCT Boot-Chain: 1, status: 0. update flag: 0
[0000.128] W> PROD_CONFIG: device prod data is empty in MB1 BCT.
[0000.133] I> Temperature = 27000
[0000.136] W> Skipping boost for clk: BPMP_CPU_NIC
[0000.141] W> Skipping boost for clk: BPMP_APB
[0000.145] W> Skipping boost for clk: AXI_CBB
[0000.149] W> Skipping boost for clk: AON_CPU_NIC
[0000.153] W> Skipping boost for clk: CAN1
[0000.157] W> Skipping boost for clk: CAN2
[0000.161] I> Boot-device: SDMMC (instance: 3)
[0000.172] I> Sdmmc: HS400 mode enabled
[0000.176] I> Non-ECC region[0]: Start:0x80000000, End:0x100000000
[0000.183] W> Thermal config not found in BCT
[0000.191] W> MEMIO rail config not found in BCT
[0000.213] I> sdmmc bdev is already initialized
[0000.258] W> Platform config not found in BCT
[0000.292] I> MB1 done
����main enter
SPE VERSION #: R01.00.18 Created: Jan 29 2021 @ 14:18:27
HW Function test
Start Scheduler.
in late init
��
[0000.301] I> Welcome to MB2(TBoot-BPMP) (version: default.t194-mobile-8e4b789e)
[0000.302] I> DMA Heap @ [0x526fa000 - 0x52ffa000]
[0000.302] I> Default Heap @ [0xd486400 - 0xd48a400]
[0000.303] E> DEVICE_PROD: Invalid value data = 70020000, size = 0.
[0000.309] W> device prod register failed
[0000.313] I> gpio framework initialized
[0000.316] I> tegrabl_gpio_driver_register: register 'nvidia,tegra194-gpio' driver
[0000.324] I> tegrabl_gpio_driver_register: register 'nvidia,tegra194-gpio-aon' driver
[0000.331] I> No valid sdcard_params in mb1_bct
[0000.336] I> Boot_device: SDMMC_BOOT instance: 3
[0000.340] I> sdmmc-3 params source = boot args
[0000.349] I> sdmmc-3 params source = boot args
[0000.350] I> sdmmc bdev is already initialized
[0000.383] I> Found 20 partitions in SDMMC_BOOT (instance 3)
[0000.399] I> Found 45 partitions in SDMMC_USER (instance 3)
[0000.400] I> Active Boot chain : 1
[0000.458] I> Relocating BR-BCT
[0000.460] > DEVICE_PROD: device prod is not initialized.
[0000.485] E> I2C: slave not found in slaves.
[0000.486] E> I2C: Could not write 0 bytes to slave: 0x00ae with repeat start true.
[0000.487] E> I2C_DEV: Failed to send register address 0x00000000.
[0000.488] E> I2C_DEV: Could not read 256 registers of size 1 from slave 0xae at 0x00000000 via instance 0.
[0000.489] E> eeprom: Failed to read I2C slave device
[0000.492] I> Failed to read CVB eeprom data @ AE
[0000.497] I> Retrying CVB eeprom read @ AC ...
[0000.575] I> Relocating OP-TEE dtb from: 0x6bfff720 to 0x70050000, size: 1008
[0000.575] I> [0] START: 0x80000000, SIZE: 0x2f000000
[0000.576] I> [1] START: 0xaf010000, SIZE: 0x189f0000
[0000.576] I> [2] START: 0xc7b00000, SIZE: 0xc0000
[0000.577] I> [3] START: 0xca000000, SIZE: 0x800000
[0000.577] I> dram_block larger than 80000000
[0000.580] I> [4] START: 0x100000000, SIZE: 0x780000000
[0000.591] I> Setting NS memory ranges to OP-TEE dtb finished.
[0000.605] I> found decompressor handler: lz4
[0001.101] I> EKB detected (length: 0x410) @ VA:0x526ff400
[0001.103] I> Setting EKB blob info to OPTEE dtb finished.
��NOTICE: BL31: v2.6(release):l4t-r35.5.0
NOTICE: BL31: Built : 2024-02-20 04:11:16
I/TC: Physical secure memory base 0xcb040000 size 0xf00000
��
bpmp: init
bpmp: tag is 128431eec76692047e1ac1ebc0392266
sku_dt_init: not sku 0x00
clk_early initialized
mail_early initialized
fuse initialized
hwwdt initialized
t194_ec_get_ec_list: found 45 ecs
ec initialized
vmon_setup_monitors: found 3 monitors
vmon initialized
adc initialized
fmon_populate_monitors: found 73 monitors
fmon initialized
mc initialized
reset initialized
nvhs initialized
uphy_early initialized
emc_early initialized
392 clocks registered
clk initialized
io_dpd initialized
thermal initialized
thermal_mrq initialized
i2c initialized
vrmon_dt_init: vrmon node not found
vrmon_chk_boot_state: found 0 rail monitors
vrmon initialized
regulator initialized
��I/TC:
��avfs_clk_platform initialized
����soctherm initialized
aotag initialized
powergate initialized
dvs initialized
pm initialized
suspend initialized
pg_late initialized
pg_mrq_init initialized
strap initialized
nvl initialized
emc initialized
emc_mrq initialized
clk_dt initialized
tj_init initialized
uphy_dt initialized
uphy_mrq initialized
uphy initialized
ec_swd_poll_start: 281 reg polling start w period 47 ms
ec_late initialized
hwwdt_late initialized
reset_mrq initialized
ec_mrq initialized
fmon_mrq initialized
clk_mrq initialized
avfs_mrq initialized
mail_mrq initialized
i2c_mrq initialized
tag_mrq initialized
console_mrq initialized
mrq initialized
clk_sync_fmon_post initialized
��I/TC: Non-secure external DT found
��clk_dt_late initialized
noc_late initialized
pm_post initialized
dbells initialized
dmce initialized
cvc initialized
avfs_clk_mach_post initialized
avfs_clk_platform_post initialized
cvc_late initialized
regulator_post initialized
rm initialized
console_late initialized
clk_dt_post initialized
mc_reg initialized
pg_post initialized
profile initialized
fuse_late initialized
extras_post initialized
bpmp: init complete
entering main console loop
] ��I/TC: OP-TEE version: 3.22 (gcc version 13.3.0 (GCC)) #1 Tue Feb 20 04:38:03 UTC 2024 aarch64
I/TC: WARNING: This OP-TEE configuration might be insecure!
I/TC: WARNING: Please check https://optee.readthedocs.io/en/latest/architecture/porting_guidelines.html
I/TC: Primary CPU initializing
I/TC: Primary CPU switching to normal world boot
��
[0001.888] I> Welcome to NVDisp-Init
[0001.888] I> NVDisp-Init version: 32.07.02-oe4t-t194-22776bfd
[0001.888] I> CPU-BL Params @ 0xca020000
[0001.889] I> 0) Base:0x00000000 Size:0x00000000
[0001.889] I> 1) Base:0xc8100000 Size:0x00100000
[0001.889] I> 2) Base:0xc9800000 Size:0x00200000
[0001.890] I> 3) Base:0xc8600000 Size:0x00200000
[0001.893] I> 4) Base:0xc8000000 Size:0x00100000
[0001.898] I> 5) Base:0xc7f00000 Size:0x00100000
[0001.902] I> 6) Base:0xc9400000 Size:0x00400000
[0001.907] I> 7) Base:0xc9000000 Size:0x00400000
[0001.911] I> 8) Base:0xc7e00000 Size:0x00100000
[0001.916] I> 9) Base:0xc7d00000 Size:0x00100000
[0001.920] I> 10) Base:0xca800000 Size:0x00800000
[0001.925] I> 11) Base:0x40000000 Size:0x00040000
[0001.929] I> 12) Base:0xc7c00000 Size:0x00100000
[0001.934] I> 13) Base:0x40046000 Size:0x00002000
[0001.938] I> 14) Base:0x40048000 Size:0x00002000
[0001.943] I> 15) Base:0xaf000000 Size:0x00004000
[0001.947] I> 16) Base:0x4004a000 Size:0x00002000
[0001.951] I> 17) Base:0xc7a00000 Size:0x00100000
[0001.956] I> 18) Base:0x4004c000 Size:0x00002000
[0001.960] I> 19) Base:0xc9a00000 Size:0x00600000
[0001.965] I> 20) Base:0x4004e000 Size:0x00002000
[0001.969] I> 21) Base:0xc7bc0000 Size:0x0000c000
[0001.974] I> 22) Base:0x00000000 Size:0x00000000
[0001.978] I> 23) Base:0xc7be0000 Size:0x00020000
[0001.983] I> 24) Base:0xcc000000 Size:0x02000000
[0001.987] I> 25) Base:0x40050000 Size:0x00002000
[0001.992] I> 26) Base:0x40040000 Size:0x00006000
[0001.996] I> 27) Base:0xc8c00000 Size:0x00400000
[0002.001] I> 28) Base:0xc8400000 Size:0x00200000
[0002.005] I> 29) Base:0xc8800000 Size:0x00400000
[0002.009] I> 30) Base:0xc7bd0000 Size:0x00010000
[0002.014] I> 31) Base:0x00000000 Size:0x00000000
[0002.018] I> 32) Base:0xf8000000 Size:0x08000000
[0002.023] I> 33) Base:0xce000000 Size:0x2a000000
[0002.027] I> 34) Base:0xcb000000 Size:0x01000000
[0002.032] I> 35) Base:0xae000000 Size:0x01000000
[0002.036] I> 36) Base:0xa0000000 Size:0x0e000000
[0002.041] I> 37) Base:0xca000000 Size:0x00800000
[0002.045] I> 38) Base:0x80000000 Size:0x20000000
[0002.050] I> 39) Base:0xb0000000 Size:0x08000000
[0002.054] I> 40) Base:0x00000000 Size:0x00000000
[0002.059] I> 41) Base:0x00000000 Size:0x00000000
[0002.063] I> 42) Base:0xc8200000 Size:0x00200000
[0002.067] I> 43) Base:0x00000000 Size:0x00000000
[0002.072] I> 44) Base:0x00000000 Size:0x00000000
[0002.076] I> 45) Base:0x00000000 Size:0x00000000
[0002.081] GIC-SPI Target CPU: 0
[0002.084] Interrupts Init done
[0002.087] calling constructors
[0002.090] initializing heap
[0002.092] I> Heap: [0xa0960000 ... 0xadf00000]
[0002.097] initializing threads
[0002.099] initializing timers
[0002.102] creating bootstrap completion thread
[0002.107] top of bootstrap2()
[0002.109] CPU: MIDR: 0x4E0F0040, MPIDR: 0x80000000
[0002.114] initializing platform
[0002.117] E> DEVICE_PROD: Invalid value data = 0, size = 0.
[0002.122] W> device prod register failed
[0002.126] I> Bl_dtb @0xadf00000
[0002.129] I> gpio framework initialized
[0002.142] I> tegrabl_gpio_driver_register: register 'nvidia,tegra194-gpio' driver
[0002.147] I> tegrabl_gpio_driver_register: register 'nvidia,tegra194-gpio-aon' driver
[0002.152] I> fixed regulator driver initialized
[0002.171] I> register 'maxim' power off handle
[0002.173] I> virtual i2c enabled
[0002.174] I> registered 'maxim,max20024' pmic
[0002.174] I> tegrabl_gpio_driver_register: register 'max20024-gpio' driver
[0002.175] I> Boot-device: eMMC
[0002.175] I> Boot_device: SDMMC_BOOT instance: 3
[0002.180] I> sdmmc-3 params source = boot args
[0002.183] W> No board IDs available
[0002.185] E> Failed to get board id info!
[0002.189] I> sdmmc bdev is already initialized
[0002.194] I> sdmmc-3 params source = boot args
[0002.200] I> Found 20 partitions in SDMMC_BOOT (instance 3)
[0002.205] I> Found 45 partitions in SDMMC_USER (instance 3)
[0002.229] I> enabling 'vdd-hdmi-5v0' regulator
[0002.236] I> regulator 'vdd-hdmi-5v0' already enabled
[0002.237] E> tegrabl_display_init_regulator: hdmi cable is not connected
[0002.237] E> tegrabl_display_get_pdata, failed to parse dtb settings
[0002.238] E> cannot find any other nvdisp nodes
[0002.239] E> no valid display unit config found in dtb
[0002.242] W> display init failed
[0002.243] initializing target
[0002.246] calling apps_init()
[0002.249] starting app kernel_boot_app
[0002.252] I> Kernel type = Normal
Jetson UEFI firmware (version v35.5.0 built on 2024-02-26T13:44:31+00:00)
��E/TC:? 0 get_rpc_alloc_res:645 RPC allocation failed. Non-secure world result: ret=0xffff0000 ret_origin=0
E/LD: init_elf:486 sys_open_ta_bin(bc50d971-d4c9-42c4-82cb-343fb7f37896)
E/TC:? 0 ldelf_init_with_ldelf:131 ldelf failed with res: 0xffff000c
��
Jetson UEFI firmware (version v35.5.0 built on 2024-02-26T13:44:31+00:00)
ESC to enter Setup.
F11 to enter Boot Manager Menu.
Enter to continue boot.
** WARNING: Test Key is used. **
......
L4TLauncher: Attempting Recovery Boot
Android image header not seen
Failed to boot recovery:1 partition
>>Start PXE over IPv4.
PXE-E16: No valid offer received.
>>Start PXE over IPv6. This command never works:
|
Actually it turns out that it is not even necessary to try to switch the bootslot. Just restarting will switch to B . Restarting again then ends in nirvana. A pure yocto build can reboot without problems. Unsure how I can switch between A/B though due to missing commands: |
Describe the bug
BUG Nr1
l4t_version.bbclass not found
BUG Nr2
| install: cannot create regular file '/home/yocto/git/ext/meta-mender-community/build/tmp/work/jetson_agx_xavier_devkit-oe4t-linux/tegra-storage-layout-base/35.5.0/image/usr/share/tegraflash/flash_l4t_nvme_rootfs_ab.xml': No such file or directory
| WARNING: exit code 1 from a shell command.
ERROR: Task (/home/yocto/git/ext/meta-mender-community/build/../meta-tegra/recipes-bsp/tegra-binaries/tegra-storage-layout-base_35.5.0.bb:do_install) failed with exit code '1'
BUG Nr3
| Error: Return value 4
| Command tegrabct_v2 --chip 0x19 --mb1bct mb1_cold_boot_bct_MB1.bct --updatefwinfo flash.xml.bin
| WARNING: exit code 1 from a shell command.
ERROR: Task (/home/yocto/git/ext/meta-mender-community/build/../meta-tegra/recipes-bsp/uefi/tegra-uefi-capsules_35.5.0.bb:do_compile) failed with exit code '1'
To Reproduce
Additional context
In order to fix the above bugs I think these changes need to be made:
Bug Nr1
in
kas/include/tegra-jetpack5.yml
This pull request.
and Bug Nr2
meta-tegra/recipes-bsp/tegra-binaries/tegra-storage-layout-base_35.5.0.bb
Additionally there is a typo in the last
PARTITION_LAYOUT_EXTERNAL
used in the original code. It is missing aT
.I was referred here to create a pull request , even though the bug seems to be in
meta-tegra
:( . See here.No idea how to fix Bug Nr3. It seems to be an issue with the partition layout. I have a 32GB Nvidia Jetson AGX Xavier.
Many many thanks for making the meta-mender version L4T 35.5 available to owners of an NVIDIA AGX Xavier !!!!!