Skip to contentSkip to conversation

k3-am62-pocketbeagle2: add board and variant support

PATCH Superseded [email protected] 4 participants 10 messages Jun 24 – Jun 30

Subsystems (2)

v3 of 5 Superseded Latest is v5 →

lore
Share & tools
lore
#0 lore raw

v3 cover k3-am62-pocketbeagle2: add board and variant support

From: Randolph Sapp <[email protected]>

Add initial board support for the PocketBeagle 2 from BeagleBoard.org. This is based on the current official series from Robert Nelson [1] and work from Bryan Brattlof [2] with some light modifications to protect against certain configurations changes.

This borrows a lot from Phytec's current DDR fixup logic, as that seems to be the most complete implementation of a dynamic DDR correction for K3 in tree currently. Thanks Wadim Egorov and Dominik Haller for setting that up.

Now that the various memory issues have been resolved we can clearly see at runtime that there's an issue with the current device. One of our reservations overlaps with the u-boot stack. To get around this we'll need to change the relocation address to something we know will not collide.

[1] https://github.com/beagleboard/u-boot/tree/v2026.01-am62-pocketbeagle2
[2] https://github.com/bryanbrattlof/beagleboot/tree/b4/pb2i

Bryan Brattlof (1):
arm: mach-k3: am62: add &main_uart6 to clock and pwr tree

Randolph Sapp (3):
k3-am62-pocketbeagle2: add initial board support
k3-am62-pocketbeagle2: add support for 1GB variant
k3-am62-pocketbeagle2: add support for efi capsules

 arch/arm/dts/Makefile                         |   1 +
 ...> k3-am62-pocketbeagle2-ddr4-1600MTs.dtsi} |  92 ++---
 .../arm/dts/k3-am62-pocketbeagle2-u-boot.dtsi | 336 ++++++++++++++++++
 arch/arm/dts/k3-am62-r5-pocketbeagle2.dts     |  35 ++
 arch/arm/mach-k3/am62x/Kconfig                |   1 +
 arch/arm/mach-k3/r5/am62x/clk-data.c          |  19 +-
 arch/arm/mach-k3/r5/am62x/dev-data.c          |   5 +-
 board/beagle/pocketbeagle2/Kconfig            |  86 +++++
 board/beagle/pocketbeagle2/MAINTAINERS        |  10 +
 board/beagle/pocketbeagle2/Makefile           |  11 +
 .../board-cfg.yaml                            |   0
 .../{beagleplay => pocketbeagle2}/pm-cfg.yaml |   0
 board/beagle/pocketbeagle2/pocketbeagle2.c    | 185 ++++++++++
 .../pocketbeagle2/pocketbeagle2.env}          |  20 +-
 .../beagle/pocketbeagle2/pocketbeagle2_ddr.h  |  50 +++
 .../pocketbeagle2}/rm-cfg.yaml                |   4 +-
 .../sec-cfg.yaml                              |   0
 ...onfig => am62_pocketbeagle2_a53_defconfig} |  25 +-
 ...config => am62_pocketbeagle2_r5_defconfig} |  16 +-
 doc/board/beagle/am62_pocketbeagle2.rst       | 279 +++++++++++++++
 doc/board/beagle/index.rst                    |   1 +
 include/configs/pocketbeagle2.h               |  39 ++
 22 files changed, 1132 insertions(+), 83 deletions(-)
 copy arch/arm/dts/{k3-am62x-sk-ddr4-1600MTs.dtsi => k3-am62-pocketbeagle2-ddr4-1600MTs.dtsi} (97%)
 create mode 100644 arch/arm/dts/k3-am62-pocketbeagle2-u-boot.dtsi
 create mode 100644 arch/arm/dts/k3-am62-r5-pocketbeagle2.dts
 create mode 100644 board/beagle/pocketbeagle2/Kconfig
 create mode 100644 board/beagle/pocketbeagle2/MAINTAINERS
 create mode 100644 board/beagle/pocketbeagle2/Makefile
 copy board/beagle/{beagleplay => pocketbeagle2}/board-cfg.yaml (100%)
 copy board/beagle/{beagleplay => pocketbeagle2}/pm-cfg.yaml (100%)
 create mode 100644 board/beagle/pocketbeagle2/pocketbeagle2.c
 copy board/{ti/am62x/am62x.env => beagle/pocketbeagle2/pocketbeagle2.env} (64%)
 create mode 100644 board/beagle/pocketbeagle2/pocketbeagle2_ddr.h
 copy board/{phytec/phycore_am62x => beagle/pocketbeagle2}/rm-cfg.yaml (99%)
 copy board/beagle/{beagleplay => pocketbeagle2}/sec-cfg.yaml (100%)
 copy configs/{am62x_beagleplay_a53_defconfig => am62_pocketbeagle2_a53_defconfig} (88%)
 copy configs/{am62x_beagleplay_r5_defconfig => am62_pocketbeagle2_r5_defconfig} (86%)
 create mode 100644 doc/board/beagle/am62_pocketbeagle2.rst
 create mode 100644 include/configs/pocketbeagle2.h
Signature · 1 line
2.54.0
#1 lore raw

PATCH v3 1/4 arm: mach-k3: am62: add &main_uart6 to clock and pwr tree

From: Bryan Brattlof <[email protected]>

The pocketbeagle2 uses the main_uart6 as the debug console. To get debug console prints at the R5 SPL stage, add the &main_uart6 to the R5 clk and dev data so we can configure the uart as early as possible during the bootup of the pocketbeagle2

---
 arch/arm/mach-k3/r5/am62x/clk-data.c | 19 +++++++++++++++----
 arch/arm/mach-k3/r5/am62x/dev-data.c |  5 +++--
 2 files changed, 18 insertions(+), 6 deletions(-)
arch/arm/mach-k3/r5/am62x/clk-data.c +15 -4
index d7bfed0e031c..05cced0b313b 100644
@@ -3,9 +3,9 @@
  * AM62X specific clock platform data
  *
  * This file is auto generated. Please do not hand edit and report any issues
- * to Dave Gerlach <[email protected]>.
+ * to Bryan Brattlof <[email protected]>.
  *
- * Copyright (C) 2020-2022 Texas Instruments Incorporated - https://www.ti.com/
+ * Copyright (C) 2020-2025 Texas Instruments Incorporated - https://www.ti.com/
  */
 
 #include <linux/clk-provider.h>
@@ -125,6 +125,11 @@ static const char * const main_usart0_fclk_sel_out0_parents[] = {
 	"hsdiv4_16fft_main_1_hsdivout1_clk",
 };
 
