Commit Graph

85724 Commits

Author SHA1 Message Date
Alexandre Bard c1e4d617ac fix the right variable 2024-02-13 15:18:41 +01:00
Alexandre Bard 033c2f0eca debug 2024-02-13 14:59:11 +01:00
Alexandre Bard 66aeba5533 Again 2024-02-13 13:22:03 +01:00
Alexandre Bard 82865559d7 increase malloc size for r5 2024-02-13 12:51:32 +01:00
Alexandre Bard db1e290891 hw34_defconfig: Increase malloc size
With EFI configs, there was not enough space for loading u-boot
2024-02-13 11:46:34 +01:00
Samuel Dolt 5fdf57516a rename genimi to hw34 2024-02-12 16:26:19 +01:00
Stefan Eichenberger 04eb56941b gemini: board: add board and device tree
Add gemini as new am64x board including, board configuration, devicetree
and configuration.
2024-01-11 14:10:11 +01:00
Praneeth Bajjuri b0d717b732 configs: am62*_r5_usbmsc_defconfig: Set SPL_STACK_R_MALLOC_SIMPLE_LEN to 2M
Size of malloc was standardized to 2M for all am6*_r5_*_defconfigs, but
USB MSC defconfig was missed, update this config option now.

Fixes: 794614311a (configs: am6*_r5_defconfig: Standardize SPL_STACK_R_MALLOC_SIMPLE_LEN to 2M)

Signed-off-by: Praneeth Bajjuri <praneeth@ti.com>
2023-12-06 09:11:45 -06:00
Hari Nagalla 14f637b36b board: ti: am62p: Add FW name for MCU R5 remoteproc
Provide MCU R5 firmware name for u-boot loading of MCU remote core.

Signed-off-by: Hari Nagalla <hnagalla@ti.com>
2023-12-06 09:11:39 -06:00
Judith Mendez d83580ffea configs: am62ax_r5_usbdfu_defconfig: Sync USB-DFU with default defconfig
Size of malloc was standardized to 2M for all am6*_r5_defconfigs, but
USB DFU defconfig was missed, update this config option now.

The following warning can be seen with usb-dfu boot:

SPL possible initial stack overflow detected!!

so increase SIZE_LIMIT_PROVIDE_STACK to match the default defconfig.

Fixes: 794614311a (configs: am6*_r5_defconfig: Standardize SPL_STACK_R_MALLOC_SIMPLE_LEN to 2M)
Fixes: beee241868 (configs: am62ax: Add a new USB DFU defconfig)

Signed-off-by: Judith Mendez <jm@ti.com>
2023-12-06 09:10:37 -06:00
Judith Mendez 97083e42dc configs: am62x_r5_usbdfu_defconfig: Set SPL_STACK_R_MALLOC_SIMPLE_LEN to 2M
Size of malloc was standardized to 2M for all am6*_r5_defconfigs, but
USB DFU defconfig was missed, update this config option now.

Fixes: 794614311a (configs: am6*_r5_defconfig: Standardize SPL_STACK_R_MALLOC_SIMPLE_LEN to 2M)

Signed-off-by: Judith Mendez <jm@ti.com>
2023-12-06 09:10:06 -06:00
Judith Mendez 9988250625 configs: am62px: Enable UHS configs for mmc1
Enable UHS support in the am62p5 defconfigs, allowing us to enter
the UHS modes for mmc1.

Signed-off-by: Judith Mendez <jm@ti.com>
2023-12-06 09:08:16 -06:00
Judith Mendez 53922d6b9f arm: dts: k3-am62p5-sk: remove no-1-8 for mmc1
Remove no-1-8 dts attribute for mmc1, allowing us to enter
the UHS mode.

Signed-off-by: Judith Mendez <jm@ti.com>
2023-12-06 09:07:53 -06:00
Judith Mendez 8177a2638b arm: dts: k3-am62p: add dll delay mapping for mmc
Add the input and output delay values for the available speed modes
for the MMC controller for mmc1/mmc2 for the am62p5 allowing it
to operate at the highest speed modes available, exclude SDR12 since
the speed mode did pass validation.

