Part Number: 66AK2G12
Hi,
I am porting the kernel and filesystem from k2g_evm board to my custom board with obviuosly the proper modifications for periphericals. I am using Linux-rt SDK ver 06_01_00_08.
My DDR size is 256 MB and before u-boot relocation I have executed strees tests in order to ensure that DDR signals work well. The boot is executed via QSPI.
But kernel shows some problems at start-up; below the log:
U-Boot 2019.01-svn8 (Apr 30 2021 - 12:25:50 +0200) CPU: 66AK2Gx-100 SR1.0 Model: Texas Instruments K2G SoC - Hitachi Propulsion Controller (HPC) board Avvio u-boot entro 1 secondi Clear entire DDR3 memory to enable ECC 256 MiB MMC: Loading Environment from FAT... In: serial@02530c00 Out: serial@02530c00 Err: serial@02530c00 Net: No ethernet found. Hit any key to stop autoboot: 0 syntax error No MMC device available No MMC device available SF: Detected n25q512ax3 with page size 256 Bytes, erase size 4 KiB, total 64 MiB device 0 offset 0x240000, size 0x8040 SF: 32832 bytes @ 0x240000 Read: OK K2_BM_15.07-53-ge1f885a SoC:k2g built:17:19:23, Oct 19 2019 ## installed monitor @ 0xc0f7000, freq [24000000], status 202338304 device 0 offset 0x250000, size 0x8354 SF: 33620 bytes @ 0x250000 Read: OK 0 - Name:'pmmc@2900000' type:'internal memory mapped' supports: load start Load Remote Processor 0 with data@addr=0x82000000 33620 bytes: Success! device 0 offset 0x280000, size 0x800000 SF: 8388608 bytes @ 0x280000 Read: OK device 0 offset 0x260000, size 0x8625 SF: 34341 bytes @ 0x260000 Read: OK device 0 offset 0x200000, size 0x40000 SF: 262144 bytes @ 0x200000 Read: OK ## Flattened Device Tree blob at 88000000 Booting using the fdt blob at 0x88000000 Loading Ramdisk to 90000000, end 90000000 ... OK Loading Device Tree to 8df0d000, end 8df16e2f ... OK start[0]: 0x80000000 - size[0]: 0x10000000 start[1]: 0x8ffc3dbc8df0d000 - size[1]: 0x7264646132687465 Starting kernel ... [ 0.000000] Booting Linux on physical CPU 0x0 [ 0.000000] Linux version 4.19.59-rt24-g4203cb8c96 (root@ubuntu) (gcc version 8.3.0 (GNU Toolchain for the A-profile Architecture 8.3-2019.03 (arm-rel-8.36))) #3 SMP PREEMPT RT Tue May 26 15:26:26 CEST 2020 [ 0.000000] CPU: ARMv7 Processor [412fc0f4] revision 4 (ARMv7), cr=30c5387d [ 0.000000] CPU: div instructions available: patching division code [ 0.000000] CPU: PIPT / VIPT nonaliasing data cache, PIPT instruction cache [ 0.000000] OF: fdt: Machine model: Texas Instruments K2G - Hitachi Propulsion Controller (HPC) [ 0.000000] bootconsole [earlycon0] enabled [ 0.000000] Memory policy: Data cache writealloc [ 0.000000] Invalid address space for memory (800000000-ffffffffffffffff) [ 0.000000] efi: Getting EFI parameters from FDT: [ 0.000000] efi: UEFI not found. [ 0.000000] Reserved memory: created CMA memory pool at 0x000000080f800000, size 4 MiB [ 0.000000] OF: reserved mem: initialized node dsp-common-memory@80f800000, compatible id shared-dma-pool [ 0.000000] cma: Failed to reserve 48 MiB [ 0.000000] Kernel panic - not syncing: ERROR: Failed to allocate 0x0000000000002000 bytes below 0x0000000000000000. [ 0.000000]
It hangs after
[ 0.000000] cma: Failed to reserve 48 MiB [ 0.000000] Kernel panic - not syncing: ERROR: Failed to allocate 0x0000000000002000 bytes below 0x0000000000000000.
that is last point before hanging but another problem is present some step before:
[ 0.000000] Invalid address space for memory (800000000-ffffffffffffffff)
I am using the same zImage and filesystem used for k2g_evm because I have enabled all drivers needed for both boards but the .dtb is different according to my board pheripherals and DDR size. Below the first raw of my dts:
/ {
compatible = "ti,k2g-ice", "ti,k2g", "ti,keystone";
model = "Texas Instruments K2G - Hitachi Propulsion Controller (HPC)";
memory@800000000 {
device_type = "memory";
reg = <0x00000008 0x00000000 0x00000000 0x10000000>;
};
reserved-memory {
#address-cells = <2>;
#size-cells = <2>;
ranges;
dsp_common_mpm_memory: dsp-common-mpm-memory@80d000000 {
compatible = "ti,keystone-dsp-mem-pool";
reg = <0x00000008 0x0d000000 0x00000000 0x800000>;
no-map;
status = "okay";
};
dsp_common_memory: dsp-common-memory@80f800000 {
compatible = "shared-dma-pool";
reg = <0x00000008 0x0f800000 0x00000000 0x400000>;
reusable;
status = "okay";
};
};
As you can see I have modified the value in reg paramer for dsp_common_mpm_memory and for dsp_common_memory because I suppose that default value are ok for k2g_evm/ice DDR size and not for my board. I have tried both configuration but the result is the same. Looking at other e2e question I have modified also k2g_evm_cmem.dtsi asl below
/ {
reserved-memory {
cmem_block_mem_0: cmem_block_mem@808000000 {
reg = <0x00000008 0x08000000 0x00000000 0x5000000>;
no-map;
status = "okay";
};
};
cmem {
compatible = "ti,cmem";
#address-cells = <1>;
#size-cells = <0>;
#pool-size-cells = <2>;
status = "okay";
cmem_block_0: cmem_block@0 {
reg = <0>;
memory-region = <&cmem_block_mem_0>;
cmem-buf-pools = <1 0x00000000 0x5000000>;
};
cmem_block_1: cmem_block@1 {
reg = <1>;
sram = <&sram_cmem>;
};
};
};
&msm_ram {
sram_cmem: sram-cmem@a0000 {
reg = <0xa0000 0x57000>;
};
};
but no improvements.
I think that this problem is related how memory between ARM and DSP is manged but maybe I could be wrong or my dts setting is not correct.
Please I wait for your feedback.
Regards
Graziano