+static const char * const main_usart6_fclk_sel_out0_parents[] = {
+	"usart_programmable_clock_divider_out6",
+	"hsdiv4_16fft_main_1_hsdivout1_clk",
+};
+
 static const struct clk_data clk_list[] = {
 	CLK_FIXED_RATE("osc_26_mhz", 26000000, 0),
 	CLK_FIXED_RATE("osc_25_mhz", 25000000, 0),
@@ -210,9 +215,11 @@ static const struct clk_data clk_list[] = {
 	CLK_MUX("main_gtcclk_sel_out0", main_gtcclk_sel_out0_parents, 8, 0x43008030, 0, 3, 0),
 	CLK_MUX("main_ospi_ref_clk_sel_out0", main_ospi_ref_clk_sel_out0_parents, 2, 0x108500, 0, 1, 0),
 	CLK_DIV_DEFFREQ("usart_programmable_clock_divider_out0", "hsdiv4_16fft_main_1_hsdivout0_clk", 0x108240, 0, 2, 0, 0, 48000000),
+	CLK_DIV_DEFFREQ("usart_programmable_clock_divider_out6", "hsdiv4_16fft_main_1_hsdivout0_clk", 0x108258, 0, 2, 0, 0, 48000000),
 	CLK_MUX("wkup_clkout_sel_out0", wkup_clkout_sel_out0_parents, 8, 0x43008020, 0, 3, 0),
 	CLK_MUX("wkup_clksel_out0", wkup_clksel_out0_parents, 2, 0x43008010, 0, 1, 0),
 	CLK_MUX("main_usart0_fclk_sel_out0", main_usart0_fclk_sel_out0_parents, 2, 0x108280, 0, 1, 0),
+	CLK_MUX("main_usart6_fclk_sel_out0", main_usart6_fclk_sel_out0_parents, 2, 0x108298, 0, 1, 0),
 	CLK_DIV("hsdiv4_16fft_mcu_0_hsdivout1_clk", "pllfracf_ssmod_16fft_mcu_0_foutvcop_clk", 0x4040084, 0, 7, 0, 0),
 	CLK_FIXED_RATE("mshsi2c_wkup_0_porscl", 0, 0),
 	CLK_DIV("sam62_pll_ctrl_wrap_main_0_chip_div24_clk_clk", "sam62_pll_ctrl_wrap_main_0_sysclkout_clk", 0x41011c, 0, 5, 0, 0),
@@ -336,6 +343,10 @@ static const struct dev_clk soc_dev_clk_data[] = {
 	DEV_CLK(157, 164, "clk_32k_rc_sel_out0"),
 	DEV_CLK(157, 165, "gluelogic_rcosc_clkout"),
 	DEV_CLK(157, 166, "gluelogic_hfosc0_clkout"),
+	DEV_CLK(158, 0, "main_usart6_fclk_sel_out0"),
+	DEV_CLK(158, 1, "usart_programmable_clock_divider_out6"),
+	DEV_CLK(158, 2, "hsdiv4_16fft_main_1_hsdivout1_clk"),
+	DEV_CLK(158, 5, "sam62_pll_ctrl_wrap_main_0_chip_div1_clk_clk"),
 	DEV_CLK(161, 0, "sam62_pll_ctrl_wrap_main_0_chip_div1_clk_clk"),
 	DEV_CLK(161, 1, "sam62_pll_ctrl_wrap_main_0_chip_div1_clk_clk"),
 	DEV_CLK(161, 2, "sam62_pll_ctrl_wrap_main_0_chip_div1_clk_clk"),
@@ -361,7 +372,7 @@ static const struct dev_clk soc_dev_clk_data[] = {
 
 const struct ti_k3_clk_platdata am62x_clk_platdata = {
 	.clk_list = clk_list,
-	.clk_list_cnt = 90,
+	.clk_list_cnt = 92,
 	.soc_dev_clk_data = soc_dev_clk_data,
-	.soc_dev_clk_data_cnt = 137,
+	.soc_dev_clk_data_cnt = 140,
 };
arch/arm/mach-k3/r5/am62x/dev-data.c +3 -2
index 59c95df2a887..ea1e76a8a758 100644
@@ -3,9 +3,9 @@
  * AM62X specific device platform data
  *
  * This file is auto generated. Please do not hand edit and report any issues
- * to Dave Gerlach <[email protected]>.
+ * to Bryan Brattlof <[email protected]>.
  *
- * Copyright (C) 2020-2022 Texas Instruments Incorporated - https://www.ti.com/
+ * Copyright (C) 2020-2025 Texas Instruments Incorporated - https://www.ti.com/
  */
 
 #include "k3-dev.h"
@@ -61,6 +61,7 @@ static struct ti_dev soc_dev_list[] = {
 	PSC_DEV(36, &soc_lpsc_list[11]),
 	PSC_DEV(102, &soc_lpsc_list[11]),
 	PSC_DEV(146, &soc_lpsc_list[11]),
+	PSC_DEV(158, &soc_lpsc_list[11]),
 	PSC_DEV(13, &soc_lpsc_list[12]),
 	PSC_DEV(166, &soc_lpsc_list[13]),
 	PSC_DEV(135, &soc_lpsc_list[14]),
Signature · 1 line
2.54.0
#2 lore raw

PATCH v3 2/4 k3-am62-pocketbeagle2: add initial board support

In reply to [email protected]

From: Randolph Sapp <[email protected]>

Add initial board support for the PocketBeagle 2, based on Robert Nelson and Bryan Brattlof's work. Unify all debug consoles to main_uart6. Use DDR config v10.32 from our sysconfig tool [1] for Kingston's memory [2], (4Gb Desnity with a CL of 11 and CWL of 9). Add support for the SPL_TEXT_BASE config parameter. Ensure all files have a summary and SPDX identifier.

Also, use board_get_usable_ram_top() to fixup our relocaddr since otherwise the u-boot stack reservation will collide with the wkup_r5fss0_core0_memory_region.

[1] https://dev.ti.com/sysconfig
[2] https://mm.digikey.com/Volume0/opasdata/d220001/medias/docus/6465/D2516AN9EXGXN-TU.pdf

---
v3:
- Use board_get_usable_ram_top

---
 arch/arm/dts/Makefile                         |   1 +
 ...> k3-am62-pocketbeagle2-ddr4-1600MTs.dtsi} |  92 +++---
 ...dtsi => k3-am62-pocketbeagle2-u-boot.dtsi} | 160 ++++++----
 arch/arm/dts/k3-am62-r5-pocketbeagle2.dts     |  35 +++
 arch/arm/mach-k3/am62x/Kconfig                |   1 +
 board/beagle/pocketbeagle2/Kconfig            |  60 ++++
 board/beagle/pocketbeagle2/MAINTAINERS        |  10 +
 board/beagle/pocketbeagle2/Makefile           |   9 +
 .../board-cfg.yaml                            |   0
 .../{beagleplay => pocketbeagle2}/pm-cfg.yaml |   0
 board/beagle/pocketbeagle2/pocketbeagle2.c    |  58 ++++
 .../pocketbeagle2/pocketbeagle2.env}          |  20 +-
 .../pocketbeagle2}/rm-cfg.yaml                |   4 +-
 .../sec-cfg.yaml                              |   0
 ...onfig => am62_pocketbeagle2_a53_defconfig} |  24 +-
 ...config => am62_pocketbeagle2_r5_defconfig} |  11 +-
 doc/board/beagle/am62_pocketbeagle2.rst       | 279 ++++++++++++++++++
 doc/board/beagle/index.rst                    |   1 +
 .../configs/{beagley_ai.h => pocketbeagle2.h} |   8 +-
 19 files changed, 636 insertions(+), 137 deletions(-)
 copy arch/arm/dts/{k3-am62x-sk-ddr4-1600MTs.dtsi => k3-am62-pocketbeagle2-ddr4-1600MTs.dtsi} (97%)
 copy arch/arm/dts/{k3-am67a-beagley-ai-u-boot.dtsi => k3-am62-pocketbeagle2-u-boot.dtsi} (53%)
 create mode 100644 arch/arm/dts/k3-am62-r5-pocketbeagle2.dts
 create mode 100644 board/beagle/pocketbeagle2/Kconfig
 create mode 100644 board/beagle/pocketbeagle2/MAINTAINERS
 create mode 100644 board/beagle/pocketbeagle2/Makefile
 copy board/beagle/{beagleplay => pocketbeagle2}/board-cfg.yaml (100%)
 copy board/beagle/{beagleplay => pocketbeagle2}/pm-cfg.yaml (100%)
 create mode 100644 board/beagle/pocketbeagle2/pocketbeagle2.c
 copy board/{ti/am62x/am62x.env => beagle/pocketbeagle2/pocketbeagle2.env} (64%)
 copy board/{phytec/phycore_am62x => beagle/pocketbeagle2}/rm-cfg.yaml (99%)
 copy board/beagle/{beagleplay => pocketbeagle2}/sec-cfg.yaml (100%)
 copy configs/{am62x_beagleplay_a53_defconfig => am62_pocketbeagle2_a53_defconfig} (87%)
 copy configs/{am62x_beagleplay_r5_defconfig => am62_pocketbeagle2_r5_defconfig} (89%)
 create mode 100644 doc/board/beagle/am62_pocketbeagle2.rst
 copy include/configs/{beagley_ai.h => pocketbeagle2.h} (57%)