The higher speed modes have not been finalized yet, but the process
is to set the base value, then update if characterization says
otherwise.

For mmc0, sync with TI's v6.1 kernel.

Signed-off-by: Judith Mendez <jm@ti.com>
2023-12-06 09:07:37 -06:00
Udit Kumar eaa1840097 arm: k3: j721s2: Enable AVS
Enable AVS in config and probing of AVS node.

Signed-off-by: Udit Kumar <u-kumar1@ti.com>
2023-12-06 09:07:17 -06:00
Udit Kumar 2b8ba79e4a arm: dts: k3-j721s2-r5-common-proc-board: Add avs and buck node
Add AVS and buck node.

Signed-off-by: Udit Kumar <u-kumar1@ti.com>
2023-12-06 09:07:10 -06:00
Udit Kumar ba820aee38 driver: misc: k3_avs: Add J721S2 support
Adding AVS support for J721S2 SOC.

Signed-off-by: Udit Kumar <u-kumar1@ti.com>
2023-12-06 09:07:02 -06:00
Roger Quadros d231dfe971 configs: am64x_evm_a53_defconfig: Fix USB DFU boot
Increasing SPL_STACK_R_MALLOC_SIMPLE_LEN to 16M seems to break
USB DFU boot. The default of 4M seems to be OK for NAND case
as well so stick to defaults.

Reported-by: Ravi Gunasekaran <r-gunasekaran@ti.com>
Fixes: b1ba64d9ba ("configs: am64x_evm_a53_defconfig: add SPL_LOAD_FIT_APPLY_OVERLAY")
Signed-off-by: Roger Quadros <rogerq@kernel.org>
Reviewed-by: Judith Mendez <jm@ti.com>
Tested-by: Ravi Gunasekaran <r-gunasekaran@ti.com>
2023-12-06 09:06:31 -06:00
Vishal Mahaveer c1c2bdf272 board: ti: am62x/am62ax: Update MCU GPIO interrupt allocation in board config
Share the MCU GPIO interrupts between A53 core and DM R5 core. Allocating
2 instances each to A53 and DM R5.

Signed-off-by: Vishal Mahaveer <vishalm@ti.com>
2023-11-30 12:17:44 -06:00
Vishal Mahaveer 87830ba3dc board: ti: am62ax: Add C7x resource allocation entries to board config
Update am62ax rm-cfg with allocation entries for C7x core. Following
updates are added for C7x:
- Share split BCDMA tx and rx channels between DM R5 and C7x
- Share rings for split BCDMA tx and rx channels between DM R5 and C7x
- Add Global events and Virtual interrupts for C7x

Signed-off-by: Vishal Mahaveer <vishalm@ti.com>
2023-11-30 12:17:44 -06:00
Vishal Mahaveer 528eaab694 board: ti: am62x/am62ax: Formatting updates to board config files
Minor formatting updates to the rm board configuration file for
am62x and am62ax boards.

Signed-off-by: Vishal Mahaveer <vishalm@ti.com>
2023-11-30 12:17:44 -06:00
Vishal Mahaveer 46efc2a85b Revert "board: ti: rm-cfg: Update to latest configuration"
This reverts commit eff76d94a3.

This patch brought in cumulative updates from resource-partitioning
tool, including a change for latest TIFS firmware (v09.01.07) which
breaks backward compatibility. The TIFS firmware is updated to revert
the change that caused backward compatibility break (v09.01.08).

Reverting this patch and bringing in the updates (minus the change done
for the compatibility breaking TIFS firmware) in granular patches
subsequently.

Signed-off-by: Vishal Mahaveer <vishalm@ti.com>
2023-11-30 12:17:44 -06:00
Guillaume La Roque a9361b412f configs: am62x_evm_android: add extrasize for applying dt overlay
Actually we just do a resize to fix issue when apply overlay on device
tree without any free space but if overlay take more place as default
extra size added fdt apply will fail.

So to fix this issue add extra size corresponding to page size.

