This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

SK-AM64B: Problem with u-boot 2024/2025 and I2C

Part Number: SK-AM64B

Tool/software:

Hello,
We’ve encountered a strange issue with I2C—initially on our custom boards (with our custom builds), and later also on the SK-AM64B board when using default images. The problem occurs in all tested U-Boot versions 2024.04 and 2025.01, but is not present in 2023.04.

The observed behavior is as follows:

U-Boot 2023.04-ti-g836606420854 (May 09 2024 - 05:42:45 +0000)

SoC:   AM64X SR2.0 HS-FS
Model: Texas Instruments AM642 SK
Board: AM64B-SKEVM rev A
DRAM:  2 GiB
Core:  90 devices, 33 uclasses, devicetree: separate
NAND:  0 MiB
MMC:   mmc@fa00000: 1
Loading Environment from nowhere... OK
In:    serial@2800000
Out:   serial@2800000
Err:   serial@2800000
Net:   eth0: ethernet@8000000port@1, eth1: ethernet@8000000port@2
Hit any key to stop autoboot:  0
=>
=> i2c probe
Valid chip addresses: 30 51
=> i2c bus
Bus 0:  i2c@20000000  (active 0)
   30: pmic@30, offset len 1, flags 0
   51: generic_51, offset len 1, flags 0
Bus 1:  i2c@20010000
   70: gpio@70, offset len 1, flags 0
=>

but with u-boot 2025.01:

U-Boot 2025.01-00406-gcd91d7360181 (Mar 25 2025 - 16:14:37 +0000)

SoC:   AM64X SR2.0 HS-FS
Model: Texas Instruments AM642 SK
Board: AM64B-SKEVM rev A
DRAM:  2 GiB
Core:  95 devices, 33 uclasses, devicetree: separate
MMC:   mmc@fa00000: 1
Loading Environment from nowhere... OK
In:    serial@2800000
Out:   serial@2800000
Err:   serial@2800000
Failed to probe prueth driver
Net:   eth0: ethernet@8000000port@1, eth1: ethernet@8000000port@2
Hit any key to stop autoboot:  0
=> i2c probe
ti_sci system-controller@44043000: Message not acknowledged
ti-sci-pm-domains power-controller: ti_sci_power_domain_on: get_device(102) failed (-19)
Default I2C bus 0 not found
=> i2c bus
Bus 0:  i2c@20000000
Bus 1:  i2c@20010000  (active 1)
   70: gpio@70, offset len 1, flags 0
=>

I understand that the default image initially uses the EVM board device tree, and after board detection is completed, it switches to the SK board device tree.
We’re seeing a similar issue on our custom boards. The problem appears to be related to which default device tree is used before board detection takes place. We have two board revisions: r0 and r1.
If we set the r0 device tree as the default, then I2C0 works on r0 boards but fails on r1 boards. Conversely, if we set the r1 device tree as the default, I2C0 works on r1 boards but fails on r0 boards.