arch/arm/dts/Makefile +1 -0
index a29d1807e715..73bfb72b6b42 100644
@@ -1052,6 +1052,7 @@ dtb-$(CONFIG_SOC_K3_AM642) += k3-am642-r5-evm.dtb \
 			      k3-am642-r5-phycore-som-2gb.dtb
 
 dtb-$(CONFIG_SOC_K3_AM625) += k3-am625-r5-sk.dtb \
+			      k3-am62-r5-pocketbeagle2.dtb \
 			      k3-am625-r5-beagleplay.dtb \
 			      k3-am625-verdin-r5.dtb \
 			      k3-am625-r5-phycore-som-2gb.dtb
arch/arm/dts/k3-am62-pocketbeagle2-ddr4-1600MTs.dtsi renamed from arch/arm/dts/k3-am62x-sk-ddr4-1600MTs.dtsi +47 -45

229 lines not on this page · raw message

arch/arm/dts/k3-am62-pocketbeagle2-u-boot.dtsi renamed from arch/arm/dts/k3-am67a-beagley-ai-u-boot.dtsi +103 -57

308 lines not on this page · raw message

arch/arm/dts/k3-am62-r5-pocketbeagle2.dts new file +35 -0
new file mode 100644
index 000000000000..4489a559287b
@@ -0,0 +1,35 @@
+// SPDX-License-Identifier: GPL-2.0-only OR MIT
+/*
+ * AM625 PocketBeagle 2 dts file for R5 SPL
+ * https://www.beagleboard.org/boards/pocketbeagle-2
+ *
+ * Copyright (C) 2022-2023 Texas Instruments Incorporated - https://www.ti.com/
+ * Copyright (C) 2022-2023 Robert Nelson, BeagleBoard.org Foundation
+ */
+
+#include "k3-am62-pocketbeagle2.dts"
+#include "k3-am62-pocketbeagle2-ddr4-1600MTs.dtsi"
+#include "k3-am62-ddr.dtsi"
+
+#include "k3-am62-pocketbeagle2-u-boot.dtsi"
+#include "k3-am625-r5.dtsi"
+
+/ {
+	aliases {
+		serial1 = &main_uart1;
+		serial2 = &main_uart6;
+		serial3 = &main_uart3;
+		serial4 = &main_uart4;
+		serial5 = &main_uart5;
+		serial6 = &main_uart2;
+		serial7 = &main_uart0;
+	};
+};
+
+&main_pktdma {
+	ti,sci = <&dm_tifs>;
+};
+
+&main_bcdma {
+	ti,sci = <&dm_tifs>;
+};
arch/arm/mach-k3/am62x/Kconfig +1 -0
index f7ad52db7d8d..87470248aa15 100644
@@ -69,6 +69,7 @@ config TARGET_VERDIN_AM62_R5
 endchoice
 
 source "board/beagle/beagleplay/Kconfig"
+source "board/beagle/pocketbeagle2/Kconfig"
 source "board/phytec/phycore_am62x/Kconfig"
 source "board/ti/am62x/Kconfig"
 source "board/toradex/verdin-am62/Kconfig"
board/beagle/pocketbeagle2/Kconfig new file +60 -0

60 lines not on this page · raw message

board/beagle/pocketbeagle2/MAINTAINERS new file +10 -0
new file mode 100644
index 000000000000..79bdd59af7e7
@@ -0,0 +1,10 @@
+POCKETBEAGLE2 BOARD
+M:	Nishanth Menon <[email protected]>
+M:	Robert Nelson <[email protected]>
+M:	Tom Rini <[email protected]>
+S:	Maintained
+N:	pocketbeagle2
+F:	board/beagle/pocketbeagle2/
+F:	include/configs/pocketbeagle2.h
+F:	configs/am62_pocketbeagle2_a53_defconfig
+F:	configs/am62_pocketbeagle2_r5_defconfig
board/beagle/pocketbeagle2/Makefile new file +9 -0
new file mode 100644
index 000000000000..3d42c160716e
@@ -0,0 +1,9 @@
+# SPDX-License-Identifier: GPL-2.0+
+#
+# Makefile for AM625 PocketBeagle 2
+# https://www.beagleboard.org/boards/pocketbeagle-2
+#
+# Copyright (C) 2025 Texas Instruments Incorporated - https://www.ti.com/
+#
+
+obj-y += pocketbeagle2.o
board/beagle/pocketbeagle2/board-cfg.yaml renamed from board/beagle/beagleplay/board-cfg.yaml +0 -0
similarity index 100%
copy from board/beagle/beagleplay/board-cfg.yaml
copy to board/beagle/pocketbeagle2/board-cfg.yaml
board/beagle/pocketbeagle2/pm-cfg.yaml renamed from board/beagle/beagleplay/pm-cfg.yaml +0 -0
similarity index 100%
copy from board/beagle/beagleplay/pm-cfg.yaml
copy to board/beagle/pocketbeagle2/pm-cfg.yaml
board/beagle/pocketbeagle2/pocketbeagle2.c new file +58 -0