Signed-off-by: Guillaume La Roque <glaroque@baylibre.com>
Acked-by: Vishal Mahaveer <vishalm@ti.com>
Reviewed-by: Mattijs Korpershoek <mkorpershoek@baylibre.com>
Tested-by: Mattijs Korpershoek <mkorpershoek@baylibre.com>
2023-11-30 12:10:59 -06:00
Markus Schneider-Pargmann 4fda02e747 arm: mach-k3: Remove CANUART IO isolation
After leaving the Partial-IO mode or other deep sleep states, the IO
isolation needs to be removed. This routine is shared by at least am62,
am62a and am62p.

The original function for testing was developed by
Akashdeep Kaur <a-kaur@ti.com>

Signed-off-by: Markus Schneider-Pargmann <msp@baylibre.com>
Reviewed-by: Dhruva Gole <d-gole@ti.com>
2023-11-28 12:34:52 -06:00
Bryan Brattlof 77053f97e0 ram: k3-ddrss: do not touch ctrl regs during training
commit af7c33c103450e06aecf8adba8cbc8c522295be1 upstream.

During LPDDR initialization we will loop through a series of frequency
changes in order to train at the various operating frequencies. During
this training, accessing the DRAM_CLASS bitfield could happen during a
frequency change and cause the read to hang.

Store the DRAM type into the main structure to avoid multiple readings
while the independent phy is training.

Signed-off-by: Bryan Brattlof <bb@ti.com>
[praneeth@ti.com: cherrypick from v2023.10]
Signed-off-by: Praneeth Bajjuri <praneeth@ti.com>
2023-11-28 11:36:12 -06:00
Vignesh Raghavendra 71b8c840ca configs: am62x_evm_a53_defconfig: Increase DFU buffer size to 256K
OSPI Flashes have 256K sector size, match the DFU buffer size to the
same so that entire sector can be written at once.

W/o this OSPI DFU update fails with timeouts like
=> setenv dfu_alt_info ${dfu_alt_info_ospi}; dfu 0 sf 0:0;

Signed-off-by: Vignesh Raghavendra <vigneshr@ti.com>
2023-11-27 14:25:35 +05:30
Dhruva Gole e8889cb56a arm: dts: k3: binman: am62p: add support for signing FSSTUB images
Add support for signing, detection and loading of FSSTUB images for
for HSSE and HSFS AM62P devices. Based on the binman code for AM625
with updates to the filenames and load address.

Signed-off-by: Dhruva Gole <d-gole@ti.com>
Acked-by: Vishal Mahaveer <vishalm@ti.com>
2023-11-24 16:56:59 -06:00
Vishal Mahaveer eff76d94a3 board: ti: rm-cfg: Update to latest configuration
Update RM boardcfg to latest output from k3-resource-partitioning
tool for am62, am62ax and am62px devices.

Commit SHA of k3-resource-partitioning tool:
e8dcac2413f918aad02298fbe476891c71823c41

Signed-off-by: Vishal Mahaveer <vishalm@ti.com>
Tested-by: Dhruva Gole <d-gole@ti.com> #am62px
2023-11-24 16:56:35 -06:00
Roger Quadros c0176ab8dd mtd: nand: omap_gpmc: Fix NAND in SPL for AM335x
AM335x uses a special driver "am335x_spl_bch.c" as SPL
NAND loader. This driver expects 1 sector at a time ECC
and doesn't work well with multi-sector ECC that was implemented
in commit 04fcd25873.

Switch back to 1 sector at a time read/ECC.

Fixes: 04fcd25873 ("mtd: rawnand: omap_gpmc: Fix BCH6/16 HW based correction")
Signed-off-by: Roger Quadros <rogerq@kernel.org>
2023-11-24 16:54:00 -06:00
Roger Quadros 2d30da97ed environment: ti: k3_dfu_combined.env: add dfu_alt_info_ospi_nand
Copy this over from k3_dfu.env.

Signed-off-by: Roger Quadros <rogerq@kernel.org>
2023-11-24 16:53:29 -06:00
Roger Quadros 154ecd8648 environment: ti: k3_dfu_combined.env: add dfu_alt_info_nand
Copy this over from k3_dfu.env.

