]> git.ipfire.org Git - thirdparty/u-boot.git/commit
board: adi: Fix exception when using standalone SoM
authorPhilip Molloy <philip.molloy@analog.com>
Wed, 1 Apr 2026 09:31:56 +0000 (09:31 +0000)
committerTom Rini <trini@konsulko.com>
Wed, 22 Apr 2026 20:22:33 +0000 (14:22 -0600)
commit1994e69d4e5b8b8bb01436b6b8e7ddf42d8e4785
tree60556bc4d510dfa1f53d0fc2f9c07f646d5f3308
parent58e523fedf48a304b54c4e42e46fd88d072f8751
board: adi: Fix exception when using standalone SoM

Although less common, ADSP SoM boards can be operated standalone without
a carrier board. The SoM can be powered over USB-C by moving the jumper
on JP1.

The board configuration needs to be heavily refactored to reduce the
number of defconfigs and leverage the devicetree. The TI DP83867
support, which is dependent on that configuration, needs to be removed.
Until then this change allows the same U-Boot binary to work correctly
both with carrier boards and the standalone SoM.

The carrier board initialization code in somcrr_ezkit.c and
somcrr_ezlite.c calls gpio_hog_lookup_name() to find ethernet
control GPIOs, but does not check if the lookup succeeds before
using the returned pointers.

When running on a standalone SoM without a carrier board, these
GPIO hogs do not exist in the device tree. The gpio_hog_lookup_name()
function returns -ENODEV and sets the pointer to NULL, but the code
continues to call dm_gpio_set_value() with uninitialized pointers,
causing a synchronous abort exception:

  "Synchronous Abort" handler, esr 0x96000004
  elr: 00000000960326c4 lr : 0000000096038d5c (reloc)

Signed-off-by: Philip Molloy <philip.molloy@analog.com>
Reviewed-by: Greg Malysa <malysagreg@gmail.com>
board/adi/carriers/somcrr_ezkit.c
board/adi/carriers/somcrr_ezlite.c