58 lines not on this page · raw message

board/beagle/pocketbeagle2/pocketbeagle2.env renamed from board/ti/am62x/am62x.env +7 -13
similarity index 64%
copy from board/ti/am62x/am62x.env
copy to board/beagle/pocketbeagle2/pocketbeagle2.env
index 60b5fd5e6ca7..816f365083e7 100644
@@ -10,23 +10,17 @@ 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}
+args_all=setenv optargs ${optargs} earlycon=ns16550a,mmio32,0x02860000
 run_kern=booti ${loadaddr} ${rd_spec} ${fdtaddr}
+set_led_state_fail_load= led led-1 off; led led-2 on;
+	led led-3 off; led led-4 on
+set_led_state_start_load=led led-1 on; led led-2 off;
+	led led-3 on; led led-4 off
 
-boot_targets=mmc1 mmc0 usb pxe dhcp
+boot_targets=mmc1
 boot=mmc
 mmcdev=1
 bootpart=1:2
 bootdir=/boot
+bootmeths=script extlinux efi pxe
 rd_spec=-
-
-splashfile=ti_logo_414x97_32bpp.bmp.gz
-splashimage=0x80200000
-splashpos=m,m
-splashsource=sf
-
-#if CONFIG_BOOTMETH_ANDROID
-#include <env/ti/android.env>
-adtb_idx=0
-#endif
\ No newline at end of file
board/beagle/pocketbeagle2/rm-cfg.yaml renamed from board/phytec/phycore_am62x/rm-cfg.yaml +2 -2
similarity index 99%
copy from board/phytec/phycore_am62x/rm-cfg.yaml
copy to board/beagle/pocketbeagle2/rm-cfg.yaml
index f800fb28a692..26d99b03b800 100644
@@ -525,7 +525,7 @@ rm-cfg:
             reserved: 0
         -
             start_resource: 168
-            num_resource: 7
+            num_resource: 8
             type: 1802
             host_id: 30
             reserved: 0
@@ -555,7 +555,7 @@ rm-cfg:
             reserved: 0
         -
             start_resource: 909
-            num_resource: 625
+            num_resource: 626
             type: 1805
             host_id: 128
             reserved: 0
board/beagle/pocketbeagle2/sec-cfg.yaml renamed from board/beagle/beagleplay/sec-cfg.yaml +0 -0
similarity index 100%
copy from board/beagle/beagleplay/sec-cfg.yaml
copy to board/beagle/pocketbeagle2/sec-cfg.yaml
configs/am62_pocketbeagle2_a53_defconfig renamed from configs/am62x_beagleplay_a53_defconfig +11 -13
similarity index 87%
copy from configs/am62x_beagleplay_a53_defconfig
copy to configs/am62_pocketbeagle2_a53_defconfig
index c9bc7cd8d398..8964cb3b1955 100644
@@ -6,18 +6,23 @@ CONFIG_SPL_LIBCOMMON_SUPPORT=y
 CONFIG_SPL_LIBGENERIC_SUPPORT=y
 CONFIG_NR_DRAM_BANKS=1
 CONFIG_SOC_K3_AM625=y
-CONFIG_TARGET_AM625_A53_BEAGLEPLAY=y
+CONFIG_TARGET_AM62X_A53_POCKETBEAGLE2=y
 CONFIG_HAS_CUSTOM_SYS_INIT_SP_ADDR=y
-CONFIG_CUSTOM_SYS_INIT_SP_ADDR=0x80b80000
+CONFIG_CUSTOM_SYS_INIT_SP_ADDR=0x82b00000
 CONFIG_DM_GPIO=y
-CONFIG_DEFAULT_DEVICE_TREE="ti/k3-am625-beagleplay"
+CONFIG_DEFAULT_DEVICE_TREE="ti/k3-am62-pocketbeagle2"
 CONFIG_OF_LIBFDT_OVERLAY=y
 CONFIG_DM_RESET=y
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
-CONFIG_SPL_STACK_R_ADDR=0x82000000
+CONFIG_TEXT_BASE=0x82f80000
+CONFIG_SPL_TEXT_BASE=0x82000000
+CONFIG_SPL_STACK_R_ADDR=0x83f80000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
-CONFIG_SPL_BSS_START_ADDR=0x80c80000
+CONFIG_K3_OPTEE_LOAD_ADDR=0x80080000
+CONFIG_SPL_BSS_START_ADDR=0x82c00000
+CONFIG_SPL_HAS_LOAD_FIT_ADDRESS=y
+CONFIG_SPL_LOAD_FIT_ADDRESS=0x82f80000
 CONFIG_SPL_BSS_MAX_SIZE=0x80000
 CONFIG_SPL_STACK_R=y
 CONFIG_SPL_SIZE_LIMIT=0x40000
@@ -44,8 +49,6 @@ CONFIG_SPL_I2C=y
 CONFIG_SPL_DM_MAILBOX=y
 CONFIG_SPL_POWER_DOMAIN=y
 CONFIG_SPL_YMODEM_SUPPORT=y
-CONFIG_CMD_BOOTEFI_SELFTEST=y
-CONFIG_CMD_NVEDIT_EFI=y
 CONFIG_CMD_GPIO=y
 CONFIG_CMD_GPIO_READ=y
 CONFIG_CMD_I2C=y
@@ -53,6 +56,7 @@ CONFIG_CMD_MMC=y
 CONFIG_CMD_EFIDEBUG=y
 CONFIG_CMD_PMIC=y
 CONFIG_CMD_REGULATOR=y
+CONFIG_CMD_CACHE=y
 CONFIG_OF_CONTROL=y
 CONFIG_SPL_OF_CONTROL=y
 CONFIG_OF_UPSTREAM=y
@@ -90,10 +94,6 @@ CONFIG_MMC_SDHCI=y
 CONFIG_MMC_SDHCI_ADMA=y
 CONFIG_SPL_MMC_SDHCI_ADMA=y
 CONFIG_MMC_SDHCI_AM654=y
-CONFIG_PHY_REALTEK=y
-CONFIG_PHY_TI=y
-CONFIG_DM_ETH_PHY=y
-CONFIG_TI_AM65_CPSW_NUSS=y
 CONFIG_PHY=y
 CONFIG_PINCTRL=y
 CONFIG_SPL_PINCTRL=y
@@ -120,7 +120,5 @@ CONFIG_SYSRESET_TI_SCI=y
 CONFIG_EXT4_WRITE=y
 CONFIG_FS_FAT_MAX_CLUSTSIZE=16384
 CONFIG_LZO=y
