Re: [PATCH v2] arm64: dts: qcom: sa8775p: Add new memory map updates to SA8775P

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Jan 25, 2024 at 11:21:34AM +0530, Ninad Naik wrote:
> New memory map layout changes (by Qualcomm firmware) have brought
> in updates to base addresses and/or size for different memory regions
> like cpcucp_fw, tz-stat, and also introduces new memory regions for
> resource manager firmware. The updated memory map also fixes existing
> issues pertaining to boot up failure while running memtest, thus
> improving stability.
> 
> This change brings in these corresponding memory map updates to the
> device tree for SA8775P SoC platform, which currently is in its
> development stage.
> 
> Signed-off-by: Ninad Naik <quic_ninanaik@xxxxxxxxxxx>
> ---
> Changes since v1:
> - Updated commit message.
> - Fixed reserved memory node naming, by replacing underscore with
>   hyphen.
> - https://lore.kernel.org/all/20240118155711.7601-1-quic_ninanaik@xxxxxxxxxxx/
> ---
>  arch/arm64/boot/dts/qcom/sa8775p.dtsi | 103 +++++++++++++++++++++++---
>  1 file changed, 94 insertions(+), 9 deletions(-)
> 
> diff --git a/arch/arm64/boot/dts/qcom/sa8775p.dtsi b/arch/arm64/boot/dts/qcom/sa8775p.dtsi
> index a7eaca33d326..2e9606c80381 100644
> --- a/arch/arm64/boot/dts/qcom/sa8775p.dtsi
> +++ b/arch/arm64/boot/dts/qcom/sa8775p.dtsi
> @@ -356,13 +356,18 @@ uefi_log: uefi-log@908b0000 {
>  			no-map;
>  		};
>  
> +		ddr_training_checksum: ddr-training-checksum@908c0000 {
> +			reg = <0x0 0x908c0000 0x0 0x1000>;
> +			no-map;
> +		};
> +
>  		reserved_mem: reserved@908f0000 {
> -			reg = <0x0 0x908f0000 0x0 0xf000>;
> +			reg = <0x0 0x908f0000 0x0 0xe000>;
>  			no-map;
>  		};
>  
> -		secdata_apss_mem: secdata-apss@908ff000 {
> -			reg = <0x0 0x908ff000 0x0 0x1000>;
> +		secdata_apss_mem: secdata-apss@908fe000 {
> +			reg = <0x0 0x908fe000 0x0 0x2000>;
>  			no-map;
>  		};
>  
> @@ -373,8 +378,43 @@ smem_mem: smem@90900000 {
>  			hwlocks = <&tcsr_mutex 3>;
>  		};
>  
> -		cpucp_fw_mem: cpucp-fw@90b00000 {
> -			reg = <0x0 0x90b00000 0x0 0x100000>;

On the latest firmware I have access to (mid-January), I still trigger a
fault on that block with these changes applied:
[    0.000000] earlycon: qcom_geni0 at MMIO 0x0000000000a8c000 (options '115200n8')
[    0.000000] printk: legacy bootconsole [qcom_geni0] enabled
[    0.000000] early_memtest: # of tests: 1
[    0.000000]   0x0000000090880000 - 0x00000000908b0000 pattern 0000000000000000
[    0.000000]   0x00000000908c1000 - 0x00000000908f0000 pattern 0000000000000000
[    0.000000]   0x0000000090b00000 - 0x0000000090c00000 pattern 0000000000000000
[    0.000000] Internal error: synchronous external abort: 0000000096000010 [#1] PREEMPT SMP
[    0.000000] Modules linked in:
[    0.000000] CPU: 0 PID: 0 Comm: swapper Not tainted 6.8.0-rc1-next-20240129-00001-g487b7c881fa6 #179
[    0.000000] Hardware name: Qualcomm SA8775P Ride (DT)
[    0.000000] pstate: 800000c5 (Nzcv daIF -PAN -UAO -TCO -DIT -SSBS BTYPE=--)
[    0.000000] pc : early_memtest+0x1e0/0x2a8
[    0.000000] lr : early_memtest+0x1a8/0x2a8
[    0.000000] sp : ffffc3168c233c60
[    0.000000] x29: ffffc3168c233c60 x28: 0000000000000000 x27: ffff244650b00000
[    0.000000] x26: 0000000090b00000 x25: 0000000000000000 x24: ffff244650c00000
[    0.000000] x23: ffffc3168c872980 x22: ffffc3168c30c000 x21: ffffc3168c30c000
[    0.000000] x20: 0000000080000000 x19: 0000000f54100000 x18: 0000000000000006
[    0.000000] x17: 3030303030303030 x16: 303030303030206e x15: 7265747461702030
[    0.000000] x14: 3030303063303930 x13: 3030303030303030 x12: 3030303030303030
[    0.000000] x11: 206e726574746170 x10: ffffc3168c2bc578 x9 : ffffc3168c264578
[    0.000000] x8 : 00000000ffffefff x7 : ffffc3168c2bc578 x6 : 80000000fffff000
[    0.000000] x5 : 0000000000100000 x4 : 0000000090b00007 x3 : 0000244650b00000
[    0.000000] x2 : 0000000000000000 x1 : ffffc3168c244ec0 x0 : ffff244650b00000
[    0.000000] Call trace:
[    0.000000]  early_memtest+0x1e0/0x2a8
[    0.000000]  bootmem_init+0x54/0x228
[    0.000000]  setup_arch+0x21c/0x658
[    0.000000]  start_kernel+0x7c/0x8c0
[    0.000000]  __primary_switched+0xb8/0xc8
[    0.000000] Code: eb18037f 540003a2 aa1b03e0 d503201f (f800841c) 
[    0.000000] ---[ end trace 0000000000000000 ]---
[    0.000000] Kernel panic - not syncing: Attempted to kill the idle task!
[    0.000000] ---[ end Kernel panic - not syncing: Attempted to kill the idle task! ]---

Adding back 0x90b00000-0x90bfffff as no-map passed memtest=1.

> +		tz_sail_mailbox_mem: tz-sail-mailbox@90c00000 {
> +			reg = <0x0 0x90c00000 0x0 0x100000>;
> +			no-map;
> +		};
> +
> +		sail_mailbox_mem: sail-ss@90d00000 {
> +			reg = <0x0 0x90d00000 0x0 0x100000>;
> +			no-map;
> +		};
> +
> +		sail_ota_mem: sail-ss@90e00000 {
> +			reg = <0x0 0x90e00000 0x0 0x300000>;
> +			no-map;
> +		};
> +
> +		aoss_backup_mem: aoss-backup@91b00000 {
> +			reg = <0x0 0x91b00000 0x0 0x40000>;
> +			no-map;
> +		};
> +
> +		cpucp_backup_mem: cpucp-backup@91b40000 {
> +			reg = <0x0 0x91b40000 0x0 0x40000>;
> +			no-map;
> +		};
> +
> +		tz_config_backup_mem: tz-config-backup@91b80000 {
> +			reg = <0x0 0x91b80000 0x0 0x10000>;
> +			no-map;
> +		};
> +
> +		ddr_training_data_mem: ddr-training-data@91b90000 {
> +			reg = <0x0 0x91b90000 0x0 0x10000>;
> +			no-map;
> +		};
> +
> +		cdt_data_backup_mem: cdt-data-backup@91ba0000 {
> +			reg = <0x0 0x91ba0000 0x0 0x1000>;
>  			no-map;
>  		};
>  
> @@ -433,13 +473,43 @@ pil_video_mem: pil-video@9fc00000 {
>  			no-map;
>  		};
>  
> +		audio_mdf_mem: audio-mdf-region@ae000000 {
> +			reg = <0x0 0xae000000 0x0 0x1000000>;
> +			no-map;
> +		};
> +
> +		firmware_mem: firmware-region@b0000000 {
> +			reg = <0x0 0xb0000000 0x0 0x800000>;
> +			no-map;
> +		};
> +
>  		hyptz_reserved_mem: hyptz-reserved@beb00000 {
>  			reg = <0x0 0xbeb00000 0x0 0x11500000>;
>  			no-map;
>  		};
>  
> -		tz_stat_mem: tz-stat@d0000000 {
> -			reg = <0x0 0xd0000000 0x0 0x100000>;
> +		scmi_mem: scmi-region@d0000000 {
> +			reg = <0x0 0xd0000000 0x0 0x40000>;
> +			no-map;
> +		};
> +
> +		firmware_logs_mem: firmware-logs@d0040000 {
> +			reg = <0x0 0xd0040000 0x0 0x10000>;
> +			no-map;
> +		};
> +
> +		firmware_audio_mem: firmware-audio@d0050000 {
> +			reg = <0x0 0xd0050000 0x0 0x4000>;
> +			no-map;
> +		};
> +
> +		firmware_reserved_mem: firmware-reserved@d0054000 {
> +			reg = <0x0 0xd0054000 0x0 0x9c000>;
> +			no-map;
> +		};
> +
> +		firmware_quantum_test_mem: firmware-quantum-test@d00f0000 {
> +			reg = <0x0 0xd00f0000 0x0 0x10000>;
>  			no-map;
>  		};
>  
> @@ -453,8 +523,23 @@ qtee_mem: qtee@d1300000 {
>  			no-map;
>  		};
>  
> -		trusted_apps_mem: trusted-apps@d1800000 {
> -			reg = <0x0 0xd1800000 0x0 0x3900000>;
> +		deepsleep_backup_mem: deepsleep-backup@d1800000 {
> +			reg = <0x0 0xd1800000 0x0 0x100000>;
> +			no-map;
> +		};
> +
> +		trusted_apps_mem: trusted-apps@d1900000 {
> +			reg = <0x0 0xd1900000 0x0 0x3800000>;
> +			no-map;
> +		};
> +
> +		tz_stat_mem: tz-stat@db100000 {
> +			reg = <0x0 0xdb100000 0x0 0x100000>;
> +			no-map;
> +		};
> +
> +		cpucp_fw_mem: cpucp-fw@db200000 {
> +			reg = <0x0 0xdb200000 0x0 0x100000>;
>  			no-map;
>  		};
>  	};
> -- 
> 2.42.0
> 
> 

-- 
Eric Chanudet





[Index of Archives]     [Device Tree Compilter]     [Device Tree Spec]     [Linux Driver Backports]     [Video for Linux]     [Linux USB Devel]     [Linux PCI Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Yosemite Backpacking]


  Powered by Linux