I have built a FIT image following the instructions outlined in the release notes, but loading/executing the image causes an kernel panic and a hang. The only error I can pick out of the message dump is that no uefi is present, but it tries to continue booting before crashing on an undefined instruction.
Reading the kernel image using mkimage -l informs that the kernel is gz compressed, yet there is not "unpacking" stage shown in the kernel logs; it just jumps right to "Starting Kernel" rather than "Uncompressing Kernel ... ".
Also, there are several types of FIT images that are built:
kernel-fsl-ls1043a-uefi-rdb.dtb-ls1043ardb-20160404181338.itb
kernel-fsl-ls1043a-rdb-usdpaa.dtb-ls1043ardb-20160404181338.itb
kernel-fsl-ls1043a-rdb.dtb-ls1043ardb-20160404181338.itb
I could not find much information about each of the images above. What are each of their purposes?
The contents of the build directory following a successful compilation are (sans the symlinks):
fsl_fman_ucode_t2080_r1.1_106_4_17.bin
fsl_fman_ucode_t2080_r1.1_108_4_5.bin
fsl-image-core-ls1043ardb-20160404181338.rootfs.ext2.gz
fsl-image-core-ls1043ardb-20160404181338.rootfs.ext2.gz.u-boot
fsl-image-core-ls1043ardb-20160404181338.rootfs.manifest
fsl-image-core-ls1043ardb-20160404181338.rootfs.tar.gz
fsl-image-full-ls1043ardb-20160401165628.rootfs.ext2.gz
fsl-image-full-ls1043ardb-20160401165628.rootfs.manifest
fsl-image-full-ls1043ardb-20160401165628.rootfs.tar.gz
fsl-image-full-ls1043ardb-20160401172219.rootfs.ext2.gz
fsl-image-full-ls1043ardb-20160401172219.rootfs.manifest
fsl-image-full-ls1043ardb-20160401172219.rootfs.tar.gz
Image--3.19-r0-fsl-ls1043a-rdb-20160401165628.dtb
Image--3.19-r0-fsl-ls1043a-rdb-usdpaa-20160401165628.dtb
Image--3.19-r0-fsl-ls1043a-uefi-rdb-20160401165628.dtb
Image--3.19-r0-ls1043ardb-20160401165628.bin
iram_Type_A_LS1021a_r1.0.bin
kernel-fsl-ls1043a-rdb.dtb-ls1043ardb-20160404181338.itb
kernel-fsl-ls1043a-rdb-usdpaa.dtb-ls1043ardb-20160404181338.itb
kernel-fsl-ls1043a-uefi-rdb.dtb-ls1043ardb-20160404181338.itb
LS1043ARDBPI_NAND_EFI.pbl
LS1043ARDBPI_SD_EFI.pbl
LS1043aRdbPkgXipBoot_EFI.fd
modules--3.19-r0-ls1043ardb-20160401165628.tgz
NAND_EFI.fd
ppa.itb
rcw/
README_-_DO_NOT_DELETE_FILES_IN_THIS_DIRECTORY.txt
SD_EFI.fd
u-boot-ls1043ardb-2015.01+git-r0.bin
u-boot-nand-ls1043ardb_nand-2015.01+git-r0.bin
u-boot-sd-ls1043ardb_sdcard-2015.01+git-r0.bin
The log from the kernel is as follows when executing the kernel-fsl-ls1043a-rdb.dtb-ls1043ardb-20160404181338.itb image:
=> bootm 0xa0000000
## Loading kernel from FIT Image at a0000000 ...
Using 'config@1' configuration
Trying 'kernel@1' kernel subimage
Description: ARM64 Linux kernel
Type: Kernel Image
Compression: gzip compressed
Data Start: 0xa00000dc
Data Size: 4408291 Bytes = 4.2 MiB
Architecture: AArch64
OS: Linux
Load Address: 0x80080000
Entry Point: 0x80080000
Verifying Hash Integrity ... OK
## Loading ramdisk from FIT Image at a0000000 ...
Using 'config@1' configuration
Trying 'ramdisk@1' ramdisk subimage
Description: LS1043 Ramdisk
Type: RAMDisk Image
Compression: uncompressed
Data Start: 0xa043bab4
Data Size: 30560088 Bytes = 29.1 MiB
Architecture: AArch64
OS: Linux
Load Address: unavailable
Entry Point: unavailable
Verifying Hash Integrity ... OK
## Loading fdt from FIT Image at a0000000 ...
Using 'config@1' configuration
Trying 'fdt@1' fdt subimage
Description: Flattened Device Tree blob
Type: Flat Device Tree
Compression: uncompressed
Data Start: 0xa0434574
Data Size: 29880 Bytes = 29.2 KiB
Architecture: AArch64
Verifying Hash Integrity ... OK
Loading fdt from 0xa0434574 to 0x90000000
Booting using the fdt blob at 0x90000000
Uncompressing Kernel Image ... OK
reserving fdt memory region: addr=80000000 size=10000
Using Device Tree in place at 0000000090000000, end 000000009001a4b7
Starting kernel ...
Booting Linux on physical CPU 0x0
Initializing cgroup subsys cpu
Linux version 3.19.3+ (user@NXP-build) (gcc version 4.8.3 20140401 (prerelease) (Linaro GCC 4.8-2014.04) ) #1 SMP PREEMPT Fri Apr 1 13:03:40 EDT 2016
CPU: AArch64 Processor [410fd034] revision 4
Detected VIPT I-cache on CPU0
Early serial console at MMIO 0x21c0500 (options '115200')
bootconsole [uart0] enabled
efi: Getting EFI parameters from FDT:
efi: UEFI not found.
Reserved memory: initialized node bman-fbpr, compatible id fsl,bman-fbpr
Reserved memory: initialized node qman-fqd, compatible id fsl,qman-fqd
Reserved memory: initialized node qman-pfdr, compatible id fsl,qman-pfdr
cma: Reserved 16 MiB at 0x00000000fb000000
psci: probing for conduit method from DT.
swapper[0]: undefined instruction: pc=ffffffc00008c008
Code: 00000000 00000000 d4000002 d65f03c0 (d4000003)
Internal error: Oops - undefined instruction: 0 [#1] PREEMPT SMP
Modules linked in:
CPU: 0 PID: 0 Comm: swapper Not tainted 3.19.3+ #1
Hardware name: LS1043A RDB Board (DT)
task: ffffffc00096a940 ti: ffffffc000958000 task.ti: ffffffc000958000
PC is at __invoke_psci_fn_smc+0x0/0x8
LR is at psci_0_2_init+0x40/0x174
pc : [<ffffffc00008c008>] lr : [<ffffffc000905ba0>] pstate: 400002c5
sp : ffffffc00095bec0
x29: ffffffc00095bec0 x28: 0000004080000000
x27: ffffffc00096d0a8 x26: ffffffc00097b000
x25: ffffffc00084a5e0 x24: ffffffc000971fa0
x23: ffffffc00096d000 x22: ffffffc0009cb000
x21: ffffffc00096d2a8 x20: ffffffc0009d9de0
x19: 0000000000000000 x18: ffffffc0009d9dc8
x17: 0000000000000000 x16: 0000000000000010
x15: 00000000ffe00000 x14: ffffffffffffffff
x13: 0000000000000018 x12: 0101010101010101
x11: 0000000000000018 x10: 0101010101010101
x9 : 7f7f7f7f7f7f7f7f x8 : 7f7f7f7f7f7f7f7f
x7 : fefefefeff626c72 x6 : 0000008080808083
x5 : ffffffc00008c008 x4 : ffffffc0009cb000
x3 : 0000000000000000 x2 : 0000000000000000
x1 : 0000000000000000 x0 : 0000000084000000
Process swapper (pid: 0, stack limit = 0xffffffc000958058)
Stack: (0xffffffc00095bec0 to 0xffffffc00095c000)
bec0: 0095bef0 ffffffc0 00905e18 ffffffc0 7fdfddc0 ffffffc0 009d9de0 ffffffc0
bee0: 0096d2a8 ffffffc0 009cb000 ffffffc0 0095bf10 ffffffc0 009057c8 ffffffc0
bf00: 7fdfddc0 ffffffc0 0093d480 ffffffc0 0095bfa0 ffffffc0 00902694 ffffffc0
bf20: 009cb000 ffffffc0 00936078 ffffffc0 00000000 00000000 009cb000 ffffffc0
bf40: 00964000 ffffffc0 80000000 00000000 80a7b000 00000000 80a7d000 00000000
bf60: 00081230 ffffffc0 006d5090 ffffffc0 00000001 00000000 90000000 00000000
bf80: ffffffff ffffffff 00000000 00000000 00000080 00000000 fefefefe fefefefe
bfa0: 00000000 00000000 800825f0 00000000 ffda0640 00000000 00000e12 00000000
bfc0: 90000000 00000000 410fd034 00000000 8096d000 00000000 80000000 00000000
bfe0: 00000000 00000000 00936078 ffffffc0 00000000 00000000 00000000 00000000
Call trace:
[<ffffffc00008c008>] __invoke_psci_fn_smc+0x0/0x8
[<ffffffc000905e14>] psci_init+0x28/0x3c
[<ffffffc0009057c4>] setup_arch+0x44c/0x5d8
[<ffffffc000902690>] start_kernel+0xa0/0x3c0
Code: 00000000 00000000 d4000002 d65f03c0 (d4000003)
---[ end trace cb88537fdc8fa200 ]---
Kernel panic - not syncing: Attempted to kill the idle task!
---[ end Kernel panic - not syncing: Attempted to kill the idle task!
Solved! Go to Solution.
Hello Branden Sherrell,
There is no PPA firmware programmed on your board, please follow the steps in the following to update the PPA firmware:
Program the ppa.itb to NOR flash at address 0x60500000.
1) Program the ucode for Bank0
=> tftp 82000000 ppa.itb
=> protect off 60500000 +$filesize;erase 60500000 +$filesize;
=> cp.b 82000000 60500000 $filesize;protect on 60500000 +$filesize
2) Program the ucode for Bank4
=> tftp 82000000 ppa.itb
=> protect off 64500000 +$filesize;erase 64500000 +$filesize;
=> cp.b 82000000 64500000 $filesize;protect on 64500000 +$filesize
The attached file is got from the pre_built image ISO.
Have a great day,
Yiping
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------
What exactly do these three lines tell you?
swapper[0]: undefined instruction: pc=ffffffc00008c008
Code: 00000000 00000000 d4000002 d65f03c0 (d4000003)
Internal error: Oops - undefined instruction: 0 [#1] PREEMPT SMP
It appears to just be a trap on undefined instruction. I am interested in how this pointed you to the fact that ppa was not installed. Also, why does the kernel panic when it cannot use ppa to communicate with SW?
Hello Branden Sherrell,
This is because some core and power related functions are implemented by PPA. If you don't want to use PPA, you could configure and rebuild u-boot to disable PPA, then u-boot will implement these functions instead of PPA.
You could disable the macro "CONFIG_FSL_LS_PPA" in u-boot header file include/configs/ls1043ardb.h to disable PPA, and rebuild u-boot image.
Have a great day,
Yiping
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------
Hello Branden Sherrell,
Did you use Linux-LS1043A-SDK-V0.5 release SDK? Would you please provide kernel configuration file which your are using?
Have a great day,
Yiping
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------
I downloaded the SDK directly from here. I built the image (fsl-image-kernelitb) without any configuration or source changes. Three FIT images resulted
kernel-fsl-ls1043a-uefi-rdb.dtb-ls1043ardb-20160404181338.itb
kernel-fsl-ls1043a-rdb-usdpaa.dtb-ls1043ardb-20160404181338.itb
kernel-fsl-ls1043a-rdb.dtb-ls1043ardb-20160404181338.itb
I pushed, via TFTP, the kernel-fsl-ls1043a-rdb.dtb-ls1043ardb-20160404181338.itb and the panic ensued. The deployment is a rather simple process since you rely entirely on U-boot to pass kernel parameters via bootm and boot arguments as
bootargs ‘root=/dev/ram rw earlycon=uart8250,0x21c0500,115200 console=ttyS0,115200’
If it is the config file at
... /build_ls1043ardb_release/tmp/sysroots/ls1043ardb/usr/src/kernel/.config
you are looking for then I have attached it.
Hello Branden Sherrell,
There is no PPA firmware programmed on your board, please follow the steps in the following to update the PPA firmware:
Program the ppa.itb to NOR flash at address 0x60500000.
1) Program the ucode for Bank0
=> tftp 82000000 ppa.itb
=> protect off 60500000 +$filesize;erase 60500000 +$filesize;
=> cp.b 82000000 60500000 $filesize;protect on 60500000 +$filesize
2) Program the ucode for Bank4
=> tftp 82000000 ppa.itb
=> protect off 64500000 +$filesize;erase 64500000 +$filesize;
=> cp.b 82000000 64500000 $filesize;protect on 64500000 +$filesize
The attached file is got from the pre_built image ISO.
Have a great day,
Yiping
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------
Wonderful! That was the problem. How did you derive this conclusion from the kernel logs and config file?
Also, what is it about not having this the PPA application that causes the panic?
Finally, what are the differences between the three FIT images built as shown above?
EDIT: During boot I also see "Not a microcode". I have a second unmodified ls1043ardb that does not display this message, but rather reports information about a successful load of the "QE firmware." Which fsl build type includes a new QE firmware image? Also, what is this image/firmware for? The kernel seems to boot without issues despite it not being present.
Hello Branden Sherrell,
Just from the following information in the Kernel log.
swapper[0]: undefined instruction: pc=ffffffc00008c008
Code: 00000000 00000000 d4000002 d65f03c0 (d4000003)
Internal error: Oops - undefined instruction: 0 [#1] PREEMPT SMP
Please refer to the following characteristics of Primary Protected Application(PPA), the secure monitor and associated functions that comprise the base EL3 SW foundation.
Regarding the three FIT images, the FIT image contains uncompressed Linux Kernel image, dtb and filesystem.
kernel-fsl-ls1043a-rdb.dtb-ls1043ardb-20160404181338.itb is used to boot the normal Linux Kernel.
Kernel-fsl-ls1043a-rdb-usdpaa.dtb-ls1043ardb-20160404181338.itb is used to boot USDPAA(user space DPAA-Ethernet networking driver framework) system, USDPAA device tree is used and the networking interfaces will be assigned to USDPAA, Linux Kernel cannot use them any more.
Kernel-fsl-ls1043a-uefi-rdb.dtb-ls1043ardb-20160404181338.itb is used by UEFI bootloader(not for u-boot).
The system could be boot up without QE firmware, if you don't want to use QE related features, it is not necessary to flash QE firmware.
The attached is QE firmware got from SDK 0.5 pre-built image ISO, please flash it at 0x60600000 on bank0 and 0x64600000 on bank4.
Have a great day,
Yiping
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------