Signed-off-by: Roger Quadros <rogerq@kernel.org>
2023-11-24 16:53:29 -06:00
Roger Quadros bc8d0eb32d environment: ti: am64x: Fix mtdids and mtdparts
mtdids and mtdparts defined in nand.env are not suitable
for am64x-evm. Define its own here.

We deliberately don't define spi.nor partitions here as
it causes mtdparts and dfu to fail till user has done
"sf probe" command. This is because NOR flash is not
auto probed by u-boot.

Signed-off-by: Roger Quadros <rogerq@kernel.org>
2023-11-24 16:53:29 -06:00
Roger Quadros b8cf525335 configs/am64x_evm_a53_defconfig: Enable NAND DFU
Enable NAND support for DFU.

Signed-off-by: Roger Quadros <rogerq@kernel.org>
2023-11-24 16:53:29 -06:00
Roger Quadros ca69452f7a tools/fdtgrep: Include __symbols__ table
This is required for overlays to work at SPL.

Loading of symbol table depends on DT Overlay support in SPL
so make it compile-time dependent. Without this SPL fails to
boot some platforms where this feature is not enabled
(e.g. dra71-evm.)

Without including the <linux/kconfig.h> file, the symbol
CONFIG_SPL_LOAD_FIT_APPLY_OVERLAY will not be visible and
we will never include the symbol table.

So include <linux/kconfig.h>

