ti: add support for AM6254atl SiP
TI's AM6254atl (or AM62x SiP for short) provides the existing AM62x SoC with 512MiB of DDR integrated in a single package. This patch adds the necessary U-Boot devie tree files, the required defconfigs along with the documentation for the AM62x SiP EVM. AM62x SiP differs from the already supported AM62x in following ways: - OP-TEE for the AM62x resides from 0x9e800000 to 0xa0000000 which needs to be moved to 0x80080000 to free up space at end of DDR in AM62x SiP with 512MiB of memory. This is required to allow U-Boot to relocate to end of DDR before booting to the kernel. - Changes to the env: 1. splashimage address updated from 0x80200000 to 0x81a00000 2. DFU addresses updated to match updated TEXT_BASE for SPL and U-Boot Signed-off-by: Anshul Dalal <anshuld@ti.com>
This commit is contained in:
102
arch/arm/dts/k3-am6254atl-r5-sk.dts
Normal file
102
arch/arm/dts/k3-am6254atl-r5-sk.dts
Normal file
@@ -0,0 +1,102 @@
|
||||
// SPDX-License-Identifier: GPL-2.0
|
||||
/*
|
||||
* AM6254atl SiP SK dts for R5 SPL
|
||||
* Webpage: https://www.ti.com/tool/SK-AM62-SIP
|
||||
*
|
||||
* Copyright (C) 2025 Texas Instruments Incorporated - https://www.ti.com/
|
||||
*/
|
||||
|
||||
#include "k3-am6254atl-sk.dts"
|
||||
#include "k3-am6254atl-sip-ddr-lp4-50-800.dtsi"
|
||||
#include "k3-am62-ddr.dtsi"
|
||||
|
||||
#include "k3-am6254atl-sk-u-boot.dtsi"
|
||||
|
||||
/ {
|
||||
aliases {
|
||||
tick-timer = &main_timer0;
|
||||
remoteproc0 = &sysctrler;
|
||||
remoteproc1 = &a53_0;
|
||||
serial0 = &wkup_uart0;
|
||||
serial3 = &main_uart1;
|
||||
};
|
||||
|
||||
a53_0: a53@0 {
|
||||
compatible = "ti,am654-rproc";
|
||||
reg = <0x00 0x00a90000 0x00 0x10>;
|
||||
power-domains = <&k3_pds 61 TI_SCI_PD_EXCLUSIVE>,
|
||||
<&k3_pds 135 TI_SCI_PD_EXCLUSIVE>,
|
||||
<&k3_pds 166 TI_SCI_PD_EXCLUSIVE>;
|
||||
resets = <&k3_reset 135 0>;
|
||||
clocks = <&k3_clks 61 0>, <&k3_clks 135 0>;
|
||||
clock-names = "gtc", "core";
|
||||
assigned-clocks = <&k3_clks 61 0>, <&k3_clks 135 0>;
|
||||
assigned-clock-parents = <&k3_clks 61 2>;
|
||||
assigned-clock-rates = <200000000>, <1200000000>;
|
||||
ti,sci = <&dmsc>;
|
||||
ti,sci-proc-id = <32>;
|
||||
ti,sci-host-id = <10>;
|
||||
bootph-pre-ram;
|
||||
};
|
||||
|
||||
dm_tifs: dm-tifs {
|
||||
compatible = "ti,j721e-dm-sci";
|
||||
ti,host-id = <36>;
|
||||
ti,secure-host;
|
||||
mbox-names = "rx", "tx";
|
||||
mboxes= <&secure_proxy_main 22>,
|
||||
<&secure_proxy_main 23>;
|
||||
bootph-pre-ram;
|
||||
};
|
||||
};
|
||||
|
||||
&dmsc {
|
||||
mboxes= <&secure_proxy_main 0>,
|
||||
<&secure_proxy_main 1>,
|
||||
<&secure_proxy_main 0>;
|
||||
mbox-names = "rx", "tx", "notify";
|
||||
ti,host-id = <35>;
|
||||
ti,secure-host;
|
||||
};
|
||||
|
||||
&secure_proxy_sa3 {
|
||||
/* We require this for boot handshake */
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&cbass_main {
|
||||
sysctrler: sysctrler {
|
||||
compatible = "ti,am654-tisci-rproc-r5";
|
||||
mboxes= <&secure_proxy_main 1>, <&secure_proxy_main 0>, <&secure_proxy_sa3 0>;
|
||||
mbox-names = "tx", "rx", "boot_notify";
|
||||
bootph-pre-ram;
|
||||
};
|
||||
};
|
||||
|
||||
&main_timer0 {
|
||||
/delete-property/ clocks;
|
||||
/delete-property/ clocks-names;
|
||||
/delete-property/ assigned-clocks;
|
||||
/delete-property/ assigned-clock-parents;
|
||||
clock-frequency = <25000000>;
|
||||
};
|
||||
|
||||
/* WKUP UART0 is used for DM firmware logs */
|
||||
&wkup_uart0 {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
/* Main UART1 is used for TIFS firmware logs */
|
||||
&main_uart1 {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&ospi0 {
|
||||
reg = <0x00 0x0fc40000 0x00 0x100>,
|
||||
<0x00 0x60000000 0x00 0x08000000>;
|
||||
};
|
||||
|
||||
&main_pktdma {
|
||||
ti,sci = <&dm_tifs>;
|
||||
bootph-all;
|
||||
};
|
||||
2191
arch/arm/dts/k3-am6254atl-sip-ddr-lp4-50-800.dtsi
Normal file
2191
arch/arm/dts/k3-am6254atl-sip-ddr-lp4-50-800.dtsi
Normal file
File diff suppressed because it is too large
Load Diff
21
arch/arm/dts/k3-am6254atl-sk-u-boot.dtsi
Normal file
21
arch/arm/dts/k3-am6254atl-sk-u-boot.dtsi
Normal file
@@ -0,0 +1,21 @@
|
||||
// SPDX-License-Identifier: GPL-2.0
|
||||
/*
|
||||
* Common AM6254atl SK dts file for SPLs
|
||||
* Copyright (C) 2025 Texas Instruments Incorporated - https://www.ti.com/
|
||||
*/
|
||||
|
||||
#include "k3-am625-sk-u-boot.dtsi"
|
||||
|
||||
#ifdef CONFIG_TARGET_AM625_A53_EVM
|
||||
|
||||
#define SPL_AM6254ATL_SK_DTB "spl/dts/ti/k3-am6254atl-sk.dtb"
|
||||
|
||||
&spl_am625_sk_dtb {
|
||||
filename = SPL_AM6254ATL_SK_DTB;
|
||||
};
|
||||
|
||||
&spl_am625_sk_dtb_unsigned {
|
||||
filename = SPL_AM6254ATL_SK_DTB;
|
||||
};
|
||||
|
||||
#endif
|
||||
@@ -10,3 +10,5 @@ F: configs/am62x_evm_r5_ethboot_defconfig
|
||||
F: configs/am62x_evm_a53_ethboot_defconfig
|
||||
F: configs/am62x_lpsk_r5_defconfig
|
||||
F: configs/am62x_lpsk_a53_defconfig
|
||||
F: configs/am6254atl_evm_r5_defconfig
|
||||
F: configs/am6254atl_evm_a53_defconfig
|
||||
|
||||
37
board/ti/am62x/am6254atl.env
Normal file
37
board/ti/am62x/am6254atl.env
Normal file
@@ -0,0 +1,37 @@
|
||||
#include <env/ti/ti_common.env>
|
||||
#include <env/ti/mmc.env>
|
||||
#include <env/ti/k3_dfu.env>
|
||||
|
||||
|
||||
#if CONFIG_CMD_REMOTEPROC
|
||||
#include <env/ti/k3_rproc.env>
|
||||
#endif
|
||||
|
||||
rproc_fw_binaries= 0 /lib/firmware/am62-mcu-m4f0_0-fw
|
||||
|
||||
name_kern=Image
|
||||
console=ttyS2,115200n8
|
||||
args_all=setenv optargs ${optargs} earlycon=ns16550a,mmio32,0x02800000
|
||||
${mtdparts}
|
||||
run_kern=booti ${loadaddr} ${rd_spec} ${fdtaddr}
|
||||
|
||||
boot_targets=mmc1 mmc0 usb pxe dhcp
|
||||
boot=mmc
|
||||
mmcdev=1
|
||||
bootpart=1:2
|
||||
bootdir=/boot
|
||||
rd_spec=-
|
||||
|
||||
splashfile=ti_logo_414x97_32bpp.bmp.gz
|
||||
splashimage=0x82180000
|
||||
splashpos=m,m
|
||||
splashsource=sf
|
||||
|
||||
dfu_alt_info_ram=
|
||||
tispl.bin ram 0x82000000 0x200000;
|
||||
u-boot.img ram 0x82f80000 0x400000
|
||||
|
||||
#if CONFIG_BOOTMETH_ANDROID
|
||||
#include <env/ti/android.env>
|
||||
adtb_idx=0
|
||||
#endif
|
||||
15
configs/am6254atl_evm_a53_defconfig
Normal file
15
configs/am6254atl_evm_a53_defconfig
Normal file
@@ -0,0 +1,15 @@
|
||||
#include <configs/am62x_evm_a53_defconfig>
|
||||
|
||||
CONFIG_ARM=y
|
||||
CONFIG_ARCH_K3=y
|
||||
CONFIG_SOC_K3_AM625=y
|
||||
CONFIG_TARGET_AM625_A53_EVM=y
|
||||
CONFIG_TEXT_BASE=0x82f80000
|
||||
CONFIG_SPL_TEXT_BASE=0x82000000
|
||||
CONFIG_SPL_STACK_R_ADDR=0x83f80000
|
||||
CONFIG_K3_OPTEE_LOAD_ADDR=0x80080000
|
||||
CONFIG_SPL_BSS_START_ADDR=0x82c00000
|
||||
CONFIG_SPL_LOAD_FIT_ADDRESS=0x82f80000
|
||||
CONFIG_CUSTOM_SYS_INIT_SP_ADDR=0x82b00000
|
||||
CONFIG_DEFAULT_DEVICE_TREE="ti/k3-am6254atl-sk"
|
||||
CONFIG_ENV_SOURCE_FILE="am6254atl"
|
||||
10
configs/am6254atl_evm_r5_defconfig
Normal file
10
configs/am6254atl_evm_r5_defconfig
Normal file
@@ -0,0 +1,10 @@
|
||||
#include <configs/am62x_evm_r5_defconfig>
|
||||
|
||||
CONFIG_ARM=y
|
||||
CONFIG_ARCH_K3=y
|
||||
CONFIG_SOC_K3_AM625=y
|
||||
CONFIG_TARGET_AM625_R5_EVM=y
|
||||
CONFIG_ENV_SOURCE_FILE="am6254atl"
|
||||
CONFIG_K3_OPTEE_LOAD_ADDR=0x80080000
|
||||
CONFIG_SPL_LOAD_FIT_ADDRESS=0x82000000
|
||||
CONFIG_DEFAULT_DEVICE_TREE="k3-am6254atl-r5-sk"
|
||||
308
doc/board/ti/am6254atl_sk.rst
Normal file
308
doc/board/ti/am6254atl_sk.rst
Normal file
@@ -0,0 +1,308 @@
|
||||
.. SPDX-License-Identifier: GPL-2.0+ OR BSD-3-Clause
|
||||
.. sectionauthor:: Anshul Dalal <anshuld@ti.com>
|
||||
|
||||
AM6254ATL SIP Platforms
|
||||
=======================
|
||||
|
||||
Introduction:
|
||||
-------------
|
||||
|
||||
The AM6254atl SiP (System In Package) provides existing :doc:`am62x_sk` with
|
||||
512MiB of DDR integrated in a single packages.
|
||||
|
||||
More details can be found in the Technical Reference Manual:
|
||||
https://www.ti.com/lit/pdf/spruiv7
|
||||
|
||||
Platform information:
|
||||
|
||||
* https://www.ti.com/tool/SK-AM62-SIP
|
||||
|
||||
Boot Flow:
|
||||
----------
|
||||
Below is the pictorial representation of boot flow:
|
||||
|
||||
.. image:: img/boot_diagram_am62.svg
|
||||
:alt: Boot flow diagram
|
||||
|
||||
- Here TIFS acts as master and provides all the critical services. R5/A53
|
||||
requests TIFS to get these services done as shown in the above diagram.
|
||||
|
||||
Sources:
|
||||
--------
|
||||
|
||||
.. include:: ../ti/k3.rst
|
||||
:start-after: .. k3_rst_include_start_boot_sources
|
||||
:end-before: .. k3_rst_include_end_boot_sources
|
||||
|
||||
.. include:: ../ti/k3.rst
|
||||
:start-after: .. k3_rst_include_start_boot_firmwares
|
||||
:end-before: .. k3_rst_include_end_tifsstub
|
||||
|
||||
Build procedure:
|
||||
----------------
|
||||
0. Setup the environment variables:
|
||||
|
||||
.. include:: ../ti/k3.rst
|
||||
:start-after: .. k3_rst_include_start_common_env_vars_desc
|
||||
:end-before: .. k3_rst_include_end_common_env_vars_desc
|
||||
|
||||
.. include:: ../ti/k3.rst
|
||||
:start-after: .. k3_rst_include_start_board_env_vars_desc
|
||||
:end-before: .. k3_rst_include_end_board_env_vars_desc
|
||||
|
||||
Set the variables corresponding to this platform:
|
||||
|
||||
.. include:: ../ti/k3.rst
|
||||
:start-after: .. k3_rst_include_start_common_env_vars_defn
|
||||
:end-before: .. k3_rst_include_end_common_env_vars_defn
|
||||
.. prompt:: bash $
|
||||
|
||||
export UBOOT_CFG_CORTEXR=am6254atl_evm_r5_defconfig
|
||||
export UBOOT_CFG_CORTEXA=am6254atl_evm_a53_defconfig
|
||||
export TFA_BOARD=lite
|
||||
export TFA_EXTRA_ARGS="PRELOADED_BL33_BASE=0x81880000 BL32_BASE=0x80080000"
|
||||
export OPTEE_PLATFORM=k3-am62x
|
||||
export OPTEE_EXTRA_ARGS="CFG_TZDRAM_START=0x80080000"
|
||||
|
||||
1. Trusted Firmware-A:
|
||||
|
||||
.. include:: ../ti/k3.rst
|
||||
:start-after: .. k3_rst_include_start_build_steps_tfa
|
||||
:end-before: .. k3_rst_include_end_build_steps_tfa
|
||||
|
||||
|
||||
2. OP-TEE:
|
||||
|
||||
.. include:: ../ti/k3.rst
|
||||
:start-after: .. k3_rst_include_start_build_steps_optee
|
||||
:end-before: .. k3_rst_include_end_build_steps_optee
|
||||
|
||||
3. U-Boot:
|
||||
|
||||
* 3.1 R5:
|
||||
|
||||
.. include:: ../ti/k3.rst
|
||||
:start-after: .. k3_rst_include_start_build_steps_spl_r5
|
||||
:end-before: .. k3_rst_include_end_build_steps_spl_r5
|
||||
|
||||
* 3.1.1 Alternative build of R5 for DFU boot:
|
||||
|
||||
As the SPL size can get too big when building with support for booting both
|
||||
from local storage *and* DFU an extra config fragment should be used to enable
|
||||
DFU support (and disable storage support)
|
||||
|
||||
.. prompt:: bash $
|
||||
|
||||
export UBOOT_CFG_CORTEXR="${UBOOT_CFG_CORTEXR} am62x_r5_usbdfu.config"
|
||||
|
||||
.. include:: ../ti/k3.rst
|
||||
:start-after: .. k3_rst_include_start_build_steps_spl_r5
|
||||
:end-before: .. k3_rst_include_end_build_steps_spl_r5
|
||||
|
||||
* 3.2 A53:
|
||||
|
||||
.. include:: ../ti/k3.rst
|
||||
:start-after: .. k3_rst_include_start_build_steps_uboot
|
||||
:end-before: .. k3_rst_include_end_build_steps_uboot
|
||||
|
||||
Target Images
|
||||
-------------
|
||||
|
||||
In order to boot we need tiboot3.bin, tispl.bin and u-boot.img. Each SoC
|
||||
variant (HS-FS or HS-SE) requires a different source for these files.
|
||||
|
||||
- HS-FS
|
||||
|
||||
* tiboot3-am62x-hs-fs-evm.bin from step 3.1
|
||||
* tispl.bin, u-boot.img from step 3.2
|
||||
|
||||
- HS-SE
|
||||
|
||||
* tiboot3-am62x-hs-evm.bin from step 3.1
|
||||
* tispl.bin, u-boot.img from step 3.2
|
||||
|
||||
Image formats:
|
||||
--------------
|
||||
|
||||
- tiboot3.bin
|
||||
|
||||
.. image:: img/multi_cert_tiboot3.bin.svg
|
||||
:alt: tiboot3.bin image format
|
||||
|
||||
- tispl.bin
|
||||
|
||||
.. image:: img/tifsstub_dm_tispl.bin.svg
|
||||
:alt: tispl.bin image format
|
||||
|
||||
OSPI:
|
||||
-----
|
||||
ROM supports booting from OSPI from offset 0x0.
|
||||
|
||||
Flashing images to OSPI:
|
||||
|
||||
Below commands can be used to download tiboot3.bin, tispl.bin, and u-boot.img,
|
||||
over tftp and then flash those to OSPI at their respective addresses.
|
||||
|
||||
.. prompt:: bash =>
|
||||
|
||||
sf probe
|
||||
tftp ${loadaddr} tiboot3.bin
|
||||
sf update $loadaddr 0x0 $filesize
|
||||
tftp ${loadaddr} tispl.bin
|
||||
sf update $loadaddr 0x80000 $filesize
|
||||
tftp ${loadaddr} u-boot.img
|
||||
sf update $loadaddr 0x280000 $filesize
|
||||
|
||||
Flash layout for OSPI:
|
||||
|
||||
.. image:: img/ospi_sysfw2.svg
|
||||
:alt: OSPI flash partition layout
|
||||
|
||||
A53 SPL DDR Memory Layout
|
||||
-------------------------
|
||||
|
||||
This provides an overview memory usage in A53 SPL stage.
|
||||
|
||||
.. list-table::
|
||||
:widths: 16 16 16
|
||||
:header-rows: 1
|
||||
|
||||
* - Region
|
||||
- Start Address
|
||||
- End Address
|
||||
|
||||
* - ATF
|
||||
- 0x80000000
|
||||
- 0x80080000
|
||||
|
||||
* - OPTEE
|
||||
- 0x80080000
|
||||
- 0x81880000
|
||||
|
||||
* - TEXT BASE
|
||||
- 0x81880000
|
||||
- 0x818d8000
|
||||
|
||||
* - EMPTY
|
||||
- 0x818d8000
|
||||
- 0x81a00000
|
||||
|
||||
* - BMP IMAGE
|
||||
- 0x81a00000
|
||||
- 0x82377660
|
||||
|
||||
* - STACK
|
||||
- 0x82377660
|
||||
- 0x82377e60
|
||||
|
||||
* - GD
|
||||
- 0x82377e60
|
||||
- 0x80b78000
|
||||
|
||||
* - MALLOC
|
||||
- 0x82378000
|
||||
- 0x82380000
|
||||
|
||||
* - EMPTY
|
||||
- 0x82380000
|
||||
- 0x82480000
|
||||
|
||||
* - BSS
|
||||
- 0x82480000
|
||||
- 0x82500000
|
||||
|
||||
* - BLOBS
|
||||
- 0x82500000
|
||||
- 0x82500400
|
||||
|
||||
* - EMPTY
|
||||
- 0x82500400
|
||||
- 0x82800000
|
||||
|
||||
Switch Setting for Boot Mode
|
||||
----------------------------
|
||||
|
||||
Boot Mode pins provide means to select the boot mode and options before the
|
||||
device is powered up. After every POR, they are the main source to populate
|
||||
the Boot Parameter Tables.
|
||||
|
||||
The following table shows some common boot modes used on AM62 platform. More
|
||||
details can be found in the Technical Reference Manual:
|
||||
https://www.ti.com/lit/pdf/spruiv7 under the `Boot Mode Pins` section.
|
||||
|
||||
.. list-table:: Boot Modes
|
||||
:widths: 16 16 16
|
||||
:header-rows: 1
|
||||
|
||||
* - Switch Label
|
||||
- SW2: 12345678
|
||||
- SW3: 12345678
|
||||
|
||||
* - SD
|
||||
- 01000000
|
||||
- 11000010
|
||||
|
||||
* - OSPI
|
||||
- 00000000
|
||||
- 11001110
|
||||
|
||||
* - EMMC
|
||||
- 00000000
|
||||
- 11010010
|
||||
|
||||
* - UART
|
||||
- 00000000
|
||||
- 11011100
|
||||
|
||||
* - USB DFU
|
||||
- 00000000
|
||||
- 11001010
|
||||
|
||||
* - Ethernet
|
||||
- 00110000
|
||||
- 11000100
|
||||
|
||||
For SW2 and SW1, the switch state in the "ON" position = 1.
|
||||
|
||||
DFU based boot
|
||||
--------------
|
||||
|
||||
To boot the board over DFU, set the switches to DFU mode and connect to the
|
||||
USB type C DRD port on the board. After power-on the build artifacts needs to be
|
||||
uploaded one by one with a tool like dfu-util.
|
||||
|
||||
The initial ROM will have a DFU alt named `bootloader` for the initial R5 spl
|
||||
upload. The next stages as exposed by U-Boot have target alts matching the name
|
||||
of the artifacts, for these a USB reset has to be done after each upload.
|
||||
|
||||
When using dfu-util the following commands can be used to boot to a U-Boot shell:
|
||||
|
||||
.. prompt:: bash $
|
||||
|
||||
dfu-util -a bootloader -D tiboot3.bin
|
||||
dfu-util -R -a tispl -D tispl.bin
|
||||
dfu-util -R -a u-boot.img -D u-boot.img
|
||||
|
||||
Debugging U-Boot
|
||||
----------------
|
||||
|
||||
See :ref:`Common Debugging environment - OpenOCD<k3_rst_refer_openocd>`: for
|
||||
detailed setup information.
|
||||
|
||||
.. warning::
|
||||
|
||||
**OpenOCD support since**: v0.12.0
|
||||
|
||||
If the default package version of OpenOCD in your development
|
||||
environment's distribution needs to be updated, it might be necessary to
|
||||
build OpenOCD from the source.
|
||||
|
||||
.. include:: k3.rst
|
||||
:start-after: .. k3_rst_include_start_openocd_connect_XDS110
|
||||
:end-before: .. k3_rst_include_end_openocd_connect_XDS110
|
||||
|
||||
To start OpenOCD and connect to the board
|
||||
|
||||
.. prompt:: bash $
|
||||
|
||||
openocd -f board/ti_am625evm.cfg
|
||||
@@ -33,6 +33,7 @@ K3 Based SoCs
|
||||
am62ax_sk
|
||||
am62x_sk
|
||||
am62px_sk
|
||||
am6254atl_sk
|
||||
am64x_evm
|
||||
am65x_evm
|
||||
j7200_evm
|
||||
|
||||
Reference in New Issue
Block a user