-CONFIG_EFI_SET_TIME=y
 
-#include <configs/k3_efi_capsule.config>
 #include <configs/am62x_a53_usbdfu.config>
configs/am62_pocketbeagle2_r5_defconfig renamed from configs/am62x_beagleplay_r5_defconfig +8 -3
similarity index 89%
copy from configs/am62x_beagleplay_r5_defconfig
copy to configs/am62_pocketbeagle2_r5_defconfig
index 08b2c38b80de..90e577e8ce16 100644
@@ -3,15 +3,16 @@ CONFIG_ARCH_K3=y
 CONFIG_SYS_MALLOC_LEN=0x08000000
 CONFIG_SYS_MALLOC_F_LEN=0x9000
 CONFIG_SPL_LIBCOMMON_SUPPORT=y
+CONFIG_SPL_LIBGENERIC_SUPPORT=y
 CONFIG_NR_DRAM_BANKS=1
 CONFIG_SOC_K3_AM625=y
-CONFIG_TARGET_AM625_R5_BEAGLEPLAY=y
+CONFIG_TARGET_AM62X_R5_POCKETBEAGLE2=y
 CONFIG_HAS_CUSTOM_SYS_INIT_SP_ADDR=y
 CONFIG_CUSTOM_SYS_INIT_SP_ADDR=0x43c3a7f0
 CONFIG_ENV_SIZE=0x20000
 CONFIG_DM_GPIO=y
 CONFIG_SPL_DM_SPI=y
-CONFIG_DEFAULT_DEVICE_TREE="k3-am625-r5-beagleplay"
+CONFIG_DEFAULT_DEVICE_TREE="k3-am62-r5-pocketbeagle2"
 CONFIG_DM_RESET=y
 CONFIG_SPL_SYS_MALLOC_F_LEN=0x7000
 CONFIG_SPL_MMC=y
@@ -34,7 +35,6 @@ CONFIG_SPL_SIZE_LIMIT_SUBTRACT_MALLOC=y
 CONFIG_SPL_MAX_SIZE=0x3B000
 CONFIG_SPL_PAD_TO=0x0
 CONFIG_SPL_SYS_REPORT_STACK_F_USAGE=y
-CONFIG_SPL_BOARD_INIT=y
 CONFIG_SPL_SYS_MALLOC_SIMPLE=y
 CONFIG_SPL_SEPARATE_BSS=y
 CONFIG_SPL_SYS_MALLOC=y
@@ -62,6 +62,8 @@ CONFIG_ENV_RELOC_GD_ENV_ADDR=y
 CONFIG_NO_NET=y
 CONFIG_SPL_DM=y
 CONFIG_SPL_DM_SEQ_ALIAS=y
+CONFIG_REGMAP=y
+CONFIG_SPL_REGMAP=y
 CONFIG_SPL_OF_TRANSLATE=y
 CONFIG_CLK=y
 CONFIG_SPL_CLK=y
@@ -97,3 +99,6 @@ CONFIG_SPL_TIMER=y
 CONFIG_OMAP_TIMER=y
 CONFIG_LIB_RATIONAL=y
 CONFIG_SPL_LIB_RATIONAL=y
+CONFIG_K3_OPTEE_LOAD_ADDR=0x80080000
+CONFIG_SPL_HAS_LOAD_FIT_ADDRESS=y
+CONFIG_SPL_LOAD_FIT_ADDRESS=0x82000000
doc/board/beagle/am62_pocketbeagle2.rst new file +279 -0

279 lines not on this page · raw message

doc/board/beagle/index.rst +1 -0
index e33d39fc677f..8bf099ae7be7 100644
@@ -10,6 +10,7 @@ ARM based boards
 .. toctree::
    :maxdepth: 2
 
+   am62_pocketbeagle2
    am62x_beagleplay
    am67a_beagley_ai.rst
    j721e_beagleboneai64
include/configs/pocketbeagle2.h renamed from include/configs/beagley_ai.h +4 -4
similarity index 57%
copy from include/configs/beagley_ai.h
copy to include/configs/pocketbeagle2.h
index a7072a094c58..dd6956aa8b90 100644
@@ -1,14 +1,14 @@
 /* SPDX-License-Identifier: GPL-2.0+ */
 /*
- * Configuration header file for BeagleY-AI
+ * Configuration header file for PocketBeagle 2
  *
  * Copyright (C) 2025 Texas Instruments Incorporated - https://www.ti.com/
  */
 
-#ifndef __CONFIG_BEAGLEY_AI_H
-#define __CONFIG_BEAGLEY_AI_H
+#ifndef __CONFIG_POCKETBEAGLE2_H
+#define __CONFIG_POCKETBEAGLE2_H
 
 /* Now for the remaining common defines */
 #include <configs/ti_armv7_common.h>
 
-#endif /* __CONFIG_BEAGLEY_AI_H */
+#endif /* __CONFIG_POCKETBEAGLE2_H */
Signature · 1 line
2.54.0
#3 lore raw

PATCH v3 3/4 k3-am62-pocketbeagle2: add support for 1GB variant

In reply to [email protected]

From: Randolph Sapp <[email protected]>

Take Phytec's current DDR fixup functions and utilize them to dynamically adjust for variants in the pocketbeagle2. There are currently 3 skews, two of which are both 512MB with the same memory configuration, and one which is 1GB using the same CWL and CL settings but a modified density [1].

Based off of Bryan Brattlof's patch [2].

[1] https://mm.digikey.com/Volume0/opasdata/d220001/medias/docus/5411/8G%20Bits%20DDR4%20SDRAM.pdf
[2] https://github.com/bryanbrattlof/beagleboot/commit/fb2f022e27427e990d7a33fd001ffb571e13cfc3

---
 board/beagle/pocketbeagle2/Kconfig            |  26 +++++
 board/beagle/pocketbeagle2/Makefile           |   2 +
 board/beagle/pocketbeagle2/pocketbeagle2.c    | 103 +++++++++++++++++-
 .../beagle/pocketbeagle2/pocketbeagle2_ddr.h  |  50 +++++++++
 configs/am62_pocketbeagle2_r5_defconfig       |   5 +-
 5 files changed, 184 insertions(+), 2 deletions(-)
 create mode 100644 board/beagle/pocketbeagle2/pocketbeagle2_ddr.h
board/beagle/pocketbeagle2/Kconfig +26 -0
index e957b8e8377e..a361fcebfc1d 100644
@@ -12,6 +12,7 @@ config TARGET_AM62X_A53_POCKETBEAGLE2
 	select ARM64
 	select BINMAN
 	select OF_SYSTEM_SETUP
+	imply TI_I2C_BOARD_DETECT
 
 config TARGET_AM62X_R5_POCKETBEAGLE2
 	bool "BeagleBoard.org AM62X PocketBeagle 2 running on R5"