Due to some reason it needs to be included after
[#include "fdt_host.h"] otherwise it causes a build error.

Signed-off-by: Roger Quadros <rogerq@kernel.org>
2023-11-24 16:53:29 -06:00
Roger Quadros 2bf80af7a9 configs: am64x_evm: provide NAND configuration
Provide NAND device and NAND driver configuration for AM64x EVM.

Signed-off-by: Roger Quadros <rogerq@kernel.org>
2023-11-24 16:53:29 -06:00
Roger Quadros 1feeea360e configs: am64x_evm_a53_defconfig: Enable NAND
Enables configuration required for NAND in SPL and u-boot.

Enable MTD Driver model and MTD + UBI command line utilities.

Add mtdids/mtdparts for NAND as it is required for u-boot's
MTD subsystem commands to recognize NAND partitions.

Add u-boot partition location.

Signed-off-by: Roger Quadros <rogerq@kernel.org>
2023-11-24 16:53:29 -06:00
Roger Quadros b1ba64d9ba configs: am64x_evm_a53_defconfig: add SPL_LOAD_FIT_APPLY_OVERLAY
We want SPL to apply DTB overlays (e.g. NAND card overlay) so
enable SPL_LOAD_FIT_APPLY_OVERLAY.
Increase SPL_LOAD_FIT_APPLY_OVERLAY_BUF_SZ and
SPL_STACK_R_MALLOC_SIMPLE_LEN. Without this SPL hangs.

Signed-off-by: Roger Quadros <rogerq@kernel.org>
2023-11-24 16:53:29 -06:00
Roger Quadros 63c591d6f5 board: ti: am64: select NAND overlay if HSE card present
Since we are using overlay for A53 SPL and A53 u-boot the
SPL must select the NAND overlay from the FIT image if
HSE card is present.

Signed-off-by: Roger Quadros <rogerq@kernel.org>
2023-11-24 16:53:29 -06:00
Roger Quadros d507c6b2ba arm: dts: k3-am64x-binman: Add NAND overlay and configuration
Add NAND overlay and configuration to tispl and u-boot images.

Signed-off-by: Roger Quadros <rogerq@kernel.org>
2023-11-24 16:53:29 -06:00
Roger Quadros 40e776a36d arm: dts: k3-am642-evm: Add NAND support
Add NAND support for A53 SPL and u-boot.

For A53 SPL & u-boot we use NAND overlay to add NAND support.

Signed-off-by: Roger Quadros <rogerq@kernel.org>
2023-11-24 16:53:29 -06:00
Roger Quadros cc471479d3 arm: dts: k3-am642: main_i2c0 cleanup
move main_i2c0, main-i2c0-pins-default, and tca9554
definitions to where they belong i.e. k3-am642-evm.dts

k3-am642-r5-evm.dts is not cleaned up like in upstream
to include k3-am642-evm.dts so we have to add the
main-i2c0-pins-default and tca9554 nodes to it
as well.

Signed-off-by: Roger Quadros <rogerq@kernel.org>
2023-11-24 16:53:29 -06:00
Roger Quadros 189bd2cc06 arm: mach-k3: am642: Define NAND boot device
AM642 SoC supports booting from GPMC NAND device.
Define boot device for it.

Signed-off-by: Roger Quadros <rogerq@kernel.org>
2023-11-24 16:53:29 -06:00
Udit Kumar 3c8e18effc remoteproc: k3-dsp: Avoid reloading of firmware
DSP core is going into abnormal state when load callback is called
after starting of DSP core.
Reload of firmware needs core to be stopped first, followed by
load.
So avoid loading of firmware, when core is started.

Signed-off-by: Udit Kumar <u-kumar1@ti.com>
Reviewed-by: Apurva Nandan <a-nandan@ti.com>
2023-11-24 16:52:21 -06:00
Vignesh Raghavendra c97fa5cd4a mach-k3: am62p5_init: Add emmc boot support
Add spl_mmc_boot_mode() to help distinguish eMMC raw boot mode.

Signed-off-by: Vignesh Raghavendra <vigneshr@ti.com>
2023-11-24 16:50:51 -06:00
Vignesh Raghavendra 5e27b6be65 configs: am62px_evm_a53_defconfig: Enable PHY support of cadence-qspi
Enable support for using PHY mode in cadence-qspi driver for better data
rate.

Signed-off-by: Vignesh Raghavendra <vigneshr@ti.com>
2023-11-23 14:49:54 +05:30
Vignesh Raghavendra 4209cce84e arm: dts: k3-am62p5-sk: Enable OSPI PHY mode
Enable OSPI PHY mode for faster boot time as PHY mode supports upto
166MHz of OSPI bus freq.

Signed-off-by: Vignesh Raghavendra <vigneshr@ti.com>
2023-11-23 14:49:54 +05:30
Vignesh Raghavendra 66551ea574 arm: dts: k3-am62p5-r5-sk: Add 32bit OSPI DATA region
Add 32bit OSPI DATA region which enables R5 to access OSPI

Signed-off-by: Vignesh Raghavendra <vigneshr@ti.com>
2023-11-23 14:49:54 +05:30
Vignesh Raghavendra 34e454793f arm: dts: am62p5-r5-sk: Add DMA support at R5 SPL
OSPI boot requires DMA for faster boot up at R5 SPL stage. Enable the
same.

Signed-off-by: Vignesh Raghavendra <vigneshr@ti.com>
Reviewed-by: Dhruva Gole <d-gole@ti.com>
2023-11-23 14:49:54 +05:30
Vignesh Raghavendra d65ac3de81 arm: dts: k3-am62p-r5-sk: Fix secproxy thread ID for DM2TIFS comm
Per [0] thread IDs should be 20 and 21. Update the same

[0] https://software-dl.ti.com/tisci/esd/latest/5_soc_doc/am62px/sec_proxy.html#secure-proxy-thread-allocation-for-dmass0-sec-proxy-0

Fixes: bc763e60eb ("arm: dts: introduce am62p5 uboot dts files")
Signed-off-by: Vignesh Raghavendra <vigneshr@ti.com>
2023-11-23 14:49:54 +05:30
Judith Mendez 057d19e56d environment: ti: k3_dfu_combined.env: Fix env offset for eMMC
The following shall be the eMMC layout for AM64x platform:

            boot0 partition
    0x0+----------------------------------+
       |     tiboot3.bin (1 MB)           |
  0x800+----------------------------------+
       |       tispl.bin (2 MB)           |
0x1800+-----------------------------------+
       |       u-boot.img (4 MB)          |
0x3800+-----------------------------------+
       |      environment (128 KB)        |
0x3900+-----------------------------------+

Move u-boot environment from 0x3400 to ox3800 since at 0x3400
it overlaps with u-boot.img.

Signed-off-by: Judith Mendez <jm@ti.com>
2023-11-22 20:37:55 +05:30