@@ -23,6 +24,7 @@ config TARGET_AM62X_R5_POCKETBEAGLE2
 	select K3_DDRSS
 	select BINMAN
 	imply SYS_K3_SPL_ATF
+	imply TI_I2C_BOARD_DETECT
 
 endchoice
 
@@ -58,3 +60,27 @@ config SPL_LDSCRIPT
 source "board/ti/common/Kconfig"
 
 endif
+
+config POCKETBEAGLE2_AM62X_RAM_SIZE_FIX
+	bool "Set the PocketBeagle 2 RAM size instead of detecting it"
+	default false
+	help
+	  RAM size is automatically detected through the device revision stored
+	  in EEPROM. This overrides the detection logic with a fixed value.
+
+choice
+	prompt "PocketBeagle 2 RAM size"
+	depends on POCKETBEAGLE2_AM62X_RAM_SIZE_FIX
+	default POCKETBEAGLE2_AM62X_RAM_SIZE_512MB
+
+config POCKETBEAGLE2_AM62X_RAM_SIZE_512MB
+	bool "512MB RAM"
+	help
+	  Set RAM size fix to 512MB for the PocketBeagle 2.
+
+config POCKETBEAGLE2_AM62X_RAM_SIZE_1GB
+	bool "1GB RAM"
+	help
+	  Set RAM size fix to 1GB for the PocketBeagle 2.
+
+endchoice
board/beagle/pocketbeagle2/Makefile +2 -0
index 3d42c160716e..dd529fe6d75e 100644
@@ -7,3 +7,5 @@
 #
 
 obj-y += pocketbeagle2.o
+obj-${CONFIG_K3_DDRSS} += ../../phytec/common/k3/k3_ddrss_patch.o
+obj-${CONFIG_TI_I2C_BOARD_DETECT} += ../../ti/common/board_detect.o
board/beagle/pocketbeagle2/pocketbeagle2.c +102 -1

119 lines not on this page · raw message

board/beagle/pocketbeagle2/pocketbeagle2_ddr.h new file +50 -0

50 lines not on this page · raw message

configs/am62_pocketbeagle2_r5_defconfig +4 -1
index 90e577e8ce16..82919d559d5e 100644
@@ -14,7 +14,7 @@ CONFIG_DM_GPIO=y
 CONFIG_SPL_DM_SPI=y
 CONFIG_DEFAULT_DEVICE_TREE="k3-am62-r5-pocketbeagle2"
 CONFIG_DM_RESET=y
-CONFIG_SPL_SYS_MALLOC_F_LEN=0x7000
+CONFIG_SPL_SYS_MALLOC_F_LEN=0x8000
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
@@ -41,6 +41,7 @@ CONFIG_SPL_SYS_MALLOC=y
 CONFIG_SPL_EARLY_BSS=y
 CONFIG_SPL_SYS_MMCSD_RAW_MODE=y
 CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR=0x400
+CONFIG_SPL_I2C=y
 CONFIG_SPL_DM_MAILBOX=y
 CONFIG_SPL_DM_RESET=y
 CONFIG_SPL_POWER_DOMAIN=y
@@ -72,6 +73,8 @@ CONFIG_SPL_CLK_K3_PLL=y
 CONFIG_SPL_CLK_K3=y
 CONFIG_TI_SCI_PROTOCOL=y
 CONFIG_DA8XX_GPIO=y
+CONFIG_DM_I2C=y
+CONFIG_SYS_I2C_OMAP24XX=y
 CONFIG_DM_MAILBOX=y
 CONFIG_K3_SEC_PROXY=y
 CONFIG_SPL_MISC=y
Signature · 1 line
2.54.0
#4 lore raw

Re: [PATCHv3 3/4] k3-am62-pocketbeagle2: add support for 1GB variant

Quoted 23 lines · rs

From: Randolph Sapp <[email protected]>

Take Phytec's current DDR fixup functions and utilize them to dynamically adjust for variants in the pocketbeagle2. There are currently 3 skews, two of which are both 512MB with the same memory configuration, and one which is 1GB using the same CWL and CL settings but a modified density [1].

Based off of Bryan Brattlof's patch [2].

[1] https://mm.digikey.com/Volume0/opasdata/d220001/medias/docus/5411/8G%20Bits%20DDR4%20SDRAM.pdf
[2] https://github.com/bryanbrattlof/beagleboot/commit/fb2f022e27427e990d7a33fd001ffb571e13cfc3

---
 board/beagle/pocketbeagle2/Kconfig            |  26 +++++
 board/beagle/pocketbeagle2/Makefile           |   2 +
 board/beagle/pocketbeagle2/pocketbeagle2.c    | 103 +++++++++++++++++-
 .../beagle/pocketbeagle2/pocketbeagle2_ddr.h  |  50 +++++++++
 configs/am62_pocketbeagle2_r5_defconfig       |   5 +-
 5 files changed, 184 insertions(+), 2 deletions(-)
 create mode 100644 board/beagle/pocketbeagle2/pocketbeagle2_ddr.h
Quoted 1 line

[snip]

Just thinking out loud here, but maybe we shouldn't take this patch. The industrial version, on top of having more memory, also has eMMC. That already mandates a new device tree and configuration if people are going to use it as a boot method.

Then again, maybe it's convenient for the users who don't care about eMMC? I dunno. Seems odd either way.

#5 lore raw

Re: [PATCHv3 3/4] k3-am62-pocketbeagle2: add support for 1GB variant

Quoted 26 lines · Randolph Sapp
Quoted 23 lines · rs

From: Randolph Sapp <[email protected]>

Take Phytec's current DDR fixup functions and utilize them to dynamically adjust for variants in the pocketbeagle2. There are currently 3 skews, two of which are both 512MB with the same memory configuration, and one which is 1GB using the same CWL and CL settings but a modified density [1].

Based off of Bryan Brattlof's patch [2].

[1] https://mm.digikey.com/Volume0/opasdata/d220001/medias/docus/5411/8G%20Bits%20DDR4%20SDRAM.pdf
[2] https://github.com/bryanbrattlof/beagleboot/commit/fb2f022e27427e990d7a33fd001ffb571e13cfc3

---
 board/beagle/pocketbeagle2/Kconfig            |  26 +++++
 board/beagle/pocketbeagle2/Makefile           |   2 +
 board/beagle/pocketbeagle2/pocketbeagle2.c    | 103 +++++++++++++++++-
 .../beagle/pocketbeagle2/pocketbeagle2_ddr.h  |  50 +++++++++
 configs/am62_pocketbeagle2_r5_defconfig       |   5 +-
 5 files changed, 184 insertions(+), 2 deletions(-)
 create mode 100644 board/beagle/pocketbeagle2/pocketbeagle2_ddr.h
Quoted 1 line

[snip]

Quoted 7 lines

Just thinking out loud here, but maybe we shouldn't take this patch. The industrial version, on top of having more memory, also has eMMC. That already mandates a new device tree and configuration if people are going to use it as a boot method.

Then again, maybe it's convenient for the users who don't care about eMMC? I dunno. Seems odd either way.

Since it's technically a different board altogether and not just PB2 w/ extra DDR. I think it might be better if it had a separate DT and we can decide the correct one based on the EEPROM at runtime using SPL_MULTI_DTB_FIT which would allow us to still have a single defconfig in U-Boot.

#6 lore raw

Re: [PATCHv3 3/4] k3-am62-pocketbeagle2: add support for 1GB variant

Quoted 32 lines · Anshul Dalal
Quoted 31 lines · Randolph Sapp
Quoted 23 lines · rs

From: Randolph Sapp <[email protected]>

Take Phytec's current DDR fixup functions and utilize them to dynamically adjust for variants in the pocketbeagle2. There are currently 3 skews, two of which are both 512MB with the same memory configuration, and one which is 1GB using the same CWL and CL settings but a modified density [1].

Based off of Bryan Brattlof's patch [2].

[1] https://mm.digikey.com/Volume0/opasdata/d220001/medias/docus/5411/8G%20Bits%20DDR4%20SDRAM.pdf
[2] https://github.com/bryanbrattlof/beagleboot/commit/fb2f022e27427e990d7a33fd001ffb571e13cfc3

---
 board/beagle/pocketbeagle2/Kconfig            |  26 +++++
 board/beagle/pocketbeagle2/Makefile           |   2 +
 board/beagle/pocketbeagle2/pocketbeagle2.c    | 103 +++++++++++++++++-
 .../beagle/pocketbeagle2/pocketbeagle2_ddr.h  |  50 +++++++++
 configs/am62_pocketbeagle2_r5_defconfig       |   5 +-
 5 files changed, 184 insertions(+), 2 deletions(-)
 create mode 100644 board/beagle/pocketbeagle2/pocketbeagle2_ddr.h
Quoted 1 line

[snip]

Just thinking out loud here, but maybe we shouldn't take this patch. The industrial version, on top of having more memory, also has eMMC. That already mandates a new device tree and configuration if people are going to use it as a boot method.

Quoted 8 lines
Quoted 2 lines

Then again, maybe it's convenient for the users who don't care about eMMC? I dunno. Seems odd either way.

Since it's technically a different board altogether and not just PB2 w/ extra DDR. I think it might be better if it had a separate DT and we can decide the correct one based on the EEPROM at runtime using SPL_MULTI_DTB_FIT which would allow us to still have a single defconfig in U-Boot.

Syncing some internal comments here:

Zephyr and Jason Kridner apparently agree with me here. They treat the device as a separate model: https://github.com/zephyrproject-rtos/zephyr/pull/106680

To cite Bryan Brattlof:

I don't think the R5 has the space to switch-out the DT like this during bootup. it would need to be another build

Sounds like we'll have to upstream a separate dt and defconfig then. I'll play around with this a little on my end before submitting another revision. Suppose the dt will have to go to the kernel first so it'll be a little bit.

#7 lore raw

Re: [PATCHv3 3/4] k3-am62-pocketbeagle2: add support for 1GB variant

On June 29, 2026 thus sayeth Randolph Sapp:

Quoted 47 lines · Anshul Dalal
Quoted 32 lines · Randolph Sapp
Quoted 31 lines · rs
Quoted 23 lines

From: Randolph Sapp <[email protected]>

Take Phytec's current DDR fixup functions and utilize them to dynamically adjust for variants in the pocketbeagle2. There are currently 3 skews, two of which are both 512MB with the same memory configuration, and one which is 1GB using the same CWL and CL settings but a modified density [1].

Based off of Bryan Brattlof's patch [2].

[1] https://mm.digikey.com/Volume0/opasdata/d220001/medias/docus/5411/8G%20Bits%20DDR4%20SDRAM.pdf
[2] https://github.com/bryanbrattlof/beagleboot/commit/fb2f022e27427e990d7a33fd001ffb571e13cfc3

---
 board/beagle/pocketbeagle2/Kconfig            |  26 +++++
 board/beagle/pocketbeagle2/Makefile           |   2 +
 board/beagle/pocketbeagle2/pocketbeagle2.c    | 103 +++++++++++++++++-
 .../beagle/pocketbeagle2/pocketbeagle2_ddr.h  |  50 +++++++++
 configs/am62_pocketbeagle2_r5_defconfig       |   5 +-
 5 files changed, 184 insertions(+), 2 deletions(-)
 create mode 100644 board/beagle/pocketbeagle2/pocketbeagle2_ddr.h
Quoted 1 line

[snip]

Just thinking out loud here, but maybe we shouldn't take this patch. The industrial version, on top of having more memory, also has eMMC. That already mandates a new device tree and configuration if people are going to use it as a boot method.

Quoted 8 lines
Quoted 2 lines

Then again, maybe it's convenient for the users who don't care about eMMC? I dunno. Seems odd either way.

Since it's technically a different board altogether and not just PB2 w/ extra DDR. I think it might be better if it had a separate DT and we can decide the correct one based on the EEPROM at runtime using SPL_MULTI_DTB_FIT which would allow us to still have a single defconfig in U-Boot.

Syncing some internal comments here:

Zephyr and Jason Kridner apparently agree with me here. They treat the device as a separate model: https://github.com/zephyrproject-rtos/zephyr/pull/106680

Quoted 8 lines

To cite Bryan Brattlof:

I don't think the R5 has the space to switch-out the DT like this during bootup. it would need to be another build

Sounds like we'll have to upstream a separate dt and defconfig then. I'll play around with this a little on my end before submitting another revision. Suppose the dt will have to go to the kernel first so it'll be a little bit.

Sorry Randolph, I've been buried in emails. Thanks for syncing the threads together.

My only worry here is having different builds for each flavor of the PB2 will complicate things for people who don't care about the BSP layers. If all we're worried about is checking if the MMC is populated and which DDR to setup before we hand things over to Linux then in my opinion is this approach is better. Linux shouldn't care about these things.

We do have some space we can reclaim in the R5 SPL build but I seriously doubt swapping out the DT on the fly like we're suggesting will work for the R5 SPL. The only hope we have to unify the bootloaders for all PB2s is going to be with this approach.

~Bryan

#8 lore raw

PATCH v3 4/4 k3-am62-pocketbeagle2: add support for efi capsules

In reply to [email protected]

From: Randolph Sapp <[email protected]>

Add support for EFI capsules for this device. One large caveat is that the partition holding boot binaries cannot be the ESP partition due to the following ROM limitations.

- The boot disk must be MBR
- The boot partition must be labeled 0x0c with a boot flag

A separate ESP partition should be provided for EFI capabilities.

---
v3:
- Remove unnecessary dfu_alt_info_ram variable

---
 .../arm/dts/k3-am62-pocketbeagle2-u-boot.dtsi | 29 +++++++++++++++++++
 board/beagle/pocketbeagle2/pocketbeagle2.c    | 26 +++++++++++++++++
 configs/am62_pocketbeagle2_a53_defconfig      |  1 +
 include/configs/pocketbeagle2.h               | 25 ++++++++++++++++
 4 files changed, 81 insertions(+)
arch/arm/dts/k3-am62-pocketbeagle2-u-boot.dtsi +29 -0
index 452161115318..283e26380e48 100644
@@ -181,6 +181,17 @@
 		};
 	};
 };
+
+#include "k3-binman-capsule-r5.dtsi"
+
+// Capsule update GUIDs in string form. See pocketbeagle2.h
+#define POCKETBEAGLE2_TIBOOT3_IMAGE_GUID_STR "F0D53723-106E-5346-8A41-85EB2D07C720"
+
+&capsule_tiboot3 {
+	efi-capsule {
+		image-guid = POCKETBEAGLE2_TIBOOT3_IMAGE_GUID_STR;
+	};
+};
 #endif /* CONFIG_TARGET_AM62X_R5_POCKETBEAGLE2 */
 
 #if IS_ENABLED(CONFIG_TARGET_AM62X_A53_POCKETBEAGLE2)
@@ -304,4 +315,22 @@
 		};
 	};
 };
+
+#include "k3-binman-capsule.dtsi"
+
+// Capsule update GUIDs in string form. See pocketbeagle2.h
+#define POCKETBEAGLE2_SPL_IMAGE_GUID_STR "C73FDEA2-3964-58C8-8A25-E55102172E1D"
+#define POCKETBEAGLE2_UBOOT_IMAGE_GUID_STR "520E1012-DE6C-5992-B43A-95D53D8332F2"
+
+&capsule_tispl {
+	efi-capsule {
+		image-guid = POCKETBEAGLE2_SPL_IMAGE_GUID_STR;
+	};
+};
+
+&capsule_uboot {
+	efi-capsule {
+		image-guid = POCKETBEAGLE2_UBOOT_IMAGE_GUID_STR;
+	};
+};
 #endif /* CONFIG_TARGET_AM62X_A53_POCKETBEAGLE2 */
board/beagle/pocketbeagle2/pocketbeagle2.c +26 -0
index 8463d82ef9d8..b6a136a93c0a 100644
@@ -7,6 +7,7 @@
  * Copyright (C) 2025 Robert Nelson, BeagleBoard.org Foundation
  */
 
+#include <efi_loader.h>
 #include <env.h>
 #include <fdt_support.h>
 #include <spl.h>
@@ -22,6 +23,31 @@
 
 DECLARE_GLOBAL_DATA_PTR;
 
+struct efi_fw_image fw_images[] = {
+	{
+		.image_type_id = POCKETBEAGLE2_TIBOOT3_IMAGE_GUID,
+		.fw_name = u"POCKETBEAGLE2_TIBOOT3",
+		.image_index = 1,
+	},
+	{
+		.image_type_id = POCKETBEAGLE2_SPL_IMAGE_GUID,
+		.fw_name = u"POCKETBEAGLE2_SPL",
+		.image_index = 2,
+	},
+	{
+		.image_type_id = POCKETBEAGLE2_UBOOT_IMAGE_GUID,
+		.fw_name = u"POCKETBEAGLE2_UBOOT",
+		.image_index = 3,
+	}
+};
+
+struct efi_capsule_update_info update_info = {
+	.dfu_string = "mmc 1=tiboot3.bin fat 1 1;"
+		      "tispl.bin fat 1 1;u-boot.img fat 1 1",
+	.num_images = ARRAY_SIZE(fw_images),
+	.images = fw_images,
+};
+
 static int pocketbeagle2_get_ddr_size(void)
 {
 	// check config overrides first
configs/am62_pocketbeagle2_a53_defconfig +1 -0
index 8964cb3b1955..7428926a8ba6 100644
@@ -122,3 +122,4 @@ CONFIG_FS_FAT_MAX_CLUSTSIZE=16384
 CONFIG_LZO=y
 
 #include <configs/am62x_a53_usbdfu.config>
+#include <configs/k3_efi_capsule.config>
include/configs/pocketbeagle2.h +25 -0
index dd6956aa8b90..aed60d325742 100644
@@ -8,6 +8,31 @@
 #ifndef __CONFIG_POCKETBEAGLE2_H
 #define __CONFIG_POCKETBEAGLE2_H
 
+/**
+ * define POCKETBEAGLE2_TIBOOT3_IMAGE_GUID - firmware GUID for PocketBeagle 2
+ *                                           tiboot3.bin
+ * define POCKETBEAGLE2_SPL_IMAGE_GUID     - firmware GUID for PocketBeagle 2 SPL
+ * define POCKETBEAGLE2_UBOOT_IMAGE_GUID   - firmware GUID for PocketBeagle 2 UBOOT
+ *
+ * These GUIDs are used in capsules updates to identify the corresponding
+ * firmware object.
+ *
+ * Board developers using this as a starting reference should
+ * define their own GUIDs to ensure that firmware repositories (like
+ * LVFS) do not confuse them.
+ */
+#define POCKETBEAGLE2_TIBOOT3_IMAGE_GUID                                   \
+	EFI_GUID(0xF0D53723, 0x106E, 0x5346, 0x8A, 0x41, 0x85, 0xEB, 0x2D, \
+		 0x07, 0xC7, 0x20)
+
+#define POCKETBEAGLE2_SPL_IMAGE_GUID                                       \
+	EFI_GUID(0xC73FDEA2, 0x3964, 0x58C8, 0x8A, 0x25, 0xE5, 0x51, 0x02, \
+		 0x17, 0x2E, 0x1D)
+
+#define POCKETBEAGLE2_UBOOT_IMAGE_GUID                                     \
+	EFI_GUID(0x520E1012, 0xDE6C, 0x5992, 0xB4, 0x3A, 0x95, 0xD5, 0x3D, \
+		 0x83, 0x32, 0xF2)
+
 /* Now for the remaining common defines */
 #include <configs/ti_armv7_common.h>
 
Signature · 1 line
2.54.0
#9 lore raw
In reply to [email protected]

Hi Randolph, all,

I tested this together with the ECDSA patch series v8, on top of the current u-boot master.

I built a signed FIT image with Linux v7.1, target load address 0x84000000 and device tree address 0x83000000. This did not clash with the $loadaddr of 0x82000000; the kernel address 0x81000000 would cause u-boot to crash and reboot.

The kernel booted fine, but the
https://www.beagleboard.org/distros/pocketbeagle-2-debian-13-5-2026-05-19-minimal-v6-12-x-ti
user space would fail to start up ZRAM. I guess it's simply because I did not make any kernel modules available yet. I was able to get into the login screen and shut down the system nevertheless.

My ultimate goal is to set up trusted boot on top of TF-A. The PocketBeagle 2 is a convenient development platform.

With best regards,

Marko